I've seen this before (windows I assume). After calling destroy call exitValue. It will cause an exception, so catch it, but after that the process is gone (usually).
Don't know why it's this way sometimes, but it is.
I have axis 1.4 webservice running in tomcat 6.0.18. I have a Runtime.exec calling a C program. When my Java client is connecting to the web service to get data through the C program many times (50 times) the Runtime.exec hangs and creates stale processes. How can I avoid this?
I am thinking of doing "ps -ef | grep processId" Unix command to identify and kill it but it will be a workaround. I was hoping to fix it so it won't create these stale processes and hang.