1 Reply Latest reply on Apr 21, 2008 10:29 AM by ulrike

    How to develop a WebServiceClient correctly?

    ulrike

      Currently I’m using Apache CXF (XFire) for accessing some Seam services. I managed it to maintain session state of one service, but I need some further help with different services using the same session.
      A usual scenario would be following:



      • a registered user logs in (name, pwd) – AuthenticationService

      • invokes some methods of Service A

      • same with other methods of Service B


      • user logs out - AuthenticationService



      How do I pass the session-state from one service to another? If CXF was the wrong choice, I have an open mind about using something similar.
      How can I keep the current (web service) session till the user logs out?


      I’m able to simulate this using the test.xhtml of the seambay example, but I would prefer Java classes to JavaScript for accessing the service.

        • 1. Re: How to develop a WebServiceClient correctly?
          ulrike

          And again I'm replying to myself...


          There was just one missing line that separated me from enlightenment. ;)


          requestContext.put(MessageContext.HTTPREQUESTHEADERS, requestHeaders);


          I forgot to put the requestHeaders back into the requestContext... Maybe I need a little break.