You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Miguel A Paraz <ma...@free.net.ph> on 2002/06/13 17:10:27 UTC

Proper use of ServiceLifecycle (Re: question on migrating from Soap 2.2 to Axis)

On Mon, Jun 03, 2002 at 04:22:54PM -0400, Edwards, Jeff wrote:
> I am having problems getting this to work.  I defined my service to be of
> 'application' scope and have my service impl class implementing the
> 'javax.xml.rpc.server.ServiceLifecycle' interface.  The 'init' message is
> not being called after the service is started -- for the initial call or
> subsequent calls.  Could someone explain the appropriate use of the
> 'ServiceLifecycle' interface?  Thanks in advance!


I would like to ask the same question... attached are my implementation and
deploy.wsdd.  The idea is to build the MySQL/JDBC example that was discussed
earlier. 

Thanks!


-- 
Miguel A Paraz             <http://mparaz.com>	Mobile: +63-916-423-7922
Imperium Technology, Inc.  <ma...@imperium.ph>	Office: +63-2-812-3155


Re: Proper use of ServiceLifecycle (Re: question on migrating from Soap 2.2 to Axis)

Posted by Miguel A Paraz <ma...@free.net.ph>.
On Thu, Jun 13, 2002 at 10:49:10AM -0500, Andrew Vardeman wrote:
> No, sessions aren't required.  I was describing something I'm using for 
> which the ServiceLifecycle functionality was added more recently than beta 
> 2.  Just thought maybe the functionality you're looking for was added 
> recently too.  But it sounds like your problem is something different and 
> that's all I've got, so... good luck :)

Thanks :)  It's not all that important since I'm still experimenting.

What would be another way of maintaining a persistent database connection,
connecting and disconnecting from a database upon service startup and shutdown?  

-- 
Miguel A Paraz             <http://mparaz.com>	Mobile: +63-916-423-7922
Imperium Technology, Inc.  <ma...@imperium.ph>	Office: +63-2-812-3155


Re: Proper use of ServiceLifecycle (Re: question on migrating from Soap 2.2 to Axis)

Posted by Andrew Vardeman <an...@iastate.edu>.
At 11:35 PM 6/13/2002 +0800, you wrote:
>On Thu, Jun 13, 2002 at 10:18:21AM -0500, Andrew Vardeman wrote:
> > If I remember right, Glen Daniels added a lot of ServiceLifecycle stuff
> > after beta 2.  I have an object implementing ServiceLifecycle that I store
> > in a SimpleSession, and sometime after beta 2, Glen added the 
> functionality
> > that SimpleSession would call the destroy() method on all ServiceLifecycle
> > objects it holds when the session times out.  He also mentioned some other
> > additions he'd made.  Are you running beta 2 or something later?
>
>I'm using a nightly build from Monday, June 10.
>
>I did not use any sessions.
>Are they required for "application" scope?
>I'm just using the WSDL2Java-generated stub to connect.
>
>I'll go and write code following TestSession as an example.

No, sessions aren't required.  I was describing something I'm using for 
which the ServiceLifecycle functionality was added more recently than beta 
2.  Just thought maybe the functionality you're looking for was added 
recently too.  But it sounds like your problem is something different and 
that's all I've got, so... good luck :)

Andrew



Re: Proper use of ServiceLifecycle (Re: question on migrating from Soap 2.2 to Axis)

Posted by Miguel A Paraz <ma...@free.net.ph>.
On Thu, Jun 13, 2002 at 10:18:21AM -0500, Andrew Vardeman wrote:
> If I remember right, Glen Daniels added a lot of ServiceLifecycle stuff 
> after beta 2.  I have an object implementing ServiceLifecycle that I store 
> in a SimpleSession, and sometime after beta 2, Glen added the functionality 
> that SimpleSession would call the destroy() method on all ServiceLifecycle 
> objects it holds when the session times out.  He also mentioned some other 
> additions he'd made.  Are you running beta 2 or something later?

I'm using a nightly build from Monday, June 10.

I did not use any sessions.  
Are they required for "application" scope?
I'm just using the WSDL2Java-generated stub to connect.

I'll go and write code following TestSession as an example.

-- 
Miguel A Paraz             <http://mparaz.com>	Mobile: +63-916-423-7922
Imperium Technology, Inc.  <ma...@imperium.ph>	Office: +63-2-812-3155


Re: Proper use of ServiceLifecycle (Re: question on migrating from Soap 2.2 to Axis)

Posted by Andrew Vardeman <an...@iastate.edu>.
If I remember right, Glen Daniels added a lot of ServiceLifecycle stuff 
after beta 2.  I have an object implementing ServiceLifecycle that I store 
in a SimpleSession, and sometime after beta 2, Glen added the functionality 
that SimpleSession would call the destroy() method on all ServiceLifecycle 
objects it holds when the session times out.  He also mentioned some other 
additions he'd made.  Are you running beta 2 or something later?

Andrew

At 11:10 PM 6/13/2002 +0800, you wrote:
>On Mon, Jun 03, 2002 at 04:22:54PM -0400, Edwards, Jeff wrote:
> > I am having problems getting this to work.  I defined my service to be of
> > 'application' scope and have my service impl class implementing the
> > 'javax.xml.rpc.server.ServiceLifecycle' interface.  The 'init' message is
> > not being called after the service is started -- for the initial call or
> > subsequent calls.  Could someone explain the appropriate use of the
> > 'ServiceLifecycle' interface?  Thanks in advance!
>
>
>I would like to ask the same question... attached are my implementation and
>deploy.wsdd.  The idea is to build the MySQL/JDBC example that was discussed
>earlier.
>
>Thanks!
>
>
>--
>Miguel A Paraz             <http://mparaz.com>  Mobile: +63-916-423-7922
>Imperium Technology, Inc.  <ma...@imperium.ph>    Office: +63-2-812-3155
>
>