tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shapira, Yoav" <Yoav.Shap...@mpi.com>
Subject RE: Location: redirection
Date Mon, 15 Nov 2004 20:30:50 GMT

Hi,

>We're using perl within tomcat 4.1.27. The perl scripts run all right,
>but the redirections don't work at all.

Using an external mechanism (such as a CGI perl scripts in your case)
for redirection in Tomcat is tricky at best, and doomed to failure at
worst.  The reason is that the script is not really part of the servlet
request/response pipeline.  Rather, it is invoked as an exec by a Tomcat
servlet (in your case, the CGI servlet that ships with Tomcat, I
assume).  

That servlet can easily do a response redirect or request forward, but
the script cannot.

Accordingly, if you stick with the script at all, modify it to return
the redirection URL, and have the servlet (a custom extension to the CGI
Servlet that ships with Tomcat probably) read and act upon this URL by
doing the redirection.

Yoav



This e-mail, including any attachments, is a confidential business communication, and may
contain information that is confidential, proprietary and/or privileged.  This e-mail is intended
only for the individual(s) to whom it is addressed, and may not be saved, copied, printed,
disclosed or used by anyone else.  If you are not the(an) intended recipient, please immediately
delete this e-mail from your computer system and notify the sender.  Thank you.


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message