“Finding thread start events without matching end events is as simple as running a LEFT JOIN on the two event types and keeping only those start events which don’t have a join partner.”
A thread dump shows you thousands of threads named pool-729-thread-1 and nothing about who started them. JDK Flight Recorder logs every start and end, and Calcite lets you query the recording as SQL. One LEFT JOIN finds the threads that never died, and the parent thread column points at the third-party library that leaked them. The bug is usually in a dependency you never read.