Automatic Deadlock Detection

This code will check for deadlocked threads if a ConditionTimeoutException is
thrown and attaches the thread information to the exception if something is
detected.