commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "~ * ~ Srijith Unni ~ * ~" <srijithu...@india.com>
Subject Returning non-zero exit code in Windows
Date Thu, 25 Sep 2014 13:57:33 GMT
Hi All,

         I am making use of commons-daemon to get my java process started
as a Windows Service. I am installing the service and launching it in jvm
mode. I want to handle any error condition that occurs and I am returning a
non-zero exit code, and I have set Recovery Options for my service. However
I am not seeing the service being restarted. I have gone through
http://comments.gmane.org/gmane.comp.jakarta.commons.issues/19191 and
http://markmail.org/message/mkavfkirjqb37bqn and I see that this issue was
fixed long back in 1.0.11.

         What I am doing is having an UncaughtExceptionHandler for my Java
runtime and I am handling the same and doing a System.exit(-1). When I run
my service prunsrv.exe separately from command prompt I am seeing that the
exit code is -1, but somehow while running as a service, it is not working
as expected.

         Can you let me know what I am doing wrong / if I have missed
anything.

-- 
Thanks & Regards,
--
A.Srijith.K.Unni
Mail ID : srijith.unni@gmail.com
Home Page : https://about.me/srijith

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message