- Posted by: Maciej Zywno
- Posted on: February 20 2004 11:51 EST
I would like to add webservice interface to a legacy application, but I am completely new to webservices(although I know the idea of course). I am trying to find out if there is any standard for saving a state while talking to a webservice.
I know that it is preferable to treat a webservice as a black box, but due to the fact that I deal with a legacy system, I suppose I will have to have a webservice session anyway.
I heard something about a SOAP extension that enables saving state in a SOAP header.
Can you suggest some links or papers or maybe a brief solution to my problem?
Firstly, Web Services (WS), at present,are stateless. WSDL 1.1 does not allow one to describe a WS as stateful. However, WSDL 1.2 will allow one to describe Grid Services, and hence stateful services. Maybe a fellow community member can give us some implementation specifics on this...
Also, I would say this could be handled differently depending on whether you are creating an RPC or a Document-Literal Web Service interface. A Doc-Lit interface doesnt describe the data coming over the wire at all and hence if you and your integration partner can agree on an integration architecture and XML Schema that allows one to pass information about state, then this is possible. This is a common scenario in the B2Bi space where folks have built stateful XML SOA Document Literal interfaces with their own proprietary state handling mechanisms within their proprietary xml message schema.
And in addition... there is a difference between a stateful interface and a message schema that can pass state around. I would really like to hear how other folks in the industry are feeling my pain, and what they are doing about it.
Integration Middleware Architect, IBM
A service oriented architecture is by definition stateless. You should give the service all the data it needs or you could save that data in the database and give the service the keys to access this data.
Hope this helps,