Sam Mano [
https://community.jboss.org/people/artist123] created the discussion
"Re: JPBM persistence and transaction Questions"
To view the discussion, visit:
https://community.jboss.org/message/779978#779978
--------------------------------------------------------------
Yes, It is working fine while using single persistence unit with LocalHT, what happen if I
want to use mina or hornetq. Is still applicable using single persistence unit? I tried HT
server starts good, but process fails...while creating the knowledgesession from
jpaknowlege service, the environment breaks bcos of btm transactionservice
(i am using com.mysql.jdbc.jdbc2.optional.MysqlXADataSource not btm)
I got the following error...
javax.persistence.PersistenceException: [PersistenceUnit: org.jbpm.runtime.ht] Unable to
build EntityManagerFactory
at
org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:677)
at
org.hibernate.ejb.HibernatePersistence.createEntityManagerFactory(HibernatePersistence.java:126)
at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:52)
at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:34)
at com.salaboy.jbpm5.ProcessTest.createKnowledgeSession(ProcessTest.java:102)
at com.salaboy.jbpm5.ProcessTest.main(ProcessTest.java:59)
Caused by: org.hibernate.HibernateException: Could not obtain BTM transaction manager
instance
at
org.hibernate.transaction.BTMTransactionManagerLookup.getTransactionManager(BTMTransactionManagerLookup.java:50)
at org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:367)
at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1341)
at
org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:867)
at
org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:669)
... 5 more
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:48)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:600)
at
org.hibernate.transaction.BTMTransactionManagerLookup.getTransactionManager(BTMTransactionManagerLookup.java:47)
... 9 more
Caused by: bitronix.tm.utils.InitializationException: cannot open disk journal
at
bitronix.tm.BitronixTransactionManager.<init>(BitronixTransactionManager.java:75)
at
bitronix.tm.TransactionManagerServices.getTransactionManager(TransactionManagerServices.java:62)
... 14 more
Caused by: java.io.IOException: The process cannot access the file because another process
has locked a portion of the file.
at java.io.FileDescriptor.read(Native Method)
at java.io.FileDescriptor.read(FileDescriptor.java:77)
at java.io.RandomAccessFile.read(RandomAccessFile.java:308)
at java.io.RandomAccessFile.readInt(RandomAccessFile.java:762)
at bitronix.tm.journal.TransactionLogHeader.<init>(TransactionLogHeader.java:96)
at
bitronix.tm.journal.TransactionLogAppender.<init>(TransactionLogAppender.java:69)
at bitronix.tm.journal.DiskJournal.open(DiskJournal.java:151)
at
bitronix.tm.BitronixTransactionManager.<init>(BitronixTransactionManager.java:62)
... 15 more
--------------------------------------------------------------
Reply to this message by going to Community
[
https://community.jboss.org/message/779978#779978]
Start a new discussion in jBPM at Community
[
https://community.jboss.org/choose-container!input.jspa?contentType=1&...]