struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jim Crossley <>
Subject Re: Hi Folks, 2 questions about Actions and their instance
Date Mon, 01 Apr 2002 17:02:29 GMT writes:


> So here's my 2 question(s):
> 1.   I then assume that "perform()" is synchronized

No.  If all data objects are local to the perform method, there's no
reason for it to be synchronized.  If the data objects referred to in
perform are shared, then their access should probably be synchronized,
but not necessarily.

> 2.  What about those cases where 2 different action mappings resort to the
> same action class?


> There are 2 different path elements but both refer to the same Action class
> instance...    Does this mean 2 static instances of
> BillingActionPreloadForm will exist or will only just 1 exist between the 2
> different action mappings that link to the same class?

I don't know, but it doesn't matter.  You should always assume that
any specific instance of an Action class could potentially serve multiple
threads at once.  Or else what's the point of putting your app on the
web?  ;-)

-- Jim

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message