5 Replies Latest reply on Jan 22, 2008 8:17 AM by Stephen Schwenker

    Porting JBPM to run on JBoss 4.0.4GA with PostgreSQL

    Stephen Schwenker Newbie

      Hello all,

      I'm trying to get JBpm to run on JBoss 4.0.4GA with a postgresql database.

      I've already upgraded the hibername and ehcache jar and recomipled everything.

      The acclication deploys properly but now I'm getting these errors.

      2006-10-13 11:54:50,585 DEBUG [org.hibernate.hql.ast.QueryTranslatorImpl] SQL: select message0_.ID_ as col_0_0_ from JBPM_MESSAGE message0_ where message0_.DESTINATION_=? and message0_.ISSUSPENDED_<>1 and (message0_.EXCEPTION_ is null)
      2006-10-13 11:54:50,585 DEBUG [org.hibernate.hql.ast.ErrorCounter] throwQueryException() : no errors
      2006-10-13 11:54:50,586 DEBUG [org.hibernate.jdbc.AbstractBatcher] about to open PreparedStatement (open PreparedStatements: 0, globally: 1)
      2006-10-13 11:54:50,586 DEBUG [org.hibernate.SQL] select message0_.ID_ as col_0_0_ from JBPM_MESSAGE message0_ where message0_.DESTINATION_=? and message0_.ISSUSPENDED_<>1 and (message0_.EXCEPTION_ is null)
      2006-10-13 11:54:50,589 DEBUG [org.hibernate.util.JDBCExceptionReporter] could not execute query using iterate [select timer0_.ID_ as col_0_0_ from JBPM_TIMER timer0_ where (timer0_.EXCEPTION_ is null) and timer0_.ISSUSPENDED_<>1 order by timer0_.DUEDATE_ asc]
      java.sql.SQLException: Table not found in statement [select timer0_.ID_ as col_0_0_ from JBPM_TIMER timer0_ where (timer0_.EXCEPTION_ is null) and timer0_.ISSUSPENDED_<>1 order by timer0_.DUEDATE_ asc]
       at org.hsqldb.jdbc.Util.throwError(Unknown Source)
       at org.hsqldb.jdbc.jdbcPreparedStatement.<init>(Unknown Source)
       at org.hsqldb.jdbc.jdbcConnection.prepareStatement(Unknown Source)
       at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.doPrepareStatement(BaseWrapperManagedConnection.java:349)
       at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.prepareStatement(BaseWrapperManagedConnection.java:337)
       at org.jboss.resource.adapter.jdbc.WrappedConnection.prepareStatement(WrappedConnection.java:187)
       at org.hibernate.jdbc.AbstractBatcher.getPreparedStatement(AbstractBatcher.java:497)
       at org.hibernate.jdbc.AbstractBatcher.getPreparedStatement(AbstractBatcher.java:415)
       at org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:139)
       at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1561)
       at org.hibernate.loader.hql.QueryLoader.iterate(QueryLoader.java:415)
       at org.hibernate.hql.ast.QueryTranslatorImpl.iterate(QueryTranslatorImpl.java:375)
       at org.hibernate.engine.query.HQLQueryPlan.performIterate(HQLQueryPlan.java:224)
       at org.hibernate.impl.SessionImpl.iterate(SessionImpl.java:1185)
       at org.hibernate.impl.QueryImpl.iterate(QueryImpl.java:46)
       at org.jbpm.db.SchedulerSession.findTimersByDueDate(SchedulerSession.java:82)
       at org.jbpm.scheduler.impl.SchedulerThread.executeTimers(SchedulerThread.java:106)
       at org.jbpm.scheduler.impl.SchedulerThread.run(SchedulerThread.java:70)
      2006-10-13 11:54:50,589 DEBUG [org.hibernate.util.JDBCExceptionReporter] could not execute query using iterate [select message0_.ID_ as col_0_0_ from JBPM_MESSAGE message0_ where message0_.DESTINATION_=? and message0_.ISSUSPENDED_<>1 and (message0_.EXCEPTION_ is null)]
      java.sql.SQLException: Table not found in statement [select message0_.ID_ as col_0_0_ from JBPM_MESSAGE message0_ where message0_.DESTINATION_=? and message0_.ISSUSPENDED_<>1 and (message0_.EXCEPTION_ is null)]
       at org.hsqldb.jdbc.Util.throwError(Unknown Source)
       at org.hsqldb.jdbc.jdbcPreparedStatement.<init>(Unknown Source)
       at org.hsqldb.jdbc.jdbcConnection.prepareStatement(Unknown Source)
       at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.doPrepareStatement(BaseWrapperManagedConnection.java:349)
       at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.prepareStatement(BaseWrapperManagedConnection.java:337)
       at org.jboss.resource.adapter.jdbc.WrappedConnection.prepareStatement(WrappedConnection.java:187)
       at org.hibernate.jdbc.AbstractBatcher.getPreparedStatement(AbstractBatcher.java:497)
       at org.hibernate.jdbc.AbstractBatcher.getPreparedStatement(AbstractBatcher.java:415)
       at org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:139)
       at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1561)
       at org.hibernate.loader.hql.QueryLoader.iterate(QueryLoader.java:415)
       at org.hibernate.hql.ast.QueryTranslatorImpl.iterate(QueryTranslatorImpl.java:375)
       at org.hibernate.engine.query.HQLQueryPlan.performIterate(HQLQueryPlan.java:224)
       at org.hibernate.impl.SessionImpl.iterate(SessionImpl.java:1185)
       at org.hibernate.impl.QueryImpl.iterate(QueryImpl.java:46)
       at org.jbpm.db.MessagingSession.getMessageIterator(MessagingSession.java:114)
       at org.jbpm.db.MessagingSession.nextMessage(MessagingSession.java:70)
       at org.jbpm.msg.db.DbMessageService.receiveNoWait(DbMessageService.java:75)
       at org.jbpm.msg.command.CommandExecutorThread.executeCommand(CommandExecutorThread.java:118)
       at org.jbpm.msg.command.CommandExecutorThread.run(CommandExecutorThread.java:79)
      2006-10-13 11:54:50,590 WARN [org.hibernate.util.JDBCExceptionReporter] SQL Error: -22, SQLState: S0002
      2006-10-13 11:54:50,591 WARN [org.hibernate.util.JDBCExceptionReporter] SQL Error: -22, SQLState: S0002
      2006-10-13 11:54:50,591 ERROR [org.hibernate.util.JDBCExceptionReporter] Table not found in statement [select timer0_.ID_ as col_0_0_ from JBPM_TIMER timer0_ where (timer0_.EXCEPTION_ is null) and timer0_.ISSUSPENDED_<>1 order by timer0_.DUEDATE_ asc]
      2006-10-13 11:54:50,591 ERROR [org.hibernate.util.JDBCExceptionReporter] Table not found in statement [select message0_.ID_ as col_0_0_ from JBPM_MESSAGE message0_ where message0_.DESTINATION_=? and message0_.ISSUSPENDED_<>1 and (message0_.EXCEPTION_ is null)]
      2006-10-13 11:54:50,592 ERROR [org.jbpm.db.SchedulerSession] org.hibernate.exception.SQLGrammarException: could not execute query using iterate
      2006-10-13 11:54:50,592 DEBUG [org.jbpm.msg.command.CommandExecutorThread] command 'null' threw exception. rolling back transaction
      org.hibernate.exception.SQLGrammarException: could not execute query using iterate
       at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:67)
       at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
       at org.hibernate.loader.hql.QueryLoader.iterate(QueryLoader.java:443)
       at org.hibernate.hql.ast.QueryTranslatorImpl.iterate(QueryTranslatorImpl.java:375)
       at org.hibernate.engine.query.HQLQueryPlan.performIterate(HQLQueryPlan.java:224)
       at org.hibernate.impl.SessionImpl.iterate(SessionImpl.java:1185)
       at org.hibernate.impl.QueryImpl.iterate(QueryImpl.java:46)
       at org.jbpm.db.MessagingSession.getMessageIterator(MessagingSession.java:114)
       at org.jbpm.db.MessagingSession.nextMessage(MessagingSession.java:70)
       at org.jbpm.msg.db.DbMessageService.receiveNoWait(DbMessageService.java:75)
       at org.jbpm.msg.command.CommandExecutorThread.executeCommand(CommandExecutorThread.java:118)
       at org.jbpm.msg.command.CommandExecutorThread.run(CommandExecutorThread.java:79)
      Caused by: java.sql.SQLException: Table not found in statement [select message0_.ID_ as col_0_0_ from JBPM_MESSAGE message0_ where message0_.DESTINATION_=? and message0_.ISSUSPENDED_<>1 and (message0_.EXCEPTION_ is null)]
       at org.hsqldb.jdbc.Util.throwError(Unknown Source)
       at org.hsqldb.jdbc.jdbcPreparedStatement.<init>(Unknown Source)
       at org.hsqldb.jdbc.jdbcConnection.prepareStatement(Unknown Source)
       at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.doPrepareStatement(BaseWrapperManagedConnection.java:349)
       at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.prepareStatement(BaseWrapperManagedConnection.java:337)
       at org.jboss.resource.adapter.jdbc.WrappedConnection.prepareStatement(WrappedConnection.java:187)
       at org.hibernate.jdbc.AbstractBatcher.getPreparedStatement(AbstractBatcher.java:497)
       at org.hibernate.jdbc.AbstractBatcher.getPreparedStatement(AbstractBatcher.java:415)
       at org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:139)
       at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1561)
       at org.hibernate.loader.hql.QueryLoader.iterate(QueryLoader.java:415)
       ... 9 more
      2006-10-13 11:54:50,600 DEBUG [org.jbpm.JbpmContext] closing JbpmContext
      2006-10-13 11:54:50,592 DEBUG [org.jbpm.JbpmContext] closing JbpmContext
      



      Please notice the lines with timer0_.ISSUSPENDED_<>1 in them. I'm not sure if this is a hibernate problem that the 1 is not being converted to a proper boolean value or if the 1 is hardcoded in the jbpm source. But the 1 is suposed to be the word true because postgres requires it to be a boolean word and not an integer.

      I'll also be posting this in the jbpm forum.


      Can anyone help with this? Thank you,


      Steve.