On Wed, 2 Apr 2003 09:13, Higgins, Steven C (Steven) wrote:
> I want to handle the case when a Phoenix block calls System.exit().
You can not give that permission to the block and it should not be able to
call that (unless you explicitly disable the security manager).
> I'm trying the following but none of the shutdown phase lifecycle methods
> (i.e. stop() ) are getting called.
>
> Runtime.getRuntime().addShutdownHook(new Thread() {
> public void run() { theBlockContext.requestShutdown(); }
> });
>
> Is there a better way? It seems as if Phoenix is gone before this hook
> fires.
you should not need to even do this as Phoenix will have already registered a
shutdown hook which will go through and shutdown all the applicatios
gracefully (or at least attempt to).
--
Cheers,
Peter Donald
-------------------------------------------------------
To fight and conquer in all your battles is not supreme
excellence; supreme excellence consists in breaking the
enemy's resistance without fighting. - Sun Tzu, 300 B.C.
-------------------------------------------------------
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]