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 di...@gmx.at on 2008/06/17 11:29:47 UTC

modules and sessionid

hi, 

i have the following problem:

in my scenario a client sends a soaprequest containing a header with a sessionid, username and password. my custom module then checks if the sessionid is valid and generates a new sessionid if necessary. 
my question is how to add this (new generated) sessionid to the header of the soapresponse. 

i'm using generated classes from my wsdl.

regards, 

florian
-- 
Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! 
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer

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


Re: modules and sessionid

Posted by Florian Astl <di...@gmx.at>.
hi, 

that works, thank you very much!

Florian

> 
> > hi, 
> >
> > i have the following problem:
> >
> > in my scenario a client sends a soaprequest containing a header with a
> sessionid,
> I suppose which has nothing to do with Axis2 session management ?
> >  username and password. my custom module then checks if the sessionid is
> valid and generates a new sessionid if necessary. 
> > my question is how to add this (new generated) sessionid to the header
> of the soapresponse. 
> >   
> For this you need to have one more handler which will be there in the 
> out flow. And that handler will be add the custom header. You can 
> generate the header and add that to the operation context when the 
> message receive , and the handler in the out flow and get that value and 
> set that to out going SOAP message,
> 
> Thank you!
> Deepal
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org

-- 
Ist Ihr Browser Vista-kompatibel? Jetzt die neuesten 
Browser-Versionen downloaden: http://www.gmx.net/de/go/browser

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


Re: modules and sessionid

Posted by Deepal Jayasinghe <de...@opensource.lk>.
> hi, 
>
> i have the following problem:
>
> in my scenario a client sends a soaprequest containing a header with a sessionid,
I suppose which has nothing to do with Axis2 session management ?
>  username and password. my custom module then checks if the sessionid is valid and generates a new sessionid if necessary. 
> my question is how to add this (new generated) sessionid to the header of the soapresponse. 
>   
For this you need to have one more handler which will be there in the 
out flow. And that handler will be add the custom header. You can 
generate the header and add that to the operation context when the 
message receive , and the handler in the out flow and get that value and 
set that to out going SOAP message,

Thank you!
Deepal



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


Re: modules and sessionid

Posted by di...@gmx.at.
Azeezl, as far as i understood the documentation, in your proposal the client receives an axisfault when using an outdated sessionid, right? but instead of sending an error i need to create a new sessionid (and a sessionobject with various information my serviceoperations use) in my module. the sessionobject is identified by the sessionid. 
the problem of sending back the (new) sessionid to the client in the soapheader still remains.

Florian

> Why aren't  you deploying the service in the soapsession scope and use
> addressing? In this case, the session aware functionality will be
> available
> to you out of the box.
> 
> Azeez
> 
> On Tue, Jun 17, 2008 at 2:59 PM, <di...@gmx.at> wrote:
> 
> > hi,
> >
> > i have the following problem:
> >
> > in my scenario a client sends a soaprequest containing a header with a
> > sessionid, username and password. my custom module then checks if the
> > sessionid is valid and generates a new sessionid if necessary.
> > my question is how to add this (new generated) sessionid to the header
> of
> > the soapresponse.
> >
> > i'm using generated classes from my wsdl.
> >
> > regards,
> >
> > florian
> > --
> > Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen!
> > Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-user-help@ws.apache.org
> >
> >
> 
> 
> -- 
> Thanks
> Afkham Azeez
> 
> http://afkham.org
> http://www.wso2.org
> GPG Fingerprint: 643F C2AF EB78 F886 40C9 B2A2 4AE2 C887 665E 0760

-- 
Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! 
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer

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


Re: modules and sessionid

Posted by Afkham Azeez <af...@gmail.com>.
Why aren't  you deploying the service in the soapsession scope and use
addressing? In this case, the session aware functionality will be available
to you out of the box.

Azeez

On Tue, Jun 17, 2008 at 2:59 PM, <di...@gmx.at> wrote:

> hi,
>
> i have the following problem:
>
> in my scenario a client sends a soaprequest containing a header with a
> sessionid, username and password. my custom module then checks if the
> sessionid is valid and generates a new sessionid if necessary.
> my question is how to add this (new generated) sessionid to the header of
> the soapresponse.
>
> i'm using generated classes from my wsdl.
>
> regards,
>
> florian
> --
> Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen!
> Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>


-- 
Thanks
Afkham Azeez

http://afkham.org
http://www.wso2.org
GPG Fingerprint: 643F C2AF EB78 F886 40C9 B2A2 4AE2 C887 665E 0760