0 Replies Latest reply on Sep 7, 2004 1:37 PM by rmontag

    sar-archive in ear-file and EARClassloader question

    rmontag

      Hello,

      I have an sar-archive foo.sar with my mbean Foobar and a simple jboss-service.xml- file:

      <server>
       <mbean code="Foobar" name="FoobarMBean"/>
      </server>


      I have the following jboss-appl.xml in my ear-file foobar.ear:

      <jboss-app>
       <loader-repository>foo:loader=foobar.ear</loader-repository>
       <module>
       <service>foo.sar</service>
       </module>
      </jboss-app>


      Now the problem: I want to access a third-party library from my MBean Foobar and I'd like to include this lib only in my ear file, let's say under lib/3rdpartylib.jar in my ear-file.

      When I deploy my ear, when I try to access classes from the 3rdpartylib.jar I'll get a ClassNotFoundError in my MBean (obviously).

      But where do I define the classpath for this ? I have tried an additional classpath entry in the jboss-service.xml file and in the MANIFEST.MF of my sar archive with no success. Any suggestions ?

      Thanks in advance,
      Rainer