I am having a problem with my application since some of threads I create become stuck , I have a way to find out what are they , I am trying to write a process to stop these threads [ kill them ] from outside my application since it becomes unresponsive when the stuck threads count increases over time [ I tried to fix the root cause but seems that it sometimes happens because of database aquire connection lock ]
Is there any way to access the JVM from outside I tried com.sun.tools.attach.VirtualMachine
but it didn't work is there any other way
Regards,