Announcement Announcement Module No announcement yet. Hibernate
interceptor and threading Page Title Module Move Remove Collapse
Conversation Detail Module   • Filter   • Time   • Show Clear
All new posts    • Hibernate interceptor and threading      I
have a need to execute some business logic whenever certain
domain objects are inserted/updated. The problem is that the
business logic is complex and requires several DAOs for read-
only data access. Without duplicating logic, how can I utilize
these DAOs from within the transaction scope of the interceptor?
I am using HibernateTransactionManager with transaction proxies
around my business objects.      1) Does the
HibernateTransactionManager support PROPOGATION_REQUIRES_NEW?
Will this create another Session for use by the read-only DAOs?
2) Is the Session bound to the current thread? If so, can I
execute this business logic in a separate thread? What would I
have to do to ensure that this gets executed after the changes
to the object have been commit