Return-Path: X-Original-To: apmail-tomcat-users-archive@www.apache.org Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 5AD7B1046D for ; Thu, 6 Jun 2013 16:48:07 +0000 (UTC) Received: (qmail 82536 invoked by uid 500); 6 Jun 2013 16:48:03 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 82449 invoked by uid 500); 6 Jun 2013 16:48:03 -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 82427 invoked by uid 99); 6 Jun 2013 16:48:02 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 06 Jun 2013 16:48:02 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [212.227.17.9] (HELO moutng.kundenserver.de) (212.227.17.9) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 06 Jun 2013 16:47:57 +0000 Received: from Jens-Breitensteins-iMac.local (dslb-188-097-161-104.pools.arcor-ip.net [188.97.161.104]) by mrelayeu.kundenserver.de (node=mreu0) with ESMTP (Nemesis) id 0MKMjK-1UmHVR2fA6-001rAo; Thu, 06 Jun 2013 18:47:35 +0200 Message-ID: <51B0BD25.7010303@j-b-s.de> Date: Thu, 06 Jun 2013 18:47:33 +0200 From: Jens Breitenstein User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:17.0) Gecko/20130328 Thunderbird/17.0.5 MIME-Version: 1.0 To: Tomcat Users List Subject: Re: Best practices for shared classloader use? References: <7215BA462D00D343B2837F9113F0131F016FCAD660@POSTOFFICE02.polydyne.com> In-Reply-To: <7215BA462D00D343B2837F9113F0131F016FCAD660@POSTOFFICE02.polydyne.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V02:K0:etRsmBWmTuiLfWvQ8ppTR2aLDI6S3Zw/fR51Kq6UVvu 6ac9cqQJyJkyR1cyc4b6KilI4HRh8FEwtlpNXtV6XH6SXXLIUL XAN9/piVV5NclexhtZXyB2X4lDTbmqvvE+uILJraKSpvCYhEKI IxwB6ggqhOAwIACP4ILkBjNQPxIaeiInUMYuJtt9oevmLzdZKV HB0vyG3cljpnt17EfjR7C5ZFJNu5PHkfK7Ptqeki4315f/85v0 85TXkF8E+iRbGictziNwMe/Smc8KgdjsLqxwrc3aUtS6pyfH+5 dxHI7joOdEYn4cBsZdwIa0WaMZaJy1WIXn3RyB1zk68rg330tT L1H1zODkIN8eMn4gExQKdRU9O8O3NeZYp1KJ1Lhmu4Nr9a7iLn 0AuOouD6IZluw== X-Virus-Checked: Checked by ClamAV on apache.org Hi Jeff, You are rigth. When moving jars's configuration and resources have to move, too. But as others pointed out analysation of the mem usage is by far more important. Maybe buying some mem for a couple of dollars and forget about the shared class loader at all is a better and less hair graying approach :-) Jens Am 06.06.13 15:40, schrieb Jeffrey Janner: >> -----Original Message----- >> From: mailinglist@j-b-s.de [mailto:mailinglist@j-b-s.de] >> Sent: Tuesday, June 04, 2013 11:25 AM >> To: Tomcat Users List >> Subject: Re: Best practices for shared classloader use? >> >> Hi Don! >> >> Usually each Webapp has its own classloader thus two webapps can have >> different versions of the same class. Classloaders are chained so if a >> class is not found search continues in the next classloader. Shared >> just means one classloader is used by different webapps thus you may >> run into trouble if each webapp requires a different class version >> (changed method signature) as you can not predict which version you >> get. As long you can align the shared libs across all webapps this is >> not an issue. I do not see your static field problem, though? >> Share functionality like using the same jars? If all use the same >> version you can push it to the shared imho. >> >> Jens >> > Jens, > Statically declared variable are a big problem with the shared class loader. > Check the archives for this topic. You only need to go back a month or two. > If you doubt me, try sharing log4j among a bunch of apps, each with its own properties file. > Then try to figure out where the messages are going (hint: it will be only 1 of the files). > Jeff > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org > For additional commands, e-mail: users-help@tomcat.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org