Return-Path: Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: (qmail 77276 invoked from network); 28 Nov 2005 18:56:27 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 28 Nov 2005 18:56:27 -0000 Received: (qmail 63526 invoked by uid 500); 28 Nov 2005 18:56:12 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 63511 invoked by uid 500); 28 Nov 2005 18:56:12 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 63500 invoked by uid 99); 28 Nov 2005 18:56:11 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 28 Nov 2005 10:56:11 -0800 X-ASF-Spam-Status: No, hits=0.5 required=10.0 tests=DNS_FROM_RFC_ABUSE X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [68.142.200.230] (HELO web31111.mail.mud.yahoo.com) (68.142.200.230) by apache.org (qpsmtpd/0.29) with SMTP; Mon, 28 Nov 2005 10:57:40 -0800 Received: (qmail 78320 invoked by uid 60001); 28 Nov 2005 18:55:49 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:Received:Date:From:Reply-To:Subject:To:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=UZedvDdUIEBVNycPnODnMnN5UJQT7Z8kE0jIwH5V9MuvpQsATMSsJNqEiT8JB6CZTUg2OukJlPOYTBn5DUdFhMAPLKA0jeH5WTNSP9lmqcDXSqMjcK89Q/P/8h4ondEbfIDjV+hkWZrGSeJcc8yxD1Kv3ioHitfxI82qX24+seo= ; Message-ID: <20051128185549.78318.qmail@web31111.mail.mud.yahoo.com> Received: from [69.1.58.6] by web31111.mail.mud.yahoo.com via HTTP; Mon, 28 Nov 2005 10:55:48 PST Date: Mon, 28 Nov 2005 10:55:48 -0800 (PST) From: Wade Chandler Reply-To: hwadechandler-apache@yahoo.com Subject: Re: heap size problems (speed) [2] To: Tomcat Users List In-Reply-To: <006901c5f449$5ae934f0$0a00a8c0@lilo> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N --- Cristian wrote: > > ----- Original Message ----- > From: "Duan, Nick" > To: "Tomcat Users List" > Sent: Monday, November 28, 2005 7:30 PM > Subject: RE: heap size problems (speed) [2] > > > > Were you using the right JVM? There were two JDK > download for LINUX > on > > Sun's web site. > > I have downloaded : J2SE(TM) Development Kit 5.0 > Update 5 > Linux self extracting file (although I think I > should have get the rpm). > > I've extrated it in a separate directory and set > JAVA_HOME in tomcat to > point to that dir. > > Does it make any difference other than the fact that > this way it is not > rpm compliant? > > > The main problem may be your AMD Duron processor > which has a very > small > > cache size (I believe it's about 512K). Once the > processor cache > > reaches its limit, increasing the JVM heap size > won't be very > effective. > > This is even worse for my AMD Duron > cache size : 64 KB > > but on the other machine I have : > cache size : 1024 KB > and still get the same results. > > Cristian > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: > users-unsubscribe@tomcat.apache.org > For additional commands, e-mail: > users-help@tomcat.apache.org > > I don't think your CPU L caches are going to influence the issues you are seeing...not noticeably..not with todays hardware. Cristian is resizing the java heap to allow it to get larger than it was able before (default or the Tomcat default setting). In this case heap being the amount of memory the java process is going to be able to use for the process aside from the static space which can not be controlled by the heap setting being used. How much memory does your computer physically have Cristian? Are you also using -Xms512m? I'll wait to here about your memory first before making other comments on that. The next thing I'm going to ask deals with another issue we had on the list. Do you also write to the HashMap from your application? Are you reading and writing to this cache or your application loads this cached data at start up and it is merely read from that point on? If you are writing to this data you need to be sure to synchronize the HashMap because if you don't you can get into some serious problems with concurrency issues and HashMap resizing (synchronize reads and writes). If you load all of the data up then only read from the application then synchronizing the reads to the hash map won't matter (unless you allow reading while the loading is occuring). The next question would be: Even if only reading and you are are currently synchronizing the calls to this "cached" data are the operations long? If the operations to a synchronized resource are very long then other threads (requests in this case) will be delayed while trying to access the HashMap. Wade --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org