2 Replies Latest reply on Sep 25, 2005 2:37 AM by raja05

    jaas jndi && UseJBossWebLoader && Java2ClassLoadingComplianc

    liobod

      Hello world,

      At least i found a work around that seems to be working in order to use two versions of the same jar in two different webapp.

      The solution wasn't obvious even after read those page :
      http://wiki.jboss.org/wiki/Wiki.jsp?page=ClassLoadingConfiguration
      http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossClassLoadingUseCases
      http://www.huihoo.com/jboss/online_manual/3.2.3/Chap9.html

      and some more threads in some forums ...

      I set this properties

      <attribute name="Java2ClassLoadingCompliance">false</attribute>
      <attribute name="UseJBossWebLoader">false</attribute>

      in jboss-3.2.2/server/default/deploy/jbossweb-tomcat41.sar/META-INF/jboss-service.xml


      But i still have a problem :
      I'm not sure what i'm doing if i set Java2ClassLoadingCompliance to true or false in my webapp in jboss-web.xml
      <jboss-web>
       <!-- isolation class loading needs -->
       <attribute name="Java2ClassLoadingCompliance">true</attribute>
      </jboss-web>


      Morever this kind of conf does not work anymore :
      <jboss-web>
       <security-domain>java:/jaas/ref_ce</security-domain
      </jboss-web>

      My env is jboss-3.2.2/jbossweb-tomcat41.sar

      Any thread, doc, RTFM, link i forgot?

      thx,

        • 1. Re: jaas jndi && UseJBossWebLoader && Java2ClassLoadingCompl
          liobod

          nobody to answer/advice me on this isolation problem?

          • 2. Re: jaas jndi && UseJBossWebLoader && Java2ClassLoadingCompl
            raja05

            your post doesnt indicate if your problem got solved or not. anyway, the first 2 settings that you mentioned(UseJbossWeBLoader and Java2ClassLoadingComplianace) are at the level of jboss-tomcat integration, which means all the wars installed in ur server will go by this configuration.

            You can specifically override this behaviour by setting the Java2ClassLoadingCompliance in ur jboss-web.xml for *each* war in ur server. If you set this property to be true, Jboss will look up the parent ClassLoaders to look for the package(and the class) before it looks up the child repositories. For e.g. if you had a commons-collections in the jbossweb-tomcat*.sar and also a commons-collections in ur war file, the one in jboss-tomcat.sar will take preference over yours if you set Java2ClassLoading property to be true.