Craig R. McClanahan wrote:
>Geoff Soutter wrote:
>
>> I had an unusual requirement where I needed to have two client programs
>> share a session, one which supported cookies and one which didn't. The
>> session was created for the first client and then had to be passed to the
>> second client. How could I do this? The servlet API doesn't allow me to
>> _force_ a URL to be encoded. So, I passed the session ID in the URL using
my
>> own session encoding scheme. However, in order to do this, I needed
>> context.getSession(id) to figure out the session for the session ID when
the
>> URL came back in.
>
>IMHO, this problem should be dealt with at the implementation level, not
the
>API level.
>
>If your servlet engine allows you to configure whether cookies are used for
>session ID maintenance at all, you don't need any changes to the API. In
>essence, this would set your "force" flag to true on all encodeURL calls,
>without requiring any changes to the API itself.
I agree this is an option, but most of our page serves don't require URL
re-writing so why should we mandate it? I think the API should be flexible
enough to let us use URL re-writing when required and cookies when not if
this is what we want. After all, it's a tiny change to the API - though I
guess thats easy for me to say :-)
>If your servlet engine doesn't support this, I would certainly lobby your
>engine provider to include it. Besides the issue raised here, this also
takes
>care of the issue of multiple browser windows to the same application being
>considered part of the same session in some browsers but not others --
WITHOUT
>requiring any application changes at all, which solving it at the API level
>would require.
Hmmm, yes that always was a nasty one. :-)
Cheers,
Geoff
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html