So far so good, but how is the serial number stored 
in the validator bean ?

If the id is stored in an instance variable it may be 
possible that 2 concurrent request in the same session
to any form that uses this bean might cause problems.
(It is possible to change the value between 
jsp:setProperty and isValid())

What exactly is the purpose of the serial id ?


> -----Original Message-----
> From: Denise Mangano [mailto:[EMAIL PROTECTED]
> Sent: Thursday, March 25, 2004 5:05 PM
> To: Tomcat Users List
> Subject: RE: Possible thread "crossing"
> 
> <%@ page import="com.beans.clients.Validator" %>
> <jsp:useBean id="formValidator" class="com.beans.clients.Validator"
> scope="session"/>
> <% formValidator.reset(); %>
> <jsp:setProperty name="formValidator" property="*"/>
> 
> <% if (formValidator.isValid()) {   %>
> 
> If the form data is not valid it calls Retry.jsp which I have 
> tried two ways:
> 1) <input type="hidden" name="serialNumber"
> value="<%=formValidator.getSerialNumber()%>">
> 2) <input type="hidden" name="serialNumber" value="123456789">
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to