Re: use SOAP header for asp.net session state
- From: "InvalidLastName" <spamme@xxxxxxxxxxxxx>
- Date: Wed, 15 Nov 2006 19:19:33 -0500
Thank for all your responses.
Some background here. We are creating web services for our customer to get data in and out of the system. The web services can be consumed by any type of applications.
I totally agree the web services should stateless, and currently we actually don't need to maintain state between the calls.
We are planning to create a custom authentication ticket, which will be passed within SOAP header. I am not looking for a solution to use SOAP header to maintain "cookie", I am just want to make sure ASP.NET doesn't support SOAP header based session management, and we won't encounter any compatibility issue in the future if we do need to maintain session state for some odd reasons.
Interesting enough, I believe SQL server 2005 web services is actually using SOAP header to maintain session state. The SQL Server Reporting Services also saves execution ID, which is equivalent to session id, in SOAP header to maintain session state. That's why I really want to make sure SOAP header is not a valid session state management option is ASP.NET 2.0
Other alternative approaches, which provide minimum state management, are very welcome.
Thanks
"Steven Cheng[MSFT]" <stcheng@xxxxxxxxxxxxxxxxxxxx> wrote in message news:b6mnx0ICHHA.4752@xxxxxxxxxxxxxxxxxxxxxxxx
Thanks for John's input.
Hi InvalidLastName,
I agree with John, actually XML webservice is designed as stateless and
connectionless. As for both application Cache or SessionState, they're
specific to the ASP.NET web application, ASP.NET include it in case both
the client and server-side use .net framework. When use SessionState, if
you use .net framework to generate the client proxy, it will use the
HttpWebRequest class to send/receive webservice request/response SOAP
message. And for HttpWebRequest class, it has a Cookie property which is of
CookieContainer type. This is how .net webservice client proxy keep the
cookie returned from server-side ASP.NET webservice(if we've used).
So the problem here is whether your webservice will be consumed by any
other non-dotnet platform? If so, using cookie is not a good idea, and so
far I haven't found any standard specification on use SOAP Header to
maintain cookie since it is not included in the webservice standard.
BTW, would you provide some further details on your scenario and why you
would use cookie (to keep any state) in your webservice client & server? I
think we may have a look for some other alternative approachs.
Please feel free to post here if you have any questions or other concerns.
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
- Follow-Ups:
- Re: use SOAP header for asp.net session state
- From: John Saunders
- Re: use SOAP header for asp.net session state
- References:
- use SOAP header for asp.net session state
- From: InvalidLastName
- Re: use SOAP header for asp.net session state
- From: Steven Cheng[MSFT]
- use SOAP header for asp.net session state
- Prev by Date: Re: Can't authenticate to lists.asmx web service
- Next by Date: Re: Calling Web Service Asynchronously
- Previous by thread: Re: use SOAP header for asp.net session state
- Next by thread: Re: use SOAP header for asp.net session state
- Index(es):
Relevant Pages
|