Discussion:
mule proxy web service?
giriraj tiwari
2012-07-09 10:01:26 UTC
Permalink
Hi David, can you explore the way so that i can manage user session in mule. My scenerio is
<br /><br />
Web application( consuming web service) -- > > mule application( Generating CXF web service)
<br /><br />
e.g mule have two methods like
<br /><br />
LdapContext login(username, password) &
<br />
String resetPassword( String username, LdapContext context)
<br /><br />
where LdapContext is not serilized
<br /><br />
my question is how can I manage the ldapContext object in mule so after login, whent user sends the request for resetPassword() thyen I can use the same ldapCOntext object which we got from login(). I don't want to pass the context to webapplication.
<br />
I want to keep it in mule itself.
<br /><br />
Thanks in advance.

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email
David Dossot
2012-07-09 23:57:45 UTC
Permalink
Since LdapContext is not serializable, you'll have to create an in memory map of sessionId -> ldapContext. When login succeeds, create a sessionId (for ex. with a UUID) and return it to the caller of the web service. For resetPassword, have the client provide its session ID to look-up the related LdapContext. Use EhCache for this in-memory map to benefit from features like self eviction of old entries, etc...

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email
giriraj tiwari
2012-07-11 07:17:46 UTC
Permalink
Thanks David for the reply. I am very happy for your faster reply.
<br /><br />
The way to do this I understood but can you elaborate the way in depth so I can do hands-on it, in the technical manner instead of only theoretically concepts. It will be great if you provide any sample code/application for that.
<br /><br />
Thanks in advance.

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email
David Dossot
2012-07-11 16:59:46 UTC
Permalink
Not really otherwise I'll be doing your work :) More seriously, if you understand what I'm proposing, what's holding you from doing it? Anything specific I can clarify?

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Loading...