=== Environment ============================== - jBPM Version : 4.1 - Database : Oracle 10.2 - JDK : 1.6 - Container : JBoss 4.2.3 - Configuration : custom jbpm.cfg.xml only, see below - Libraries : the exact versions of the libs from inside the jbpm distribution
=== Process ================================== Just a Test Jpdl: Start -> Task -> End === Stacktrace ============================== No stack trace, only a warning: 15:32:14,624 WARN [AbstractEntityManagerImpl] Cannot join transaction: do not override hibernate.transaction.factory_class === Problem description ========================= I try to integrate JBPM4.1 with my application based on Seam 2.2.0 and Richfaces 3.3.1. We are using a persistence.xml instead of jbpm.hibernate.cfg.xml so I modified the persistence.xml: <?xml version="1.0" encoding="UTF-8" standalone="no"?> | <!-- Persistence deployment descriptor for dev profile --> | <persistence xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0" xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd"> | | <persistence-unit name="pmscada"> | <provider>org.hibernate.ejb.HibernatePersistence</provider> | <jta-data-source>java:/pmscadaDatasource</jta-data-source> | | <!-- JBPM4 mappings --> | <mapping-file>jbpm.repository.hbm.xml</mapping-file> | <mapping-file>jbpm.execution.hbm.xml</mapping-file> | <mapping-file>jbpm.history.hbm.xml</mapping-file> | <mapping-file>jbpm.task.hbm.xml</mapping-file> | <mapping-file>jbpm.identity.hbm.xml</mapping-file> | | <properties> | <property name="hibernate.dialect" value="org.hibernate.dialect.Oracle10gDialect"/> | <property name="hibernate.default_schema" value="schema"/> | <property name="hibernate.hbm2ddl.auto" value="create"/> | <property name="jboss.entity.manager.factory.jndi.name" value="java:/pmscadaEntityManagerFactory"/> | <property name="hibernate.show_sql" value="false"/> | | <property name="hibernate.format_sql" value="true"/> | <property name="use_sql_comments" value="true"/> | | <property name="hibernate.transaction.factory_class" value="org.hibernate.transaction.JTATransactionFactory"/> | <properties> | </persistence-unit> | </persistence> | In the jbpm.cfg.xml I removed <!--hibernate-session-factory /--> and added <pilot-integration/>, the remain is like tho original jbpm.cfg.xml. pilot-integration is declared in jbpm.user.wire.bindings.xml: | <wire-bindings> | | <binding class="...PilotBinding" /> | | </wire-bindings> | This class provides a PilotDescriptor | ... | public class PilotBinding extends WireDescriptorBinding | { | public PilotBinding() | { | super( "pilot-integration" ); | } | | /** {...@inheritdoc} */ | @Override | public Object parse( Element element, Parse parse, Parser parser ) | { | return new PilotDescriptor(); | } | | } | And the PilotDescriptor returns the Hibernate SessionFactory: | ... | public class PilotDescriptor extends AbstractDescriptor | { | private static final long serialVersionUID = 3380911977887594063L; | | /** The session factory. */ | private static SessionFactory sessionFactory; | | public static void setSessionFactory( SessionFactory sessionFactory ) | { | PilotDescriptor.sessionFactory = sessionFactory; | } | | /** {...@inheritdoc} */ | @Override | public Object construct( WireContext wireContext ) | { | return sessionFactory; | } | | /** {...@inheritdoc} */ | @Override | public Class<?> getType( WireDefinition wireDefinition ) | { | return SessionFactory.class; | } | } | The Session factory is set on startup using the static function. This configuration is running fine, it is possible to put "our" Hibernate entities as varibles in ProcessInstances. My first question is now: Is this the right way to integrate JBPM in my application ? The second: What does the Warning Cannot join transaction: do not override hibernate.transaction.factory_class mean ? The application is running anyway. Thanks, Joerg View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4257860#4257860 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4257860 _______________________________________________ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user