tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Thomas <>
Subject Re: Race condition with values displayed across redirects
Date Thu, 04 Oct 2007 12:30:15 GMT
lightbulb432 wrote:
> I have a question about whether there is a race condition with the following
> technique for displaying messages across redirects.

Yes there is.

> If you submit a form with an invalid value on page P1 and the receiving
> servlet S redirects to another page P2, you'd like page P2 to contain a
> message saying "You entered an invalid value". You can only put the value in
> the session (not the request, because it's a redirect, not a forward), with
> session.setAttribute("message","You entered an invalid value").

Why not pass the information to P2 using a request parameter on the


To start a new topic, e-mail:
To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message