Return-Path: Delivered-To: apmail-jackrabbit-dev-archive@www.apache.org Received: (qmail 5429 invoked from network); 13 Feb 2008 22:59:34 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 13 Feb 2008 22:59:34 -0000 Received: (qmail 41115 invoked by uid 500); 13 Feb 2008 22:59:26 -0000 Delivered-To: apmail-jackrabbit-dev-archive@jackrabbit.apache.org Received: (qmail 40847 invoked by uid 500); 13 Feb 2008 22:59:25 -0000 Mailing-List: contact dev-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@jackrabbit.apache.org Delivered-To: mailing list dev@jackrabbit.apache.org Received: (qmail 40825 invoked by uid 99); 13 Feb 2008 22:59:24 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Feb 2008 14:59:24 -0800 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Feb 2008 22:59:01 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 5B97F71407F for ; Wed, 13 Feb 2008 14:59:09 -0800 (PST) Message-ID: <16728341.1202943549372.JavaMail.jira@brutus> Date: Wed, 13 Feb 2008 14:59:09 -0800 (PST) From: "Chris Wilson (JIRA)" To: dev@jackrabbit.apache.org Subject: [jira] Updated: (JCR-1382) [PATCH] ResourceConfig Classloading In-Reply-To: <19031260.1202943313326.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/JCR-1382?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Chris Wilson updated JCR-1382: ------------------------------ Description: Ran into a ClassNotFoundException when trying to load a custom IOManager from webdav's config.xml. Setup: - All the dependency jars as well as Jackrabbit jars were installed in $CATALINA_HOME/common/lib in order to reference the JCR with JNDI using class org.apache.jackrabbit.core.jndi.BindableRepositoryFactory - Default install of jackrabbit-webapp-1.4 with custom IOManager(s) in $CATALINA_HOME/ jackrabbit-webapp-1.4/WEB-INF/classes On app startup the ResourceConfig was being referenced from the common Classloader. Since the current implementation is using the Class.forName method of loading a dynamic class. It was unable to find the custom IOManager which was on the webapps classloader. Patch file implements pattern to attempt to use the Threads contextClassloader and defaults to Class.forName This issue also exists in 1.3 but can be worked around by removing the jackrabbit-webdav-1.3.3.jar from the common Classloader. The workaround does not work in 1.4. Earlier versions then 1.3 are unknown since they were not tested. was: Ran into a ClassNotFoundException when trying to load a custom IOManager from webdav's config.xml. Setup: - All the dependency jars as well as Jackrabbit jars were installed in $CATALINA_HOME/common/lib in order to reference the JCR with JNDI using class org.apache.jackrabbit.core.jndi.BindableRepositoryFactory - Default install of jackrabbit-webapp-1.4 with custom IOManager(s) in $CATALINA_HOME/ jackrabbit-webapp-1.4/WEB-INF/classes On app startup the ResourceConfig was being referenced from the common Classloader. Since the current implementation is using the Class.forName method of loading a dynamic class. It was unable to find the custom IOManager which was on the webapps classloader. Patch file implements pattern to attempt to use the Threads contextClassloader and defaults to Class.forName This issue also exists in 1.3 but can be worked around by removing the jackrabbit-webdav-1.3.3.jar from the common Classloader. This workaround does not work in 1.4. Earlier version then 1.3 are unknown since they were not tested. > [PATCH] ResourceConfig Classloading > ----------------------------------- > > Key: JCR-1382 > URL: https://issues.apache.org/jira/browse/JCR-1382 > Project: Jackrabbit > Issue Type: Bug > Components: jackrabbit-jcr-server, jackrabbit-webdav > Affects Versions: 1.3, 1.3.1, 1.3.3, 1.4 > Environment: JDK 1.5, Tomcat 5.5, Xnix/Windoze > Reporter: Chris Wilson > Priority: Critical > Fix For: 1.4.1, 1.5 > > Attachments: classloader.patch > > > Ran into a ClassNotFoundException when trying to load a custom IOManager from webdav's config.xml. > Setup: > - All the dependency jars as well as Jackrabbit jars were installed in $CATALINA_HOME/common/lib in order to reference the JCR with JNDI using class org.apache.jackrabbit.core.jndi.BindableRepositoryFactory > - Default install of jackrabbit-webapp-1.4 with custom IOManager(s) in $CATALINA_HOME/ jackrabbit-webapp-1.4/WEB-INF/classes > On app startup the ResourceConfig was being referenced from the common Classloader. Since the current implementation is using the Class.forName method of loading a dynamic class. It was unable to find the custom IOManager which was on the webapps classloader. > Patch file implements pattern to attempt to use the Threads contextClassloader and defaults to Class.forName > This issue also exists in 1.3 but can be worked around by removing the jackrabbit-webdav-1.3.3.jar from the common Classloader. The workaround does not work in 1.4. Earlier versions then 1.3 are unknown since they were not tested. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.