struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Craig McClanahan" <craig...@apache.org>
Subject Re: How dose JFS deal with multi-threads
Date Sun, 23 Apr 2006 22:22:18 GMT
On 4/23/06, 王曾wang_zeng <wangzengverycool@gmail.com> wrote:
>
>    JSF provides us with a collection of standard UI components, and these
> components are integrated with JSP via JSF tag. when the JSP is executed,
> a
> tree of components will be constructed on the server. I wonder how many
> copies of this tree should be preserved on the server to remember the
> status
> of ervery clients's view. If there is only one copy, which I personally
> think is impossible, how dose JSF deal with muti-threads.
>
> The tree of components for each request is created in request scope, so it
exists per request and there are no thread safety issues to worry about
here.  That only becomes an issue when you reference session scope or
application scope properties from your components via value binding
expressions -- and then, it's a matter of ensuring that the referenced
method can deal correclty with multiple threads calling it.

For the JSF component tree, though, it is analogous to having your Struts
form beans in request scope -- you don't have to worry about multiple
threads.

Craig

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message