Return-Path: X-Original-To: apmail-tomee-users-archive@www.apache.org Delivered-To: apmail-tomee-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 974D518DC2 for ; Tue, 11 Aug 2015 23:57:44 +0000 (UTC) Received: (qmail 47485 invoked by uid 500); 11 Aug 2015 23:57:44 -0000 Delivered-To: apmail-tomee-users-archive@tomee.apache.org Received: (qmail 47460 invoked by uid 500); 11 Aug 2015 23:57:44 -0000 Mailing-List: contact users-help@tomee.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@tomee.apache.org Delivered-To: mailing list users@tomee.apache.org Delivered-To: moderator for users@tomee.apache.org Received: (qmail 41227 invoked by uid 99); 11 Aug 2015 23:54:34 -0000 X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 3.737 X-Spam-Level: *** X-Spam-Status: No, score=3.737 tagged_above=-999 required=6.31 tests=[DKIM_ADSP_CUSTOM_MED=0.001, FREEMAIL_ENVFROM_END_DIGIT=0.25, NML_ADSP_CUSTOM_MED=1.2, SPF_SOFTFAIL=0.972, URIBL_BLOCKED=0.001, URI_HEX=1.313] autolearn=disabled Date: Tue, 11 Aug 2015 16:51:07 -0700 (PDT) From: jmmoon To: users@tomee.apache.org Message-ID: <1439337067603-4675841.post@n4.nabble.com> Subject: Question about TomcatWebAppBuilder in Tomee MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Hi~ all. Actually I have a question about TomcatWebAppBuilder behavior. At the line number 605 of org.apache.tomee.catalina.TomcatWebAppBuilder in Tomee 1.7.1 standardContext.setDelegate(true); is excuted. Although There is the comment about that code, I can not understand this behavior. In case of ear, the classLoader is a instance of URLClassLoaderFirst which loads clssses in the ear\lib, ejb.jar etc. When standardContext.setDelegate(true); is called WebAppClassLoader does not look up WEB-INF directory first. It just delegates to the parent classloader URLClassLoaderFirst. This makes some classloading problem. For example, in case of using slf4j-log4j, slf4j is loaded in the ${TomeeInstallDir}\lib and log4j library is loaded in the WEB-INF so, log4j does not work well. I have had much googling about this problem, I have found "opejb.classloader.force-load=..." in the System.properties, but it doesn't work. Finally I deleted standardContext.setDelegate(true); line, then everything became perpect. But I think tomee team have a reason to call this line and I worry that threre might be a side-effect after deleting this line. I appreciate if I have an answer. Thank you. -- View this message in context: http://tomee-openejb.979440.n4.nabble.com/Question-about-TomcatWebAppBuilder-in-Tomee-tp4675841.html Sent from the TomEE Users mailing list archive at Nabble.com.