Hi all,
I am using Declarative Transactional Support in spring,basically all the service classes are annotated with @Transactional and in code I am using this
Now in one of the DAO method Exception is thrown deliberately if object is not found in DB. Can somebody please let me know whether it would result in automatic closing of session or I need to close the session manually when some exception is thrown by DAO layer ?
I am using Declarative Transactional Support in spring,basically all the service classes are annotated with @Transactional and in code I am using this
Code:
Session session=getHibernateTemplate().getSessionFactory().getCurrentSession();