[jboss-user] [jBPM] - Commit transaction after each service task?
Richard Evans
do-not-reply at jboss.com
Mon Jun 18 12:03:33 EDT 2012
Richard Evans [https://community.jboss.org/people/r3vans] created the discussion
"Commit transaction after each service task?"
To view the discussion, visit: https://community.jboss.org/message/742450#742450
--------------------------------------------------------------
Hello there,
JBPM 5.1 on Tomcat, persistence configured in Spring
I have a number of processes, each with a series of service tasks punctuated by timers.
I would like to persist process data after every service task to be confident that it is recoverable on catastrophic failure. I find, though, that data is committed only at timers and end of process. Is it possible to take control of transactions at a more granular level to get jbpm to commit more regularly?
My config..
<bean class="org.springframework.orm.jpa.JpaTransactionManager"
id="transactionManager">
<property name="entityManagerFactory" ref="entityManagerFactory" />
</bean>
<tx:annotation-driven mode="aspectj"
transaction-manager="transactionManager" />
<bean class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean"
id="entityManagerFactory">
<property name="persistenceUnitName" value="persistenceUnit" />
<property name="dataSource" ref="dataSource" />
</bean>
<bean class="org.springframework.orm.jpa.JpaTransactionManager"
id="transactionManager">
<property name="entityManagerFactory" ref="entityManagerFactory" />
</bean>
<drools:jpa-persistence>
<drools:transaction-manager ref="transactionManager" />
<drools:entity-manager-factory ref="entityManagerFactory" />
</drools:jpa-persistence>
Thanks,
Richard
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/742450#742450]
Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20120618/bd26b445/attachment.html
More information about the jboss-user
mailing list