5 Replies Latest reply on Jul 1, 2006 7:39 AM by kukeltje

    Urgent , pb with the hibernate session

    mneja82

      i am a beginner at JBPM..
      i have created a Junit class that do this:


      public class SimpleProcessTest extends TestCase {

      public void testSimpleProcess() throws Exception {
      JbpmConfiguration jbpmConfiguration = JbpmConfiguration.getInstance();
      // Extract a process definition from the processdefinition.xml file.

      JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
      try {
      String processName = "aymen";
      ProcessInstance processInstance =
      jbpmContext.newProcessInstance(processName);
      } finally {
      jbpmContext.close();
      }


      }

      }



      i have this error:


      java.lang.NoClassDefFoundError: org/hibernate/Session
      at org.jbpm.persistence.db.DbPersistenceServiceFactory.openService(DbPersistenceServiceFactory.java:55)
      at org.jbpm.svc.Services.getService(Services.java:136)
      at org.jbpm.svc.Services.getPersistenceService(Services.java:175)
      at org.jbpm.JbpmContext.getPersistenceService(JbpmContext.java:515)
      at org.jbpm.JbpmContext.getGraphSession(JbpmContext.java:431)
      at org.jbpm.JbpmContext.newProcessInstance(JbpmContext.java:266)
      at com.sample.SimpleProcessTest.testSimpleProcess(SimpleProcessTest.java:21)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at junit.framework.TestCase.runTest(TestCase.java:154)
      at junit.framework.TestCase.runBare(TestCase.java:127)
      at junit.framework.TestResult$1.protect(TestResult.java:106)
      at junit.framework.TestResult.runProtected(TestResult.java:124)
      at junit.framework.TestResult.run(TestResult.java:109)
      at junit.framework.TestCase.run(TestCase.java:118)
      at junit.framework.TestSuite.runTest(TestSuite.java:208)
      at junit.framework.TestSuite.run(TestSuite.java:203)
      at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:478)
      at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:344)
      at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)


      please help me. it s very urgent to find the pb

        • 1. Re: Urgent , pb with the hibernate session
          kukeltje

          I'm not going to be nice (I think) but could the problem be that you are a beginner in Java to?

          • 2. Re: Urgent , pb with the hibernate session
            mneja82

             

            "kukeltje" wrote:
            I'm not going to be nice (I think) but could the problem be that you are a beginner in Java to?


            So please a solution

            • 3. Re: Urgent , pb with the hibernate session
              cpob

               

              "mneja82" wrote:
              "kukeltje" wrote:
              I'm not going to be nice (I think) but could the problem be that you are a beginner in Java to?


              So please a solution


              The problem is, this error is immediately obvious to someone with any decent Java experience.
              Unfortunately, this is not the place for Java help, strictly for jBPM help.

              Though, I'll throw you a bone:
              Your issue is that you do not have Hibernate on the classpath.

              • 4. Re: Urgent , pb with the hibernate session
                newbie007

                Guys,

                Don't be so hard :-)

                The issue is that you are missing hibernate related jar files in your classpath.

                You can find list of required jar files from hibernate.org.

                Thanks.

                • 5. Re: Urgent , pb with the hibernate session
                  kukeltje

                  Newbie007,

                  We have to be, our time is precious and costly. We cannot start helping people on such fundamental issues. If these things already pos a problem, I'm holding my breath for what is comming up next.

                  Besides that. The list of what jBPM needs is *not* on the hibernate site. It is bigger and posted in the forum several times, in the wiki and docs. So if people start doing things *without* knowing what they are doing. We are hard and will be hard in the future as well.

                  btw,

                  Thanks for trying to help out ;-)