0 Replies Latest reply on Sep 11, 2014 5:13 PM by jbpm 6

    No operations allowed after connection closed

    jbpm 6 Newbie

      Hi,

       

      I am using jbpm 6.1.0_CR1, I connect to mysql with the configuration below. When I run the process and task myself it's mostly fine, but when another user login and run more processes and tasks then we get "No operations allowed after connection closed". Can anyone please help?

       

      <datasources>

                      <datasource jndi-name="java:jboss/datasources/jbpmDS" pool-name="MySQLDS" enabled="true" use-java-context="true">

                          <connection-url>jdbc:mysql://10.30.20.176:3306/jbpm</connection-url>

                          <driver>mysql</driver>

                          <pool>

                              <min-pool-size>30</min-pool-size>

                              <max-pool-size>50</max-pool-size>

                          </pool>

                          <security>

                              <user-name>jbpm</user-name>

                              <password>yellow</password>

                          </security>

                      </datasource>

                      <drivers>

                          <driver name="mysql" module="com.mysql">

                              <xa-datasource-class>com.mysql.jdbc.jdbc2.optional.MysqlXADataSource</xa-datasource-class>

                          </driver>

                      </drivers>

                  </datasources>

       

      Log:

      09:02:40,817 ERROR [org.hibernate.engine.jdbc.spi.SqlExceptionHelper] (pool-21-thread-1) No operations allowed after connection closed.

      09:02:40,824 WARN  [org.jbpm.shared.services.impl.TransactionalCommandService] (pool-21-thread-1) Could not commit session: javax.persistence.PersistenceException: org.hibernate.exception.JDBCConnectionException: No operations allowed after connection closed.

              at org.hibernate.ejb.AbstractEntityManagerImpl.convert(AbstractEntityManagerImpl.java:1361) [hibernate-entitymanager-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.ejb.AbstractEntityManagerImpl.convert(AbstractEntityManagerImpl.java:1289) [hibernate-entitymanager-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.ejb.QueryImpl.getSingleResult(QueryImpl.java:313) [hibernate-entitymanager-4.0.1.Final.jar:4.0.1.Final]

              at org.jbpm.shared.services.impl.JpaPersistenceContext.queryStringWithParameters(JpaPersistenceContext.java:151) [jbpm-shared-services-6.1.0.CR1.jar:6.1.0.CR1]

              at org.jbpm.shared.services.impl.JpaPersistenceContext.queryAndLockWithParametersInTransaction(JpaPersistenceContext.java:37) [jbpm-shared-services-6.1.0.CR1.jar:6.1.0.CR1]

              at org.jbpm.executor.impl.jpa.ExecutorQueryServiceImpl$LockAndUpdateRequestInfoCommand.execute(ExecutorQueryServiceImpl.java:214) [jbpm-executor-6.1.0.CR1.jar:6.1.0.CR1]

              at org.jbpm.executor.impl.jpa.ExecutorQueryServiceImpl$LockAndUpdateRequestInfoCommand.execute(ExecutorQueryServiceImpl.java:201) [jbpm-executor-6.1.0.CR1.jar:6.1.0.CR1]

              at org.jbpm.shared.services.impl.TransactionalCommandService.execute(TransactionalCommandService.java:38) [jbpm-shared-services-6.1.0.CR1.jar:6.1.0.CR1]

              at org.jbpm.executor.impl.jpa.ExecutorQueryServiceImpl.getRequestForProcessing(ExecutorQueryServiceImpl.java:196) [jbpm-executor-6.1.0.CR1.jar:6.1.0.CR1]

              at org.jbpm.executor.impl.AvailableJobsExecutor.executeJob(AvailableJobsExecutor.java:89) [jbpm-executor-6.1.0.CR1.jar:6.1.0.CR1]

              at org.jbpm.executor.impl.ExecutorRunnable.run(ExecutorRunnable.java:42) [jbpm-executor-6.1.0.CR1.jar:6.1.0.CR1]

              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) [rt.jar:1.7.0_55]

              at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304) [rt.jar:1.7.0_55]

              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178) [rt.jar:1.7.0_55]

              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [rt.jar:1.7.0_55]

              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_55]

              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_55]

              at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_55]

      Caused by: org.hibernate.exception.JDBCConnectionException: No operations allowed after connection closed.

              at org.hibernate.exception.internal.SQLExceptionTypeDelegate.convert(SQLExceptionTypeDelegate.java:67) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:47) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:125) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:110) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.engine.jdbc.internal.proxy.ConnectionProxyHandler.continueInvocation(ConnectionProxyHandler.java:146) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.engine.jdbc.internal.proxy.AbstractProxyHandler.invoke(AbstractProxyHandler.java:81) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at com.sun.proxy.$Proxy43.prepareStatement(Unknown Source)

              at org.hibernate.engine.jdbc.internal.StatementPreparerImpl$5.doPrepare(StatementPreparerImpl.java:147) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.engine.jdbc.internal.StatementPreparerImpl$StatementPreparationTemplate.prepareStatement(StatementPreparerImpl.java:166) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.engine.jdbc.internal.StatementPreparerImpl.prepareQueryStatement(StatementPreparerImpl.java:145) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1739) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.loader.Loader.doQuery(Loader.java:828) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:289) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.loader.Loader.doList(Loader.java:2463) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.loader.Loader.doList(Loader.java:2449) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2279) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.loader.Loader.list(Loader.java:2274) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:470) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.hql.internal.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:355) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.engine.query.spi.HQLQueryPlan.performList(HQLQueryPlan.java:196) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.internal.SessionImpl.list(SessionImpl.java:1115) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.internal.QueryImpl.list(QueryImpl.java:101) [hibernate-core-4.0.1.Final.jar:4.0.1.Final]

              at org.hibernate.ejb.QueryImpl.getSingleResult(QueryImpl.java:280) [hibernate-entitymanager-4.0.1.Final.jar:4.0.1.Final]

              ... 15 more

      Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: No operations allowed after connection closed.

              at sun.reflect.GeneratedConstructorAccessor285.newInstance(Unknown Source) [:1.7.0_55]

              at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) [rt.jar:1.7.0_55]

              at java.lang.reflect.Constructor.newInstance(Constructor.java:526) [rt.jar:1.7.0_55]

              at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)

              at com.mysql.jdbc.Util.getInstance(Util.java:386)

              at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1013)

              at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:987)

              at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:982)