Hi all,

I have been working with the new jBPM code in the spring-modules CVS, but none of the calls are being persisted to the database. I have the following spring config, but it seems the JbpmSessionFactoryUtils class cannot get a handle on a Transaction via the TransactionSynchronizationManager. Whenever I instantiate a Hibernate Transaction directly, I have no problems. Also, I am able read data from the database, just not write. Any suggestions?

Thanks,
Julian

Code:
    <bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource">
        <property name="driverClassName" value="org.postgresql.Driver"/>
        <property name="url" value="jdbc&#58;postgresql&#58;//localhost&#58;5432/jbpm/>
        <property name="username" value="sa"/>
        <property name="password" value=""/>
    </bean>

    <bean id="hibernateSessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
        <property name="dataSource">
            <ref bean="dataSource"/>
        </property>
        <property name="mappingLocations">
            <value>classpath*&#58;/org/jbpm/**/*.hbm.xml</value>
        </property>
        <property name="hibernateProperties">
            <props>
                <prop key="hibernate.dialect">org.hibernate.dialect.PostgreSQLDialect</prop>
                <prop key="hibernate.show_sql">true</prop>
            </props>
        </property>
        <property name="schemaUpdate" value="true"/>
    </bean>

    <bean id="transactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
        <property name="sessionFactory" ref="hibernateSessionFactory"/>
    </bean>

    <bean id="hibernateConfiguration" factory-bean="&amp;hibernateSessionFactory" factory-method="getConfiguration"/>

    <bean id="jbpmSessionFactory" class="org.springframework.workflow.jbpm.LocalJbpmSessionFactoryBean">
        <property name="hibernateSessionFactory" ref="hibernateSessionFactory"/>
        <property name="hibernateConfiguration" ref="hibernateConfiguration"/>
    </bean>
    
    <bean id="jbpmTemplate" class="org.springframework.workflow.jbpm.JbpmTemplate">
        <property name="jbpmSessionFactory" ref="jbpmSessionFactory"/>
    </bean>