if you want to use just local transactions below should be enough in your
spring.xml file
then in your persistence.xml file should look like below
org.hibernate.ejb.HibernatePersistence
config/droolsflow/jpa/orm.xml
org.drools.persistence.session.SessionInfo
org.drools.persistence.processinstance.ProcessInstanceInfo
org.drools.persistence.processinstance.variabletypes.JPAPersistedVariable
org.drools.persistence.processinstance.variabletypes.VariableInstanceInfo
org.drools.persistence.processinstance.variabletypes.SerializablePersistedVariable
org.drools.persistence.processinstance.WorkItemInfo
and finally when you build your statefullknowledgeSession the code should
look like below
Environment env = KnowledgeBaseFactory.newEnvironment();
env.set( EnvironmentName.ENTITY_MANAGER_FACTORY,
getEntityManagerFactorySpringBean() );
env.set(EnvironmentName.TRANSACTION_MANAGER, getDroolsFlowTxManager() );
ksession = JPAKnowledgeService.newStatefulKnowledgeSession( kbase, null,
env);
--
View this message in context:
http://drools-java-rules-engine.46999.n3.nabble.com/Can-Drools-Flow-Persi...
Sent from the Drools - User mailing list archive at
Nabble.com.