Quote:
Thanks for the help people, but I won't be back.
Hmmmm .... :-)
Ok, seriously now.
I don't think this is the right forum to ask this - since this is plain Spring usage case - no EJB3 stuff in sight.
Anway, here's a little help.
I think you are using the wrong kind of TransactionManager.
When I used Hibernate with Spring I used this kind of xml stuff:
Code:
<bean id="hibernateTransactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
<property name="sessionFactory"><ref local="sessionFactory"/></property>
</bean>
<!-- basic hibernate dao -->
<bean id="basicDAOImpl" class="com.gl.ecos.data.dao.HibernateBasicDAO">
<property name="sessionFactory"><ref local="sessionFactory"/></property>
<property name="rootModuleId"><value>1</value></property>
</bean>
<bean id="basicDAO" class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
<property name="transactionManager"><ref local="hibernateTransactionManager"/></property>
<property name="target"><ref local="basicDAOImpl"/></property>
<property name="transactionAttributes">
<props>
<prop key="find*">PROPAGATION_SUPPORTS,readOnly</prop>
<prop key="load*">PROPAGATION_SUPPORTS,readOnly</prop>
<prop key="save*">PROPAGATION_REQUIRED</prop>
<prop key="delete*">PROPAGATION_REQUIRED</prop>
</props>
</property>
</bean>
Ok, this is the old way - no annotations involved in classes on methods.
But most important stuff - in what way are you using this?
Where does the exception fail, is this web stuff, Swing client, ...