Re: [Architecture] A mechanism to communicate server shutdown to the bundles, just before actual server shutdown

2014-09-15 Thread Jayanga Dissanayake
Hi Harshan, What we want here is to notify the bundles just before the server shutdown, If we register the service in the server start up, that service get activated and all the dependent bundles get notified about that in the server start up. In this case, we are delaying the service

Re: [Architecture] A mechanism to communicate server shutdown to the bundles, just before actual server shutdown

2014-09-14 Thread Jayanga Dissanayake
Hi Amila, Sorry about the confusion. Generally, in OSGi bundles, we register services provided by a particular bundle in the bundle activation, That is true. But in this scenario, I am registering the CarbonServerShutdownPrepareService in the

Re: [Architecture] A mechanism to communicate server shutdown to the bundles, just before actual server shutdown

2014-09-14 Thread Harshan Liyanage
Hi Jayanga, Why can't register the CarbonServerShutdownPrepareService in normal OSGi service registration manner (without registering it in server shutdown)? Is that because you need to have synchronized manner or any other particular reason to do so? Thanks, Best Regards, Lakshitha Harshan

Re: [Architecture] A mechanism to communicate server shutdown to the bundles, just before actual server shutdown

2014-09-13 Thread Amila Maha Arachchi
On Thu, Sep 11, 2014 at 10:47 PM, Jayanga Dissanayake jaya...@wso2.com wrote: Hi, There was a requirement to detect the server shutdown from some bundles before the OSGi framework begin to shutdown. Because there were situations where some bundle have there own transports. If server

[Architecture] A mechanism to communicate server shutdown to the bundles, just before actual server shutdown

2014-09-11 Thread Jayanga Dissanayake
Hi, There was a requirement to detect the server shutdown from some bundles before the OSGi framework begin to shutdown. Because there were situations where some bundle have there own transports. If server shutdown happens while there were buffered messages, those should be processes before that

Re: [Architecture] A mechanism to communicate server shutdown to the bundles, just before actual server shutdown

2014-09-11 Thread Aruna Karunarathna
Hi Jayanga, Please see my inline comments. On Fri, Sep 12, 2014 at 9:17 AM, Jayanga Dissanayake jaya...@wso2.com wrote: Hi, There was a requirement to detect the server shutdown from some bundles before the OSGi framework begin to shutdown. Because there were situations where some bundle