|
This is a multipart message in MIME format.
--
[ Picked text/plain from multipart/alternative ]
Phil,
No I haven't. I previously searched the archives and all the
recommendations I saw recommended checking the job status via RTVJOBA or
the retrieve job API. My daemon is calling a CL program in a loop. The
CL is receiving a data queue entry with a wait time of 30 seconds. I just
made the CL use RTVJOBA to get the job status and return it along with any
data queue entries. If the status is '1', then the Java job terminates.
I am not sure how the addshutdownHook would play into this. Presumably I
could use it to set some boolean in my class that I checked when control
came back from the program call and just do the same thing?
Do you have any examples?
Thanks
Mark
"Hall, Philip" <phall@spss.com>
Sent by: java400-l-admin@midrange.com
10/18/2002 01:34 PM
Please respond to java400-l
To: <java400-l@midrange.com>
cc:
Subject: RE: Detecting Job/Subsystem Termination
> I am writing a "daemon-type" process in Java. I want to be able
> to detect when an operator ends the job or subsystem and close
Have you tried using the addShutdownHook method of the Runtime class to
detect when the JVM is being terminated ?
--phil
_______________________________________________
This is the Java Programming on and around the iSeries / AS400 (JAVA400-L)
mailing list
To post a message email: JAVA400-L@midrange.com
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/cgi-bin/listinfo/java400-l
or email: JAVA400-L-request@midrange.com
Before posting, please take a moment to review the archives
at http://archive.midrange.com/java400-l.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.