3 Replies Latest reply on Oct 24, 2006 4:16 PM by kurtstam

    Failed to run JBoss ESB Quick Start demo code

    cfyao

      Hi,

      I just started leaning JBoss ESB and java programming in order to kick off a new project. To start with, I downloaded JBoss ESB Quick Start demo code and picked the first one JBossESBBasicFileListener to try.

      Follow the instructions I modified the file build.xml so that jbossesbhome.dir and jbosshome.dir point to my installations of JBoss ESB and JBoss AS on Windows 2000, i.e., I changed the value of property "jbossesbhome.dir" to "D://JBoss/JBossESB4.0_Beta1" and the value of property "jbosshome.dir" to "D://JBoss/jboss-4.0.4.GA_EJB3".

      In my installation of JBoss ESB the lib folder is directly under JBoss ESB home folder, I therefore changed the value of property "jbossesbdist.dir" from original "${jbossesbhome.dir}/build/dist/lib to "${jbossesbhome.dir}/lib"

      I also modified file BasicFileListenerConfig.xml for changing inputDirURI attribute. I then renamed the downloaded file MyFileWatcher.class under build\howto folder and run command "ant run" in a DOS window. The error message I got was "D:\JBoss\JBossESB4.0_Beta1\lib not found."

      I also tried to create a project in Eclipse using the code from JBossESBBasicFileListener with libraries properly set for the project, but when I chose Run As Java Applicatin in Eclipse, I got an error saying:
      "Exception in thread "main" java.lang.NoClassDefFoundError: javax/jms/JMSException
      at howto.MyFileWatcher.main(MyFileWatcher.java:55)
      I kow the error was caused by a line in the code:
      GpListener oProc = new GpListener(CONFIG_FILE);

      Could any one tell me what's wrong? Thanks in advance.

      cfyao

        • 1. Re: Failed to run JBoss ESB Quick Start demo code
          burrsutter

          Are you running with Beta 1 MP 1?

          Do you have a real version of App Server 4.0.4.GA with EJB3 installed at that location?

          In the folder D://JBoss/JBossESB4.0_Beta1/build/dist/lib do you have:
          jbossesb-appl.ear,jbossesb-common.jar,jbossesb-listeners.jar,jbossesb-services.jar?

          And these path settings may be slightly different depending on if you are using the SRC vs BIN download, I've not checked that out completely.

          • 2. Re: Failed to run JBoss ESB Quick Start demo code
            cfyao

            Hi,

            I've figured out that some directories were wrong in build.xml. After fixed that I could build and run testJbossESB with ant. But I still cannot make it work with Eclips. I should probably post questions on Eclips forum.

            cfyao

            • 3. Re: Failed to run JBoss ESB Quick Start demo code
              kurtstam

              You need to add the right jars on your buildpath.

              For the trailblazer, please look in the bankloanbrokerdemo/IDE/JBossIDE directory for an example of the .classpath file. I'm not sure if it's completely up2date.

              For the esb itself look in the IDE directory in the root of the project.

              You may have to check out the version from SVN.