Hi jits_1998,

As an example, my principal custom object has, amongst its fields, a long that 
is an id of a jbpm process instance.

This custom object is saved in DB by Hibernate through a regular session while 
the jbpm process instance is saved using a jbpmcontext.

The hib. session is obtained from the same configuration as jbpm, for having 
the (few) tables in the same schema is not an issue.


  | public static Session createPersistantSession() {
  | DbPersistenceServiceFactory dbPersistenceServiceFactory = 
(DbPersistenceServiceFactory) 
instanceConfigurationJbpm.getServiceFactory("persistence");
  |     return dbPersistenceServiceFactory.getSessionFactory().openSession() ;
  | }
  | 

Right now, the issue in the post above is not anymore but I am facing a new one 
about contexts closed more than once

I'm using version 3.2


  | 11:11:03,653 [Thread-3] ERROR DbPersistenceService : problem rolling back 
after failed commit
  | org.hibernate.TransactionException: Transaction not successfully started
  |     at 
org.hibernate.transaction.JDBCTransaction.rollback(JDBCTransaction.java:149)
  |     at 
org.jbpm.persistence.db.DbPersistenceService.close(DbPersistenceService.java:166)
  |     at org.jbpm.svc.Services.close(Services.java:211)
  |     at org.jbpm.JbpmContext.close(JbpmContext.java:139)
  |     at com.aspheria.cerbere.Workflow.run(Workflow.java:515)
  |     at java.lang.Thread.run(Thread.java:534)
  | 11:11:03,653 [Thread-3] ERROR Services : problem closing service 
'persistence'
  | org.jbpm.persistence.JbpmPersistenceException: couldn't commit hibernate 
session
  |     at 
org.jbpm.persistence.db.DbPersistenceService.close(DbPersistenceService.java:172)
  |     at org.jbpm.svc.Services.close(Services.java:211)
  |     at org.jbpm.JbpmContext.close(JbpmContext.java:139)
  |     at com.xxxx.cerbere.Workflow.run(Workflow.java:515)
  |     at java.lang.Thread.run(Thread.java:534)
  | Caused by: org.hibernate.TransactionException: Transaction not successfully 
started
  |     at 
org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:100)
  |     at 
org.jbpm.persistence.db.DbPersistenceService.close(DbPersistenceService.java:162)
  |     ... 4 more
  | 
  |     ... 4 more
  | org.jbpm.JbpmException: closed JbpmContext more then once... check your 
try-finally's around JbpmContexts blocks
  |     at org.jbpm.JbpmConfiguration.popJbpmContext(JbpmConfiguration.java:521)
  |     at 
org.jbpm.JbpmConfiguration.jbpmContextClosed(JbpmConfiguration.java:537)
  |     at org.jbpm.JbpmContext.close(JbpmContext.java:144)
  |     at com.xxxx.cerbere.Workflow.run(Workflow.java:515)
  |     at java.lang.Thread.run(Thread.java:534)
  | 

Thanks for your help

JBaton


View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3970957#3970957

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3970957
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to