7 Replies Latest reply on Jan 12, 2007 8:54 AM by Donald Warf

    Oracle 10G and JBPM 3.1.1 Issues

    kazam Newbie

      Hi there,

      Following the documentation, I generate the scripts for oracle and they execute nicely both oracle.create.sql and oracle.drop.sql.

      However, the tests are failing.
      Library : classes12.jar from Oracle10g database.
      Hibernate Dialect: Oracle9Dialect

      I have made the following change as mentioned in the jbpm-starters-kit-3.1.1/jbpm-db/readme.html

      modify jbpm.3/src/resources/hibernate.cfg.xml: add line
      <property name="hibernate.query.substitutions">true 1, false 0</property>
      


      However, the testresults have a success rate of 1.5% with no failures but 262 errors out of 266 tests.

      Below I am providing some part of the output of the ant oracle.test target.
      Where can I post or upload the entire ant target log file.
      [junit] 19:38:42,625 [main] INFO C3P0ConnectionProvider : C3P0 using driver: oracle.jdbc.driver.OracleDriver at URL: jdbc:oracle:thin@192.168.0.110:1521:devdb
       [junit] 19:38:42,625 [main] INFO C3P0ConnectionProvider : Connection properties: {user=jbpmtest, password=****}
      
       [junit] 19:38:43,093 [main] INFO Configuration : Reading mappings from resource: org/jbpm/graph/exe/ProcessInstance.hbm.xml
       [junit] 19:38:43,093 [main] INFO HbmBinder : Mapping class: org.jbpm.graph.exe.ProcessInstance -> JBPM_PROCESSINSTANCE
       [junit] 19:38:43,109 [main] INFO Configuration : Reading mappings from resource: org/jbpm/graph/exe/Token.hbm.xml
      ...................
      ................... (continues ...)
       [junit] 19:38:43,734 [main] INFO Configuration : processing association property references
       [junit] 19:38:43,734 [main] INFO Configuration : processing foreign key constraints
       [junit] 19:38:43,750 [main] INFO Configuration : processing extends queue
       [junit] 19:38:43,750 [main] INFO Configuration : processing collection mappings
       [junit] 19:38:43,750 [main] INFO Configuration : processing association property references
       [junit] 19:38:43,750 [main] INFO Configuration : processing foreign key constraints
       [junit] 19:38:43,750 [main] INFO SchemaExport : Running hbm2ddl schema export
       [junit] 19:38:43,765 [main] INFO SchemaExport : exporting generated schema to database
       [junit] 19:38:43,765 [main] INFO C3P0ConnectionProvider : C3P0 using driver: oracle.jdbc.driver.OracleDriver at URL: jdbc:oracle:thin@192.168.0.110:1521:devdb
       [junit] 19:38:43,765 [main] INFO C3P0ConnectionProvider : Connection properties: {user=jbpmtest, password=****}
       [junit] 19:38:43,765 [main] INFO C3P0ConnectionProvider : autocommit mode: false
       [junit] 19:38:43,765 [main] DEBUG JbpmContext : closing JbpmContext
       [junit] Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0.062 sec
       [junit] TEST org.jbpm.context.exe.CustomVariableStringIdDbTest FAILED
      


      I would really appreciate if someone who has successfully done this can help me out.

      Thanks,Kazam.

        • 1. Re: Oracle 10G and JBPM 3.1.1 Issues
          falazar Novice

          Kazaam,
          If you send me your email address I can send you a copy of our internal wiki, which contains the instructions we used to get the starter kit up and working with the Oracle database.
          Everything went well for us there, except there were two tests that failed, mainly due to bad test procedure, one was referrring to the old hibernate database, and another to a missing class.
          It should contain pretty detailed instructions for you.

          James Ratcliff

          • 2. Re: Oracle 10G and JBPM 3.1.1 Issues
            falazar Novice

            Here's a line from our wiki that may help:
            When this completes, you can examine detailed reports on all the tests by loading jbpm-db/build/oracle/testfiles/index.html in your web browser.

            When I first ran the test, I got lots of errors back due to a missing C3P0 module. This is explained on the JBOSS site. (http://jboss.com/index.html?module=bb&op=viewtopic&p=3932199)

            Running this test on the JBPM starter kit, we find three errors. One is a class not found error which seems to result from a bad configuration file specifying a non-existent class, and the other two are in the org.jbpm.graph.exe.SuspendAndResumeDbTest class, apparently due to a hard-coded reference to the Hypersonic SQL DB, when in fact we're testing against Oracle.

            Maybe that will help some.

            James Ratcliff

            • 3. Re: Oracle 10G and JBPM 3.1.1 Issues
              kazam Newbie

              Thanks James,
              I appreciate your help. Please take a look at my profile for the email address, I have also sent you an email.
              I would get back once I try adding the cp30 jar or taking it out.
              Thanks Again,
              Kazam.

              • 4. Re: Oracle 10G and JBPM 3.1.1 Issues
                Koen Aers Master

                James,

                We are always interested in taking back your enhancements if you e.g. worked around this hard coded reference to Hypersonic. Also, if the info is not secret, why not publish the Oracle migration instructions on the jBPM wiki as well?

                Regards,
                Koen

                • 5. Re: Oracle 10G and JBPM 3.1.1 Issues
                  falazar Novice

                  I am working on some of the stuff now, trying to get everything all cleaned up and usable.

                  James

                  • 6. Re: Oracle 10G and JBPM 3.1.1 Issues
                    Chad Cummings Newbie

                     

                    I am working on some of the stuff now, trying to get everything all cleaned up and usable.

                    James

                    Has this been published to the wiki yet... (the steps for setting up on oracle)
                    The date on the previous post looks to be newer that what is in the wiki. :)

                    I'm wanting to setup jBPM on an Oracle AS 10.1.2 with an Oracle 10g DB.
                    Each webapp would have the jBPM jar and supporting jars (hibernate) bundled with it.

                    What are all the different types of deployments for jBPM?
                    Is the EJB wrapper still an option? we may need clustering later on.

                    Also, I noticed in the JSF console webapp for 3.1, there were a lot of warnings for using the deprecated method JbpmSession(Session). Is this
                    going to be updated soon?

                    Is it typical to have one jBPM DB 5 different webapps, or would you / could you setup different jBPM DB's for each webapp?

                    Thanks,
                    Chad

                    • 7. Re: Oracle 10G and JBPM 3.1.1 Issues
                      Donald Warf Newbie

                      After following the docs, I can generate the scripts for oracle10g, and the scripts run fine in oracle.

                      Currently, ant oracle.test achieves 98%, w/only 4 errors.

                      My question is as why does it the test keep running the SchemaExport, etc. on hsqldb? Here are to snippets of the output indicating loading the oracle information from hibernate.properties and then using C3P0 using the hsqldb driver?


                      [junit] 14:40:34,723 [main] DEBUG JbpmContext : creating JbpmContext
                      [junit] 14:40:34,723 [main] DEBUG DbPersistenceServiceFactory : creating schema export
                      [junit] 14:40:34,763 [main] INFO Environment : Hibernate 3.1
                      [junit] 14:40:34,763 [main] INFO Environment : loaded properties from resource hibernate.properties: {hibernate.connection.driver_class=oracle.jdbc.driver.OracleDriver, hibernate.cglib.use_reflection_optimizer=true, hibernate.c3p0.max_size=5, hibernate.dialect=org.hibernate.dialect.Oracle9Dialect, hibernate.c3p0.min_size=1, hibernate.query.substitutions=true 1, false 0, hibernate.connection.username=jbpmtest, hibernate.connection.url=jdbc:oracle:thin:@//127.0.0.1:1521/XE, hibernate.show_sql=true, hibernate.connection.password=****}
                      [junit] 14:40:34,763 [main] INFO Environment : using CGLIB reflection optimizer
                      [junit] 14:40:34,773 [main] INFO Environment : using JDK 1.4 java.sql.Timestamp handling
                      [junit] 14:40:34,823 [main] DEBUG HibernateHelper : creating hibernate configuration resource 'hibernate.cfg.xml'
                      .
                      .
                      .
                      [junit] 14:40:38,048 [main] INFO Configuration : processing foreign key constraints
                      [junit] 14:40:38,078 [main] INFO SchemaExport : Running hbm2ddl schema export
                      [junit] 14:40:38,078 [main] INFO SchemaExport : exporting generated schema to database
                      [junit] 14:40:38,078 [main] INFO C3P0ConnectionProvider : C3P0 using driver: org.hsqldb.jdbcDriver at URL: jdbc:hsqldb:mem:.;sql.enforce_strict_size=true
                      [junit] 14:40:38,078 [main] INFO C3P0ConnectionProvider : Connection properties: {user=sa, password=****}
                      [junit] 14:40:38,078 [main] INFO C3P0ConnectionProvider : autocommit mode: false
                      [junit] Initializing c3p0 pool... com.mchange.v2.c3p0.PoolBackedDataSource@c3c315 [ connectionPoolDataSource -> com.mchange.v2.c3p0.WrapperConnectionPoolDataSource@1d88db7 [ acquireIncrement -> 1, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 0, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, idleConnectionTestPeriod -> 0, initialPoolSize -> 1, maxIdleTime -> 0, maxPoolSize -> 5, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, nestedDataSource -> com.mchange.v2.c3p0.DriverManagerDataSource@1202d69 [ description -> null, driverClass -> null, factoryClassLocation -> null, jdbcUrl -> jdbc:hsqldb:mem:.;sql.enforce_strict_size=true, properties -> {user=******, password=******} ] , preferredTestQuery -> null, propertyCycle -> 300, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, usesTraditionalReflectiveProxies -> false ] , factoryClassLocation -> null, numHelperThreads -> 3, poolOwnerIdentityToken -> c3c315 ]
                      [junit] alter table JBPM_ACTION drop constraint FK_ACTION_EVENT
                      [junit] alter table JBPM_ACTION drop constraint FK_ACTION_EXPTHDL


                      Any suggestion or pointers would be greatly appreciated.

                      I noticed in kazam's post the C3P0 connection used the oracle driver. Any thoughts?

                      Thanks,

                      warfster