When profiling my application I came across a weird behavior - the DestroyJavaVM thread is ALWAYS running - 100% of the time.
After doing a little research on the subject, on which there's hardly any valuable information online, all I understood is that this thread is supposed to unload the JVM upon exit.
If that's the case, why is this thread in RUNNING state 100% of the time from the very first moment I start my application? Doesn't it consume valuable resources and therefore may cause an OutOfMemoryError
(like I sometimes get)?
Is there any official reference to what this thread actually does and what triggers its initialization?
Thanks
OOME
. I wouldn't start with the least obvious suspect. Have you profiled your application threads for memory use? That would be the straight forward approach to debugging your mysteriousOOME
s. – Grumble