Hi,
I'm sure this has been encountered several times before, but unfortunately I haven't been able to locate the solution in this forum.
My context contains the following:
<bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSes sionFactoryBean">
<property name="dataSource" ref="dataSource"/>
<property name="mappingResources">
<list>
<value>hbm.xml</value>
</list>
</property>
<property name="hibernateProperties">
<value>
hibernate.dialect=org.hibernate.dialect.Oracle10gD ialect
</value>
</property>
</bean>
<bean id="transactionManager" class="org.springframework.orm.hibernate3.Hibernat eTransactionManager">
<property name="sessionFactory" ref="sessionFactory"/>
</bean>
<tx:annotation-driven transaction-manager="transactionManager"/>
And the method that is called is as follows:
@Transactional
public void save(T t) {
Session session = sessionFactory.openSession();
session.save(t);
}
After my annotated method returns, a previously unsaved "t" now contains the proper ID, but the changes are never flushed through. I don't believe the transaction is ever committed. What could be the causes of this?
Thanks!


Reply With Quote
