Return-Path: Delivered-To: apmail-struts-user-archive@www.apache.org Received: (qmail 25808 invoked from network); 10 Jul 2007 12:13:16 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 10 Jul 2007 12:13:16 -0000 Received: (qmail 77678 invoked by uid 500); 10 Jul 2007 12:13:06 -0000 Delivered-To: apmail-struts-user-archive@struts.apache.org Received: (qmail 77667 invoked by uid 500); 10 Jul 2007 12:13:06 -0000 Mailing-List: contact user-help@struts.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Struts Users Mailing List" Reply-To: "Struts Users Mailing List" Delivered-To: mailing list user@struts.apache.org Received: (qmail 77654 invoked by uid 99); 10 Jul 2007 12:13:06 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 10 Jul 2007 05:13:06 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: local policy) Received: from [85.214.44.140] (HELO e.nrgie.net) (85.214.44.140) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 10 Jul 2007 05:13:02 -0700 Received: from webmail.nrgie.net (localhost [127.0.0.1]) by e.nrgie.net (Postfix) with ESMTP id 502CCEFC0DA; Tue, 10 Jul 2007 14:36:16 +0200 (CEST) Received: from 80.87.162.74 (SquirrelMail authenticated user rene) by webmail.nrgie.net with HTTP; Tue, 10 Jul 2007 14:36:16 +0200 (CEST) Message-ID: <47688.80.87.162.74.1184070976.squirrel@webmail.nrgie.net> In-Reply-To: <73896C9F08D68D438FCCBA8005C671E708A2E8CC@C3EXCHANGE.corp.premierinc.c om> References: <73896C9F08D68D438FCCBA8005C671E708A2E8CC@C3EXCHANGE.corp.premierinc.com> Date: Tue, 10 Jul 2007 14:36:16 +0200 (CEST) Subject: RE: [S2] Interceptor Question (Thread Safety) From: "Rene Gielen" To: "Struts Users Mailing List" User-Agent: SquirrelMail/1.4.8 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal X-Virus-Checked: Checked by ClamAV on apache.org I'll add some words on that to the docs. Am Di, 10.07.2007, 13:42, schrieb Hoying, Ken: > Thank you, Rene! > > This is a great help to me and allows me to move forward with my current > implementation. It might be a good idea for someone from the Struts2 > project to update the documentation with Rene's finding, as I am sure > others will also find this unclear and concerning. > > Thank you again! > > -----Original Message----- > From: Rene Gielen [mailto:gielen@it-neering.net] > Sent: Tuesday, July 10, 2007 2:38 AM > To: Struts Users Mailing List > Subject: Re: [S2] Interceptor Question (Thread Safety) > > Ken, others, > > now for the definitive answer: > There is one instance per interceptor ref, thus interceptor instances > being unique within the scope they are referenced in. > > Example: > > > > > > > barfoobar > > /index.jsp > > > > barfoo > > /index.jsp > > > > This will cause two instances of FooInterceptor being created, one with > bar property set to "barfoobar" and one with "barfoo". The interceptors > parameters given in struts.xml are only set once per instance, which > means that there are no thread safety issues with interceptor instance > variables. > > HTH, > Rene > > > Rene Gielen schrieb: >> Uahhh, >> >> thanks for pointing out this information, I was way to fast to reply >> on the said question - I recalled it wrong. Indeed documentation is >> right here, they need to be thread safe - sorry for causing >> misunderstanding here. >> >> Anyway, this does not answer the question if interceptor parameters >> introduce thread safety issues. The builder mechanism is a little >> complicated here, but AFAIK Interceptor instances are unique to the >> scope they are configured in. I will check this tonight to ensure we >> do not face a problem here with current implementation and hopefully >> can provide a reliable answer then. >> >> Regards, >> Rene >> >>