Quantcast
Channel: Nested transaction on Spring - Stack Overflow
Viewing all articles
Browse latest Browse all 4

Answer by brettjonesdev for Nested transaction on Spring

$
0
0

This is not specifically a problem with @Transactional. It is due to the configuration of your <tx:annotation-driven/>.

Spring uses two different AOP mechanisms: JDK dynamic proxies or CGLIB. JDK dynamic proxies is the default and it works through the use of interfaces at run-time. CGLIB works by generating subclasses at compile-time. If you specify <tx:annotation-driven proxy-target-class="true"/>, Spring will use CGLIB, and your second @Transactional will fire.

You can read more about the subject here.


Viewing all articles
Browse latest Browse all 4

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>