users@glassfish.java.net

Re: Singleton @PreDestroy application state?

From: <forums_at_java.net>
Date: Thu, 22 Sep 2011 06:35:17 -0500 (CDT)

Well, looks like this is not getting resolved, so maybe there's another way
to skin this cat. Basically what I'm trying to do is to notify another
application in another JVM instance that this app instance is about get
destroyed. This in a non-clustered environment so GMS is non an option (or is
it?). I was instantiating a singletion bean with @Startup directive, calling
remoteInstance.register(...) in @PostConstruct and
remoteInstance.unregister(..) in predestroy. The registration stage works
fine, but it's failing miserably in @PreDestroy. Anyone has any ideas on how
to tackle this issue asynchronously (without resolving to heartbeats).


--
[Message sent by forum member 'karl.vizmatik']
View Post: http://forums.java.net/node/844344