1 Reply Latest reply on Jul 19, 2005 1:32 PM by Gary Cuozzo

    Datasource not found error

    Gary Cuozzo Newbie

      I am trying to integrate Jbpm with a J2EE application running on JBoss. Due to having lots of class loader problems, ClassCastExceptions, hot deployment issues, etc. I configured JBoss to use separate class loaders for each application.

      I have a web app deployed in it's own WAR file and an EAR file that has session beans used by the web app. I also have the Jbpm SAR file and modified the jboss-service.xml file to have a scoped classloader and included all the Jbpm jar files inside the SAR. I have the parent delagation turned off so that classes will be loaded from jar files inside the sar file first.

      The issue that I'm having is that when I deploy the SAR file, I get an exception from hibernate that it cannot find the datasource in JNDI. Does anybody think this is related to the classloader configuration? I don't really see how it can be. It all worked before the changes, which is why i'm suspect.

      Let me know if you need to see deployment descripters or details about the structure of the packaged war/ear/sar files.

      Any help is appreciated. Thanks in advance.
      Gary.

        • 1. Re: Datasource not found error
          Gary Cuozzo Newbie

          Well, a bit more research indicates that giving jbpm its own classloader is what is causing the problem. I commented out the "loader-repository" section in the jboss-service.xml file and it can find the datasource.

          I have no idea why that would affect a JNDI lookup, but my guess is that the underlying error is really some sorta ClassNotFound and it just manifests itself as a datasource lookup problem.

          Anybody have any other suggestions for how I can run the Jbpm service without polluting the rest of my JBoss libraries & applications? I really want to keep all the Jbpm dependencies separate.

          Thanks,
          gary.