You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@servicemix.apache.org by Guillaume Nodet <gn...@gmail.com> on 2009/02/23 14:53:18 UTC

[DISCUSS] JBI lifecycle / OSGi lifecycle

Just want to raise the following issue on the dev list.
Currently, in ServiceMix 4 NMR, all the JBI lifecycle happens while
the bundle is started.
The drawback is start installation / uninstallation of JBI components
are performed each time the bundle is started / stopped.
I was wondering if we should tie the two lifecycles together a bit more:
  * perform JBI installation when the bundle is installed (i.e.
bootstraping and such)
  * perform JBI uninstallation when the bundle is uninstalled
For the start / stop / shutdown state, I'm not sure.
Imho, when the bundle is stopped, nothing should happen at all, so it
would related to the shutdown state in JBI, while both start / stop
operations would happen when the OSGi bundle is active.  I think this
would make more sense, but I'm not sure if we can really do that:
iirc, a stopped bundle will have all its registered services
unregistered automatically by the OSGi framework, so I'm not so sure
we can really have a shutdown state (i.e. still access the component)
while the bundle is stopped.   If not, that would mean the all three
states are managed as of now, and the only change would be that the
jbi installation / uninstallation process would happen when the OSGi
bundle is installed / uninstalled.

Thoughts ?

-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/
------------------------
Open Source SOA
http://fusesource.com

Re: [DISCUSS] JBI lifecycle / OSGi lifecycle

Posted by jb...@nanthrax.net.
+1 to link the JBI install/uninstall with the bundle one.

Regards
JB

On Monday 23 February 2009 - 14:53, Guillaume Nodet wrote:
> Just want to raise the following issue on the dev list.
> Currently, in ServiceMix 4 NMR, all the JBI lifecycle happens while
> the bundle is started.
> The drawback is start installation / uninstallation of JBI components
> are performed each time the bundle is started / stopped.
> I was wondering if we should tie the two lifecycles together a bit more:
>   * perform JBI installation when the bundle is installed (i.e.
> bootstraping and such)
>   * perform JBI uninstallation when the bundle is uninstalled
> For the start / stop / shutdown state, I'm not sure.
> Imho, when the bundle is stopped, nothing should happen at all, so it
> would related to the shutdown state in JBI, while both start / stop
> operations would happen when the OSGi bundle is active.  I think this
> would make more sense, but I'm not sure if we can really do that:
> iirc, a stopped bundle will have all its registered services
> unregistered automatically by the OSGi framework, so I'm not so sure
> we can really have a shutdown state (i.e. still access the component)
> while the bundle is stopped.   If not, that would mean the all three
> states are managed as of now, and the only change would be that the
> jbi installation / uninstallation process would happen when the OSGi
> bundle is installed / uninstalled.
> 
> Thoughts ?
> 
> -- 
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
> ------------------------
> Open Source SOA
> http://fusesource.com

Re: [DISCUSS] JBI lifecycle / OSGi lifecycle

Posted by Freeman Fang <fr...@gmail.com>.
+1 for bind JBI installation/uninstallation to bundle 
installation/uninstallation.
Also +1 for when stop JBI component bundle, then the JBI lifecyle should 
be SHUTDOWN if  it's possible.
Freeman

Guillaume Nodet wrote:
> Just want to raise the following issue on the dev list.
> Currently, in ServiceMix 4 NMR, all the JBI lifecycle happens while
> the bundle is started.
> The drawback is start installation / uninstallation of JBI components
> are performed each time the bundle is started / stopped.
> I was wondering if we should tie the two lifecycles together a bit more:
>   * perform JBI installation when the bundle is installed (i.e.
> bootstraping and such)
>   * perform JBI uninstallation when the bundle is uninstalled
> For the start / stop / shutdown state, I'm not sure.
> Imho, when the bundle is stopped, nothing should happen at all, so it
> would related to the shutdown state in JBI, while both start / stop
> operations would happen when the OSGi bundle is active.  I think this
> would make more sense, but I'm not sure if we can really do that:
> iirc, a stopped bundle will have all its registered services
> unregistered automatically by the OSGi framework, so I'm not so sure
> we can really have a shutdown state (i.e. still access the component)
> while the bundle is stopped.   If not, that would mean the all three
> states are managed as of now, and the only change would be that the
> jbi installation / uninstallation process would happen when the OSGi
> bundle is installed / uninstalled.
>
> Thoughts ?
>
>