axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "SCHEDENIG Marian" <Marian.Schede...@qualysoft.com>
Subject RE: Sessions with Axis2
Date Mon, 19 Mar 2007 12:48:42 GMT
> -----Original Message-----
> From: Stadelmann Josef [mailto:josef.stadelmann@winterthur.ch] 
> Sent: Donnerstag, 15. März 2007 14:39
> To: axis-user@ws.apache.org
> Subject: AW: Sessions with Axis2
> 
> That happens mainly in a time-out-condition.
> 
> I wonder why you do not see the SOAP fault such as "invalid 
> Service Group ID"
> text returned from the server in the sopa message.

I have a feeling that my server and/or client are not aware there should be sessions in the
first place.

> But further to that there are some problems with scope=soapsession
> 
> Look at my JIRA-1991 to get more insigth, even if it is not 
> the final solution better then nothing.

I updated the timeout to 30000, but nothing has changed.

> maybe you should (if not done so) implement init() and 
> destroy() to your service
> and have a logger defined at the server side to logg all 
> calles when they arrive. 
> Then look into the tomcat stdout-nnnnnnn.log and see what 
> your server does. 

I have those already. This is what I get (I'm putting spaces between the threads/calls to
make it a bit clearer):

2007-03-19 13:30:48,175 [http-8090-Processor24] DEBUG axissessiontest.server.AxisSessionTestService
- Service initialised.
2007-03-19 13:30:48,191 [http-8090-Processor24] DEBUG axissessiontest.server.AxisSessionTestService
- Service group context ID: urn:uuid:46D8B81A2EB81601091174307448176
2007-03-19 13:30:48,191 [http-8090-Processor24] DEBUG axissessiontest.server.AxisSessionTestService
- Logged in: tex
2007-03-19 13:30:48,207 [http-8090-Processor24] DEBUG axissessiontest.server.AxisSessionTestService
- Initialised count.

2007-03-19 13:30:48,285 [http-8090-Processor25] DEBUG axissessiontest.server.AxisSessionTestService
- Service initialised.
2007-03-19 13:30:48,285 [http-8090-Processor25] DEBUG axissessiontest.server.AxisSessionTestService
- Service group context ID: urn:uuid:46D8B81A2EB81601091174307448288
2007-03-19 13:30:48,285 [http-8090-Processor25] DEBUG axissessiontest.server.AxisSessionTestService
- Must login first.

2007-03-19 13:30:48,316 [http-8090-Processor23] DEBUG axissessiontest.server.AxisSessionTestService
- Service initialised.
2007-03-19 13:30:48,316 [http-8090-Processor23] DEBUG axissessiontest.server.AxisSessionTestService
- Service group context ID: urn:uuid:46D8B81A2EB81601091174307448321
2007-03-19 13:30:48,316 [http-8090-Processor23] DEBUG axissessiontest.server.AxisSessionTestService
- Must login first.

"Service initialised" is logged in the init() method. The destroy() method would log "Service
destroyed.", so clearly that never gets called. The first thing I do when one of my service
methods is called is to log the group context ID (I'm not entirely sure, but it seems to me
that this should be the session ID?), which is different for every call. "Logged in" and "Initialised
count" are the correct output for a call to the login() method. The subsequent calls to count()
would return an increasing number if login() had been called in the same session, but as the
session is not recognised, they log "Must login first." instead.

Here's my client initialisation code:

  endpoint = new EndpointReference("http://localhost:8090/axis2_new/services/AxisSessionTestService");
  serviceClient = new RPCServiceClient();

  Options options = serviceClient.getOptions();
  options.setTo(endpoint);
  options.setManageSession(true);

And this is what a call to the login service method looks like (count is similar, except for
the parameters):

  QName opExecute = new QName("http://server.axissessiontest/xsd", "login");
  Object[] opExecuteArgs = new Object[] {user, password};
  Class[] returnTypes = new Class[] { Boolean.class };

  Object[] response = serviceClient.invokeBlocking(opExecute, opExecuteArgs, returnTypes);

Looks to me like I'm doing everything right?

Thx,
Marian.

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Mime
View raw message