You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Rodrigo Madera <ro...@gmail.com> on 2007/09/22 10:57:32 UTC

Declarative Services and Internet Servers

Following my series of OSGi questions, now it's time for DS start/stop.

Let' s say that I have the GreeterServer, which listens on the TCP port N.

If I were to use an activator, I would wrap the activator's stop method, so
I could stop the server correctly (doing proper cleanup). However, with DS
this looks kind of automatic and focused on instances.

Maybe I'm missing something, but how would you implement cleanup and proper
close of the server using DS?

Thanks for all the input,
Rodrigo

Re: Declarative Services and Internet Servers

Posted by Rodrigo Madera <ro...@gmail.com>.
I'll look into the gory details of the DS spec and restate.

Thanks,
Rodrigo

On 9/23/07, Felix Meschberger <fm...@gmail.com> wrote:
>
> Hi,
>
> Well, not sure, whether I completely understand your question.
>
> But, if your GreeterServer is a component, you would start listening in
> the activate method, which compares to the BundleActivator.start method.
> Likewise, you clean up and stop listening in the deactivate method,
> which compares to the BundleActivator.stop method.
>
> Regards
> Felix
>
> Am Samstag, den 22.09.2007, 05:57 -0300 schrieb Rodrigo Madera:
> > Following my series of OSGi questions, now it's time for DS start/stop.
> >
> > Let' s say that I have the GreeterServer, which listens on the TCP port
> N.
> >
> > If I were to use an activator, I would wrap the activator's stop method,
> so
> > I could stop the server correctly (doing proper cleanup). However, with
> DS
> > this looks kind of automatic and focused on instances.
> >
> > Maybe I'm missing something, but how would you implement cleanup and
> proper
> > close of the server using DS?
> >
> > Thanks for all the input,
> > Rodrigo
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>
>

Re: Declarative Services and Internet Servers

Posted by Felix Meschberger <fm...@gmail.com>.
Hi,

Well, not sure, whether I completely understand your question.

But, if your GreeterServer is a component, you would start listening in
the activate method, which compares to the BundleActivator.start method.
Likewise, you clean up and stop listening in the deactivate method,
which compares to the BundleActivator.stop method.

Regards
Felix

Am Samstag, den 22.09.2007, 05:57 -0300 schrieb Rodrigo Madera:
> Following my series of OSGi questions, now it's time for DS start/stop.
> 
> Let' s say that I have the GreeterServer, which listens on the TCP port N.
> 
> If I were to use an activator, I would wrap the activator's stop method, so
> I could stop the server correctly (doing proper cleanup). However, with DS
> this looks kind of automatic and focused on instances.
> 
> Maybe I'm missing something, but how would you implement cleanup and proper
> close of the server using DS?
> 
> Thanks for all the input,
> Rodrigo


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org