You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@aries.apache.org by Thiago Souza <tc...@gmail.com> on 2011/03/21 22:43:04 UTC

Question about service reference

Hi,

   Is there any way to instruct aries to shutdown and put a context in grace
period in case of a reference goes away (instead of keeping the context
created with an unsatisfied reference)?

Regards
Thiago Souza

Re: Question about service reference

Posted by Thiago Souza <tc...@gmail.com>.
Hi Valentin,

     First of all, thanks for you reply.

     Actually I didn't know about this. Currently I'm porting a system
implemented using camel + spring dm to camel-blueprint. In the current
implementation a running camel context is shutdown whenever a service
belonging to it's dependency graph goes offline and this is the
expected/desired behavior. As far as I can remember this is happens because
the spring contexts that build up the service dependecy graph goes offline
whenever a service belonging to it goes offline too.

     Now, using blueprint I see that the blueprint contexts that build up
the dependency graph stays online and, IMO, this is quite interesting.
     Althought, as I didn't test this yet, I'm concerned what will happen
with the blueprint-based camel context whenever a service connected to it
(no matter how deep) goes offline. My desired behavior is that, as before,
the camel context goes offline as well (and rollingback all active
transactions).
     What I don't want is that the camel context stays online, with it's
threads suspended waiting for a reference to become satisfied, or even
worse, that any interaction with the service throws
ServiceUnavailableException and triggering the camel context's exception
handling.

Regards,
Thiago Souza

On Tue, Mar 22, 2011 at 05:03, Valentin Mahrwald
<vm...@googlemail.com>wrote:

> Hi Thiago,
>
> There is no way that I am aware of to do that. In the spec (121.3) a
> Blueprint will only enter the grace period during the initialization phase
> to wait for mandatory references. Once it is created it won't go back.
> However, if a reference becomes untracked, services depend on it should be
> become unregistered, so to the external world it should look like a partial
> shutdown ...
>
> What is the scenario you would like to do this in?
>
> Regards,
>
> Valentin
>
> On 21 Mar 2011, at 21:43, Thiago Souza wrote:
>
> > Hi,
> >
> >    Is there any way to instruct aries to shutdown and put a context in
> grace period in case of a reference goes away (instead of keeping the
> context created with an unsatisfied reference)?
> >
> > Regards
> > Thiago Souza
>
>

Re: Question about service reference

Posted by Valentin Mahrwald <vm...@googlemail.com>.
Hi Thiago,

There is no way that I am aware of to do that. In the spec (121.3) a Blueprint will only enter the grace period during the initialization phase to wait for mandatory references. Once it is created it won't go back.
However, if a reference becomes untracked, services depend on it should be become unregistered, so to the external world it should look like a partial shutdown ...

What is the scenario you would like to do this in?

Regards,

Valentin

On 21 Mar 2011, at 21:43, Thiago Souza wrote:

> Hi,
> 
>    Is there any way to instruct aries to shutdown and put a context in grace period in case of a reference goes away (instead of keeping the context created with an unsatisfied reference)?
> 
> Regards
> Thiago Souza