Skip to Content
author's profile photo Former Member
Former Member

Problems using a webservice with session activation


I´m trying to access a webservice that holds a session for every user.

My problem is, that whenever i use a method, a new session on my webservice server is cerated, although I use the same webservice instance on the client side.

Example :

IMyWebService myWebService = (IMyWebService)PortalRuntime.getRuntimeResources().getService("myProject.MySampleWS");

myWebService.doLogin(username, pwd);


This code produces two sessions on my webservice server, so that getUserInfos() fails,because it uses a different session than doLogin.

Does anyone know how I can use the same session as long as I am using the same instance of IMyWebService ?



Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Apr 29, 2004 at 11:16 AM


    the solution to your problem mainly depends on how your webservice server is implementing sessions.

    The normal "http-server-way" won't work here. (Http-Servers normally use cookies or insert session-ids in the respective html files for tracking a session)

    For example webservice-servers can send a session-id as the return-type of a call to some login method. This session-id then has to be used (by the client) as a parameter in subsequent calls to that webservice.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.