|
From: <siv...@bt...> - 2013-04-26 09:08:12
|
Please remove me from the list. I am getting annoyed with the continued messages.
From: Ani [mailto:jad...@gm...]
Sent: Friday, April 26, 2013 2:35 PM
To: wra...@li...
Subject: Re: [Wrapper-user] Wrapper-user Digest, Vol 82, Issue 6
Is there something configuration needs to be done in wrapper.conf to ensure that shutdown hooks gets called?
--Ani
Pl Save the environment. Please don't print this email unless you really need to.
On Fri, Apr 26, 2013 at 1:36 PM, Ani <jad...@gm...<mailto:jad...@gm...>> wrote:
On Fri, Apr 26, 2013 at 1:08 PM, <wra...@li...<mailto:wra...@li...>> wrote:
<chr...@ta...<mailto:chr...@ta...>>
Perfect , application launched and running successfully. Thank you Sir.
But my clear up activity process are nt getting called on service stop.
I have registered shutdown hook in my main class , i.e. EmbeddedJettyServer and the spring controller
in @preDestroy files.
--------------------------------------------------------
Runtime.getRuntime().addShutdownHook(new Thread(new Runnable() {
@Override
public void run() {
System.out.println("%%%%%%%%%%%%% in shutdown hook");
sLogger.info("%%%%%%%%%%%%% in shutdown hook");
}
}));
--------------------------------------------------------------------
@PreDestroy
public void dispose() {
sLogger.info("***********************in dispose PC");
System.out.println("***********************in dispose PC");
}
------------------------------------------------------------------------------------
Below is the log when I ctrl + c or service stop
wrapper | CTRL-C trapped. Shutting down.
wrapper | CTRL-C trapped. Forcing immediate shutdown.
wrapper | JVM did not exit on request, terminated
wrapper | <-- Wrapper Stopped
--Ani
Pl Save the environment. Please don't print this email unless you really need to.
|