Vadim
--
Resistance is futile.
> -----Original Message-----
> From: Holden Robbins [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, June 12, 2002 10:14 PM
> To: [EMAIL PROTECTED]
> Subject: Generating XML with URLs that use Sessions
>
>
> Hi,
>
> I've recently come across a major stumbling block in converting my
servlet
> based site to use Cocoon. I'm hoping to use cocoon instead of having
each
> individual servlet having the XSL transformations hard coded and doing
it
> themselves.
>
> The problem is that the servlets use session variables and the
JSessionId
> cookie is lost when the URL of the servlet is called through cocoon
file
> generator.
>
> 0 /---\ /---\
> /|\ JSessionID | | nada | |
> | ---------> | | ------> | |
> / \ \---/ \---/
>
> Client Cocoon Servlets
> File Generator
>
>
> I don't see any way to set headers or get headers from cocoon
generators.
> Which means I can't grab the JSessionId from the header in the
response
> returned by the servlet and I can't set the JSessionId in the header
for
> the request to the servlet.
>
> Is there an easy solution to this problem that I'm missing?
1. Have your servlets deployed together with Cocoon in one webapp
2.
...
<map:act type="get-session-id">
<map:generate
src="http://host:port/cocoon/old-servlet;jsessionid={session-id}"/>
</map:act>
...
should work.
Vadim
>
> My only choice seem to be re-write each of the servlets as a cocoon
> generator which I'm not sure I want to do.
>
> Thanks,
> -Holden
>
---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faq/index.html>
To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>