Return-Path: X-Original-To: apmail-tomcat-dev-archive@www.apache.org Delivered-To: apmail-tomcat-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 03A65CD2C for ; Wed, 27 Jun 2012 16:50:21 +0000 (UTC) Received: (qmail 28858 invoked by uid 500); 27 Jun 2012 16:50:21 -0000 Delivered-To: apmail-tomcat-dev-archive@tomcat.apache.org Received: (qmail 28749 invoked by uid 500); 27 Jun 2012 16:50:21 -0000 Mailing-List: contact dev-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Developers List" Delivered-To: mailing list dev@tomcat.apache.org Received: (qmail 28737 invoked by uid 99); 27 Jun 2012 16:50:21 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 27 Jun 2012 16:50:21 +0000 X-ASF-Spam-Status: No, hits=-2.3 required=5.0 tests=RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of Chuck.Caldarale@unisys.com designates 216.82.250.179 as permitted sender) Received: from [216.82.250.179] (HELO mail210.messagelabs.com) (216.82.250.179) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 27 Jun 2012 16:50:10 +0000 X-Env-Sender: Chuck.Caldarale@unisys.com X-Msg-Ref: server-3.tower-210.messagelabs.com!1340815786!3362244!6 X-Originating-IP: [192.61.61.104] X-StarScan-Version: 6.5.10; banners=-,-,- X-VirusChecked: Checked Received: (qmail 13096 invoked from network); 27 Jun 2012 16:49:47 -0000 Received: from unknown (HELO USEA-NAEDGE1.unisys.com) (192.61.61.104) by server-3.tower-210.messagelabs.com with RC4-SHA encrypted SMTP; 27 Jun 2012 16:49:47 -0000 Received: from usea-nahubcas2.na.uis.unisys.com (129.224.76.115) by USEA-NAEDGE1.unisys.com (192.61.61.104) with Microsoft SMTP Server (TLS) id 8.3.83.0; Wed, 27 Jun 2012 11:48:56 -0500 Received: from USEA-EXCH8.na.uis.unisys.com ([129.224.76.41]) by usea-nahubcas2.na.uis.unisys.com ([129.224.76.115]) with mapi; Wed, 27 Jun 2012 11:48:56 -0500 From: "Caldarale, Charles R" To: Tomcat Developers List Date: Wed, 27 Jun 2012 11:49:31 -0500 Subject: RE: Race condition in DefaultServlet Thread-Topic: Race condition in DefaultServlet Thread-Index: Ac1UgpYyA+AdoFrFTyq8UhJfDoE4dAAAdTGA Message-ID: <99C8B2929B39C24493377AC7A121E21FB0320B6E07@USEA-EXCH8.na.uis.unisys.com> References: In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 > From: Chris R [mailto:chris.tech.sf@gmail.com]=20 > Subject: Race condition in DefaultServlet > If multiple threads call doPut(...), there is a possibility that they can > clobber each other and the value of accessCount may not really give the=20 > exact number of accesses of the cache. Which is noted in the comments. > Can someone confirm whether this is a real problem? Not in the real world. If the count is off a bit, there's no measurable ha= rm. The cost of synchronization outweighs the infinitesimal benefit of hav= ing a 100% accurate number here. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MA= TERIAL and is thus for use only by the intended recipient. If you received = this in error, please contact the sender and delete the e-mail and its atta= chments from all computers. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org For additional commands, e-mail: dev-help@tomcat.apache.org