jQuery in Action, 3rd edition
The moose likes Struts and the fly likes Tomcat + Struts no jsessionid cookie. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Tomcat + Struts no jsessionid cookie." Watch "Tomcat + Struts no jsessionid cookie." New topic

Tomcat + Struts no jsessionid cookie.

Torben Riis

Joined: Aug 26, 2003
Posts: 3
I realy hope someone can help me! :-)
I have just finnished a web project using Struts. It deploys fine i WebSphere 5, but when it is deployed from Tomcat every link has been rewritten so it contains the jsessionid (URL rewriting).
If I create a test application using ordinary jsp or selvlets (no Struts) the jsessionid appears fine as a cookie, and no URL rewriting has been done by Tomcat. The same thing happens if I deploy the cookie example (One of the examples contained in the Tomcat install package).
But if I configure the Struts ActionServlet in the web.xml file, Tomcat rewrites every link. I have tested this on Tomcat 4.1.18, 4.1.27 and 5.0.9.
Even if I try to deploy the struts-example.war file from the jakarta-struts-1.1.zip package the jsessionid cookie is not found, and Tomcat rewrites every link!
Can someone tell me why Tomcat always uses URL rewriting, when your web application are using Struts? And is there any solutions to get around this?

Kind regard
Torben Riis
I agree. Here's the link: http://aspose.com/file-tools
subject: Tomcat + Struts no jsessionid cookie.
It's not a secret anymore!