Hey there, I have a class with a public @Transactional method which loads some values from the DB.
I'm declaring the bean in the xml with the init-method argument set.
The problem I'm facing is that it seams that the init-method gets called before the bean is proxified because of the @Transactional. So it's failing because Hibernate's losing the connection.
Is this correct ? I thought that init-method was called after "everything" was ready. Including the proxy.
If so, how do I change the order so that init-method calls the proxified bean and not the vainilla implementation?
PS: yes, Spring AOP is configured correctly and it works OK if I call the init-method from outside (after the bean has been created completely) and not from the bean declaration itself.
Thank you!
Fede.


Reply With Quote
