7 Replies Latest reply on Aug 27, 2003 2:31 AM by ananth

    where are verifier and metadata.jar

    schwarcz

      the online manual gives a recipe for running the JBoss verifier from Ant and dictates copying the dist/bin/verifier.jar and dist/extenral/metadata.jar files. I don't see the directories / files in my Win XP JBoss 3.0 installation.

      Where can I get the files? Do I need to deal with the source distribution?

        • 1. Re: where are verifier and metadata.jar
          schwarcz

          Or does this info only apply to 2.4 and not 3.0?

          • 2. Re: where are verifier and metadata.jar
            minamoto

            In JBoss 3.0.x, the org.jboss.verifier.Main is in the jboss.jar.
            You can call the verifier as follows:










            Because I don't know the depedencies between system jars,
            I add server/default/lib/*.jar to the verifier.classpath in my ant script.

            Or may be you could build the verifier.jar from the build.xml of the jboss server.

            Miki

            • 3. Re: where are verifier and metadata.jar
              schwarcz

              thanks so much, I'll give it a try

              • 4. Call for a 'build.xml' example to run Jboss-verifier in ANT
                kg1959

                Dear Miki,
                I tried to solve a similar problem but got stucked since 3 days on the following Exception:

                [java] Exception in thread "main" java.lang.NoClassDefFoundError: javax/management/MalformedObjectNameException
                [java] at org.jboss.metadata.ApplicationMetaData.importEjbJarXml(ApplicationMetaData.java:186)
                [java] at org.jboss.metadata.XmlFileLoader.load(XmlFileLoader.java:151)
                [java] at org.jboss.verifier.Main.main(Main.java:79)

                The relevant lines of the 'build.xml' for Ant are:
                .
                .
                .
                <!-- Tool subdirectories -->



                .
                .
                .
                <!--
                Classpath to run the jBoss Verifier. If you use a modified version
                of standardjaws.xml, change the first pathelement below to the
                directory where your custom standardjaws.xml is located.
                -->










                .
                .
                <!-- Runs the JBoss verifier and checks the contents of the ejb-jar for EJB specification compliance -->






                .
                .

                I got the example 'build.xml'-file from Bruce Eckels 'Thinking in Java' 3rd Edition and all other 'targets' work quite ok.

                As I could not manage to include "$(jboss.home)/server/default/lib/*.jar" as a pathelement location i included each *.jar file in this directory.
                But this did not overcome the Exception showed above.
                The I removed the *.jar files one by one from the pathelement location list.
                When the error changed I asumed that that specific *.jar file is needed to run the jboss-verifier.

                My Environment is:
                * RedHat Linux 7.1;
                * Blackdown-1.4.1-beta Java Development Kit;
                * jboss-3.0.4_tomcat-4.1.12 jBoss-Server

                I kindly ask for an example 'build.xml' which is proven to work and an information about your operating-environment (OS, Java-SDK and jBoss-Version).

                Many thanks in advance !

                Kurt, Vienna, Austria

                • 5. Re: Call for a 'build.xml' example to run Jboss-verifier in
                  minamoto

                  Hi Kurt,

                  I guess JBoss system jars had changed or moved after my previous post.
                  I've found we need some more jars under JBOSS_HOME/lib such as jaxp.jar and crimson.jar.

                  Here is my build.xml for JBoss 3.0.5 + Ant 1.5.1:










                  And I should replace with <classpath refid=..> as you pointed out.
                  I could use in my last post because I also set

                  somewhere else but I didn't mention it.








                  Still we see Log4J warings but the verifier works.

                  I tested it with JDK 1.3.1_06 on Windows XP.

                  I hope this helps,
                  Miki

                  • 6. Re: where are verifier and metadata.jar
                    kg1959

                    Thank you for your help, Miki !

                    Other work prevented me from learning ANT and Jboss but now I found time to prepare a 'build.xml'-file with the minimum configuration to run the JBoss-verifier:

                    <!-- Example for an ANT 'build.xml' file to test if an xxx.jar-file is proper built for deployment in Jboss 3.0.4.
                    In this example the xxx.jar-file is named 'HelloWorld.jar'.
                    This example assumes that the deployable xxx.jar-file is in the subdirectory ./dist.

                    As a base for this example i took a file originally published in Bruce Eckels 'Thinking in Java' 3rd edition.
                    Miki Minamoto gave me the essential hint to make the jboss-verifier run.

                    *** This is NOT a 'build.xml'-file to DO TO A COMPLETE compile, jar and deploy cycle in ANT; it is only an example to call Jboss-verifier ! ***

                    Kurt Gstoettner, Vienna Austria, mailto:kurt.gstoettner@aon.at
                    -->



                    <!-- Name of the ejb-jar file that contains our EJBs -->


                    <!-- Directory for the final distributable files -->


                    <!-- Tool directories as defined by the environment variables -->



                    <!-- Tool subdirectories -->


                    <!--
                    Classpath to run the jBoss Verifier. If you use a modified version
                    of standardjaws.xml, change the first pathelement below to the
                    directory where your custom standardjaws.xml is located.
                    -->










                    <!-- Runs the JBoss verifier and checks the contents of the ejb-jar for EJB specification compliance -->









                    I hope, somebody can make use of my experience !
                    Kurt

                    • 7. Ant Verifier
                      ananth

                      Thanks so much for the ant verifier TIP.

                      It was really helpful :)
                      -- Ananth