4 Replies Latest reply on Feb 12, 2004 10:21 AM by alessandro_rizzi

    Having class path from an EJB

    alessandro_rizzi Newbie

      I've to know the full class-path from an EJB that runs inside JBoss or Orion.
      With Orion I simply write: System.getProperty("java.class.path"); and I got it.
      With JBoss I got only the 2 jars used to run JBoss (tools.jar and run.jar) while I need to know all the jars full path. I need it to do it at run-time, so within Java ...
      Can anybody help me.
      Regards
      Alessandro Rizzi

        • 1. Re: Having class path from an EJB
          zolmed75 Newbie

          What you're seeing in JBoss is the correct classpath: "tools.jar and run.jar". Why do you need to know the classpath? JBoss does not load your application's classes from the classpath if that's what you are thinking.

          • 2. Re: Having class path from an EJB
            alessandro_rizzi Newbie

             

            "zolmed75" wrote:
            What you're seeing in JBoss <i>is</i> the correct classpath: "tools.jar and run.jar". Why do you need to know the classpath?


            I need to know the classpath to open some jar (which contains my ejb) to read some informations from the manifest. These jars are under the "deploy" folder in some folder which may change in time, so I do not want to hardcode the path of these jars.

            "zolmed75" wrote:
            JBoss does not load your application's classes from the classpath if that's what you are thinking.

            So, is it possible to have the list of all loades jars (with full path)?
            Thanks for help
            Alessandro


            • 3. Re: Having class path from an EJB
              Juha Lindfors Master

              The LoaderRepository MBean exposes these via its URLs attibute:

              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51504client-deployer-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51510oil2-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51483jasper-runtime.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51506jbossmq-destinations-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/bsh-core-1.3.0.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51480naming-common.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51500jms-ra.rar-contents/jms-ra.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51515schedule-manager-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51508jvm-il-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51482tomcat-util.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jnpserver.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/conf/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/snmp-adaptor.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51520web-console.war/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/mail.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jboss-management.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/mail-plugin.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51499jboss-xa-jdbc.rar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/jbossweb-tomcat41.sar/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51490jasper-compiler.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/snmp-adaptor.sar/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51516scheduler-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51495console-mgr.sar-contents/jfreechart-demo.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jcert.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51495console-mgr.sar-contents/jfreechart.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51486jakarta-regexp-1.3.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jbossmq.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/jms/jbossmq-httpil.sar/jbossmq-httpil.war/WEB-INF/classes/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/bindingservice-plugin.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51488tomcat-jk2.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51494bootstrap.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/bsh-deployer.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jboss.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51517sqlexception-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/properties-plugin.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/scheduler-plugin-example.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/activation.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/bcel.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51519user-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51487commons-collections.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/jms/jbossmq-httpil.sar/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51511rmi-il-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51507jbossmq-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51481servlets-invoker.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51499jboss-xa-jdbc.rar-contents/jboss-xa-jdbc.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51495console-mgr.sar-contents/jcommon.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/jms/jbossmq-httpil.sar/jbossmq-httpil.war/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jnet.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jsse.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jpl-pattern.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/jmx-invoker-adaptor-server.sar/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jbosssx.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51475servlets-webdav.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/scheduler-plugin.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jpl-util.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51518transaction-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/javax.servlet.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jbossha.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/http-invoker.sar/invoker.war/WEB-INF/classes/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51497uuid-key-generator.sar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51484tomcat41-service.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51472jboss-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51512uil2-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/hsqldb.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jboss-jsr77.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51502jms-ds.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jboss-transaction.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/http-invoker.sar/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51492commons-beanutils.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51495console-mgr.sar-contents/console-mgr-classes.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/http-invoker.sar/invoker.war/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51509oil-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/snmp-support.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51479tomcat-http11.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51503cache-invalidation-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jmx-adaptor-plugin.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51498jboss-local-jdbc.rar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51496castor.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51478naming-resources.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51474tomcat-coyote.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51498jboss-local-jdbc.rar-contents/jboss-local-jdbc.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/jmx-console.war/WEB-INF/classes/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51514properties-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jts.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/hsqldb-plugin.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51520web-console.war/WEB-INF/classes/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51477catalina.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jboss-j2ee.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/log4j.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51500jms-ra.rar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jboss-common-jdbc-wrapper.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51505hsqldb-jdbc2-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51513mail-service.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/deploy/jmx-console.war/
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51476commons-digester.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51495console-mgr.sar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/jboss-jaas.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51485commons-logging.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51501hsqldb-ds.xml
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51493servlets-common.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/xalan.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51491servlets-default.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51489ant.jar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51473jboss-jca.sar
              file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/lib/autonumber-plugin.jar
              



              • 4. Re: Having class path from an EJB
                alessandro_rizzi Newbie

                 

                "juha@jboss.org" wrote:
                The LoaderRepository MBean exposes these via its URLs attibute:

                file:/C:/Programs/JBoss/jboss-3.2.3/jboss-3.2.3/server/default/tmp/deploy/tmp51504client-deployer-service.xml
                file:/C:/Programs/JBoss/jboss-3.2.3/jboss-...
                


                Yeah, this works perfectly for me
                Thanks a lot
                Alessandro