-
1. Re: The
dimitris Jan 20, 2006 10:40 AM (in response to jiwils)I think I've fixed this in 4.0.3SP1:
JBAS-2483, allow jboss to restart with an exit(10).
Improve logged messages to trace the shutdown execution path,
move shutdown notification to the shutdown hook
(avoid duplicate notifications/don't notify when halting), retain the
exit code when jboss.shutdown.forceHalt is enabled, disable forceHalt
by default (it would possibly kill other concurrent shutdown hooks).
So the notification should be send in all cases, except halting (that kills the JVM instantly) -
2. Re: The
jiwils Jan 20, 2006 10:54 AM (in response to jiwils)The subject did not print correctly...
I know we have tried this with JBoss 4.0.3 (and had the same results), but I am not sure if that was SP1 or not. I will verify this... -
3. Re: The
jiwils Jan 20, 2006 3:12 PM (in response to jiwils)"jiwils" wrote:
I know we have tried this with JBoss 4.0.3 (and had the same results), but I am not sure if that was SP1 or not. I will verify this...
Okay, I have the same problem in 4.0.3sp1, but its because I am not using the MBean methods to shutdown (in all cases). I am using both Ctrl+C and kill, so while your fixes add the notification to more than one method, it still will not get sent in then.
Is there any way we could have the shutdown hook send the notification? Then, it could be coded in one place (not the three methods), and I'll be sure it get it in the Ctrl+C and kill cases too. -
4. Re: The
jiwils Jan 20, 2006 4:14 PM (in response to jiwils)"jiwils" wrote:
Is there any way we could have the shutdown hook send the notification? Then, it could be coded in one place (not the three methods), and I'll be sure it get it in the Ctrl+C and kill cases too.
In looking at the Runtime.halt method Javadoc, it does look like it might be necessary to send the notification from multiple places as halt does not invoke the Shutdown Hooks...
So, I guess my question is whether or not we might could add this notification to the JBoss Shutdown Hook as well? In all but the Runtime.halt cases, it would take care it. -
5. Re: The
jiwils Jan 20, 2006 5:12 PM (in response to jiwils)I went ahead and created a JIRA issue.
http://jira.jboss.com/jira/browse/JBAS-2697 -
6. Re: The
dimitris Jan 22, 2006 6:42 AM (in response to jiwils)I was actually wrong; this is fixed *after* 4.03SP1, so it'll come with 4.0.4RC1. I actually tested it and I can see the notification, with CTRL-C pressed.
An easy way to tests this is by including this service (e.g. in deploy/monitoring-service.xml):<mbean code="org.jboss.monitor.services.NotificationListener" name="jboss.jmx:service=NotificationListener"> <attribute name="SubscriptionList"> <subscription-list> <mbean name="jboss.system:type=Server"/> </subscription-list> </attribute> </mbean>
So I'm going to close the case, sorry for the confusion.