axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tim, Jane and Chelsea Johnson" <>
Subject Re: [Axis2] Session Management and WS-Addressing
Date Wed, 17 Jan 2007 22:41:01 GMT
Thanks for replying. Yes, I read that article. That is why I am stumped as to why my service
doesn't response with the correct headers when the client calls it the first time with the
correct WS-Addressing headers. Do I have to build the WS-Addressing headers by hand or should
Axis2 build them for me automatically? 

When you deploy a service in SOAP session and when a client tries to access the service in
the first time, Axis2 will generate serviceGroupId and send that to the client as a reference
parameter in wsa:ReplyTo, as shown below:

      <axis2:ServiceGroupId xmlns:axis2=
If the client wants to live in the same session, he has to copy that reference parameter and
send it back to the server when he invokes the service the second time. As long as a client
sends the valid serviceGroupId, he can use the same session, and the service can maintain
the session-related data. Unlike a request session, a SOAP session has a default timeout period,
so if the client does not touch the service for 30 seconds, the session will expire, and if
the client sends the old serviceGroupId, he will get an AxisFault too.

  ----- Original Message ----- 
  From: Brian De Pradine 
  Sent: Wednesday, January 17, 2007 7:52 AM
  Subject: Re: [Axis2] Session Management and WS-Addressing


  You may find the following link useful, [1] 



  Brian DePradine
  Web Services Development
  IBM Hursley
  External  +44 (0) 1962 816319         Internal 246319

  If you can't find the time to do it right the first time, where will you find the time to
do it again?

  "Tim, Jane and Chelsea Johnson" <> wrote on 17/01/2007 00:54:12:

  > I am running the latest version of axis2 - 1.1.1. I am trying to use session 
  > management via WS-Addressing.
  > In soapmonitor I can see the WS-Addressing headers going out on the request 
  > to the server. But my service's response doesn't have any of the 
  > WS-Addressing headers (specifically the groupID header). Addressing is 
  > enabled globally via the entry in Axis2.xml. In service.xml I set scope for 
  > the service to be "soapsession".
  > This is what the client is sending. Is there something I need to add or 
  > change to get the service to re-act with WS-Addressing headers.
  > <?xml version='1.0' encoding='utf-8'?>
  > <soapenv:Envelope xmlns:wsa="" 
  > xmlns:soapenv="">
  >   <soapenv:Header>
  >     <wsa:To>http://localhost:8080/axis2/services/AiMessageServices</wsa:To>
  >     <wsa:ReplyTo>
  >       <wsa:Address>http://www.w3.
  > org/2005/08/addressing/anonymous</wsa:Address>
  >     </wsa:ReplyTo>
  >     <wsa:MessageID>urn:uuid:F18B205BFF468A597911689950656872</wsa:MessageID>
  >     <wsa:Action>urn:login</wsa:Action>
  >   </soapenv:Header>
  >   <soapenv:Body>
  >     <Reqx>
  >       <HID>124</HID>
  >       <CID>2567</CID>
  >       <ReqNo>SJPC120.y</ReqNo>
  >       <CRYR>2003</CRYR>
  >     </Reqx>
  >   </soapenv:Body>
  > </soapenv:Envelope> 
  > ---------------------------------------------------------------------
  > To unsubscribe, e-mail:
  > For additional commands, e-mail:

View raw message