I have a Java application which doesn't end. The main method finishes, but threads remain active and the application doesn't end. The thing is, there don't appear to be any monitor locks / waits, so I can't see why it's not ending. According to Eclipse, I am left with two non-Daemon threads. One is labelled [DestroyJavaVM] (looks hopeful!) and the other seems to be blocked in Unsafe.park(boolean, long)
. How / where should I start investigating this?
The abridged stacktrace of the second thread is:
Unsafe.park(boolean, long)
at LockSupport.park(Object)
at AbstractQueuedSynchronizer$ConditionObject.await()
at LinkedBlockingQueue<E>.take()
at ThreadPoolExecutor.getTask()
at ThreadPoolExecutor$Worker.run()
at Thread.run()