Skip to main content



      Home
Home » Eclipse Projects » Virgo » How to know when virgo finished loading all plugins
How to know when virgo finished loading all plugins [message #1017270] Mon, 11 March 2013 08:11 Go to next message
Eclipse UserFriend

I need to execute some logic when my virgo server is up, and the web access is enabled.
What is the correct way to hook with the started event?
Re: How to know when virgo finished loading all plugins [message #1018800 is a reply to message #1017270] Thu, 14 March 2013 09:41 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

What about a service tracker?
Re: How to know when virgo finished loading all plugins [message #1018823 is a reply to message #1018800] Thu, 14 March 2013 10:34 Go to previous messageGo to next message
Eclipse UserFriend
Thanks for the idea,

Service tracking tracks some specific service, but as i understand the web access is disable until all plugins finish deployment, the number of plugins and their mixture can vary in our case, and i don't really know which one will be the last one.
Re: How to know when virgo finished loading all plugins [message #1018830 is a reply to message #1018823] Thu, 14 March 2013 10:45 Go to previous messageGo to next message
Eclipse UserFriend
I think that if you put your tracked service and your webapp in a scoped plan (with service starting at last), it will do the trick.
Re: How to know when virgo finished loading all plugins [message #1061261 is a reply to message #1017270] Thu, 30 May 2013 16:37 Go to previous message
Eclipse UserFriend
You can use the org.eclipse.virgo.kernel.install.artifact.InstallArtifact class to subscribe to virgo deployment events. Through this event handling, you could have logic executed when certain artifacts have been installed.

You register for start and install events by declaring an artifact lifecycle handler bean (extending org.eclipse.virgo.kernel.install.artifact.InstallArtifactLifecycleListenerSupport) in your spring context. Add them to your spring context (as follows):
<bean id="installArtifactLifecycleHandler" class="path.to.your.ArtifactLifecycleHandler" />

The org.eclipse.virgo.kernel.install.artifact.InstallArtifactLifecycleListenerSupport class has onStarted(...), onInstalled(...) event handler methods etc.

Good Luck!
Previous Topic:Virgo does not start up on Windows 2008 64 bit Virtual machine- Timeout exception thrown
Next Topic:userregionfactory failed to start (only after reboot).
Goto Forum:
  


Current Time: Wed Jul 23 02:09:46 EDT 2025

Powered by FUDForum. Page generated in 4.29069 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top