DDObjects
Delphi Remoting, Exception Handler, Memory Profiler and Memory Leak Detection
DDObjects
Navigation
  • Home
  • DDDebug
  • DDObjects
    • Getting Started
    • Implementing Callbacks
    • Prices and Licensing
    • Frequently Asked Questions
    • What Customers say
  • About Me
    • Hohenlohe & Banghard
    • Celtic Circle Productions
    • ISIS GmbH
    • Software-Development
  • Customers
  • Blog
  • Imprint

DDDebug is helpful finding deadlocks between threads at application run time utilizing the Thread Wait Chain Traversal (WCT) API introduced in Windows Vista. Several classes do encapsulate the Windows API in a Delphi like manner, making the usage straightforward and painless.

The most common scenario does not need more than a couple of lines of code as well as the implementation of an event handler as shown within this code snippet:

LNotifier := TWaitChainNotifier.Create(DeadlockDetected);
LNotifier.CheckInterval := 500;
LNotifier.Active := True

procedure TSomeClass.DeadlockDetected(Sender: TObject;
  AThreads: TDDDThreadInfoArray;
  var AAbortThreads, ATryTerminate: Boolean);
begin
  // 
end;

The above snippet spawns a thread which periodically checks whether any deadlocks between the threads within the process do exist. As soon as any deadlock will be detected the event OnDeadlockDetected will be invoked, passing it an array of TDDDThreadInfos of those threads involved into the deadlock.

Prices and Licensing Information

Pages

  • DDDebug
  • DDObjects
    • Getting Started
    • Implementing Callbacks
    • Prices and Licensing
    • Frequently Asked Questions
    • What Customers say
    • Demos and Samples
  • About Me
    • Hohenlohe & Banghard
    • Celtic Circle Productions
    • ISIS GmbH
    • Software-Development
  • Customers
  • Blog
  • Imprint

Categories

  • Blog (3)
  • Freeware (6)
  • News and Updates (27)
  • Uncategorized (2)

© 2023 DDObjects