Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Virgo » Hot deployment of plan bundle
Hot deployment of plan bundle [message #989288] Wed, 05 December 2012 14:42 Go to next message
Seth Helstrip is currently offline Seth Helstrip
Messages: 22
Registered: September 2012
Junior Member
Hi there,
Wondering whether someone can help me with a Virgo hot deployment question.

I have an application, that has been wired together, using a plan. The bundles used by the application are installed in the usr repo, and then deployed using a plan in the pickup dir.

What I want to be able to do, within a development environment, is to refresh a bundle, within a plan. i.e. If say, I make a change to my model module, to be able to re-deploy it to the usr repo, and for that change to be dynamically included within my application plan. I intend to do the deployment via the Virgo mvn plugin, but need to know how to get the plan to update to include the new binary. The binary is not envisaged (ideally) to have an increment in bundle version.

Anyone know how this is possible?
Re: Hot deployment of plan bundle [message #989708 is a reply to message #989288] Fri, 07 December 2012 11:23 Go to previous messageGo to next message
Glyn Normington is currently offline Glyn Normington
Messages: 1222
Registered: July 2009
Senior Member
No, it's not possible, I'm afraid.

Firstly, Virgo repositories never initiate deployment or redeployment. They are passive repositories from which Virgo pulls artefacts. Watched directories are monitored to keep the repository index up to date, but even these are still passive from a deployment perspective.

Secondly, there is no API for updating an individual bundle within a plan, although there is for PARs since the tooling support for PARs is somewhat ahead of that for plans. You may care to raise an enhancement request.
Re: Hot deployment of plan bundle [message #990241 is a reply to message #989708] Tue, 11 December 2012 14:42 Go to previous messageGo to next message
Seth Helstrip is currently offline Seth Helstrip
Messages: 22
Registered: September 2012
Junior Member
Thanks for that Glyn
Re: Hot deployment of plan bundle [message #990257 is a reply to message #989288] Tue, 11 December 2012 15:59 Go to previous messageGo to next message
Charles Vuijst is currently offline Charles Vuijst
Messages: 1
Registered: July 2009
Junior Member
Hi all,

Searching the forum I encountered this thread for which I assume my question might be related.

In our product we have an option to dynamically add database drivers to the Virgo container. This enables our customers to use any vendor's flavor they like. We wrote a wrapper tool which generates a wrapped jar as OSGi bundle to expose a service via a predefined interface and also generates a plan-file.

Attached is a zip-file containing a (mysql driver) bundle and the plan file.
The bundle we store in the repository/usr folder and the plan in the pickup folder.

When we want to remove the additional driver (we first make sure that it is not used anymore) by removing the plan file from the pickup folder, we encounter exceptions as shown in the attached General.log file.
The stacktrace mentions something about startup while it's originated from a bundle stop. We also tried to execute a similar scenario with a helloworld bundle; that gave a similar result.

At the end, everything works ok even unloading, replacing the driver by a new version, loading and executing!
However, we see Errors in the log which we and our customers do not like.
Anyone might explain the Error and how to prevent this?

See attached log, error:
java.lang.RuntimeException: Bundle 'com.infor.ion.mysql_5.1.6.r004 [186]' stopped.


Best regards,

Charles
Re: Hot deployment of plan bundle [message #990408 is a reply to message #990257] Wed, 12 December 2012 10:41 Go to previous message
Glyn Normington is currently offline Glyn Normington
Messages: 1222
Registered: July 2009
Senior Member
Charless - I can't easily explain that behaviour. It's possible that your customers are more observant than most and that this is a regular occurrence. If you can package up a trivial testcase to reproduce the problem, please feel free to raise a bug. However, I would encourage you to use a debugger first to try to understand what's going on - since you embed Virgo in ION, it would be a good investment to have some Virgo skills in house. Smile
Previous Topic:Spring Annotation Driven Controller in different bundles
Next Topic:3.6.0.M05 released
Goto Forum:
  


Current Time: Fri Oct 31 10:58:56 GMT 2014

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

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