Iain Williams created DAEMON-302:
------------------------------------

             Summary: Service recovery options do not work when a JNI crash 
brings down the JVM
                 Key: DAEMON-302
                 URL: https://issues.apache.org/jira/browse/DAEMON-302
             Project: Commons Daemon
          Issue Type: Bug
          Components: Procrun
    Affects Versions: 1.0.15
         Environment: Windows 7 64bit
JRE 1.7.0_25-b17 (64bit)
            Reporter: Iain Williams


We have a java application that we run as a service which has a C component 
setup, and communicated to across the Java Native Interface. 

If a crash occurs in the C component the whole JVM is brought down. However 
this does not trigger the service recovery options to kick in.

I believe this is due to a VM exit code of 0 (see bellow).

[2013-06-27 11:55:47] [debug] ( prunsrv.c:1528) [ 8488] Waiting for worker to 
finish...
[2013-06-27 11:55:55] [debug] ( javajni.c:964 ) [ 5716] Java Worker thread 
finished applicationName/core/applicationNameCore:main with status=0
[2013-06-27 11:55:55] [debug] ( prunsrv.c:1533) [ 8488] Worker finished.
[2013-06-27 11:55:55] [debug] ( prunsrv.c:1559) [ 8488] Waiting for all threads 
to exit
[2013-06-27 11:56:46] [debug] ( prunsrv.c:919 ) [10160] Start exit hook called 
...
[2013-06-27 11:56:46] [debug] ( prunsrv.c:920 ) [10160] VM exit code: 0
[2013-06-27 11:56:46] [debug] ( prunsrv.c:844 ) [10160] reportServiceStatusE: 
1, 0, 0, 0

With a return code of 0, the SCM would think the service stopped safely, 
without error, which is not the case here.

Is there anything that can be done about this?

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to