struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hubert Rabago <jakartau...@yahoo.com>
Subject Re: ActionForms Thread Safe
Date Sat, 21 Feb 2004 18:44:44 GMT
Different clients use different requests and different sessions.  Therefore,
different users end up with different AF instances.  If you use request scope
for your AF, then even different requests from the same client will be using
different AF instances.
hth,
Hubert

--- Amish Patel <semplice78@hotmail.com> wrote:
> Hello All,
> 
> I am new to struts.  I have been reading about it and they way I understand
> 
> the framework instantiate ActionForm is as follows. ......
> 
> 1) Check to see if an instance of the ActionForm already has been created.
> 
> 2) If an ActionForm instance is present in the appropriate scope and it's 
> the same type as needed for the new request, reuse it.
> Otherwise, create a new instance of the required ActionForm and store it in
> 
> the appropriate scope (set by the scope attribute for the action element).
> 
> 
> If this is case then ActionForm are not thread-safe.  Because Two request 
> from different client can simultaneous come in and use the same ActionForm 
> instance?
> 
> I know this is not the case, but I cannot figure out how is it thread safe?
> 
> Please help!
> Thanks
> -Semplice
> 
> _________________________________________________________________
> Get a FREE online computer virus scan from McAfee when you click here. 
> http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: struts-user-help@jakarta.apache.org
> 


__________________________________
Do you Yahoo!?
Yahoo! Mail SpamGuard - Read only the mail you want.
http://antispam.yahoo.com/tools

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


Mime
View raw message