开发者

Which Aspect/Interceptor handles the @Transactional annotation

开发者 https://www.devze.com 2023-02-27 02:15 出处:网络
Does anyone know which class handles the @Tra开发者_StackOverflow中文版nsactional annotation? I am searching for the source code that creates the transaction, specifically.I\'ve done a deep code analy

Does anyone know which class handles the @Tra开发者_StackOverflow中文版nsactional annotation? I am searching for the source code that creates the transaction, specifically.


I've done a deep code analysis for the @Transactional stuff here: http://doanduyhai.wordpress.com/2011/11/20/spring-transactional-explained/

Be carefull, this analysis only focus on JPA transaction. I did not consider datasources other than database but I guess the approach is similar


TransactionInterceptor handles the interception logic, but obviously with the assistance of a lot of other infrastructure classes. That's the best place to start, though. The transaction sync stuff is pretty fearsome when you start getting into the source code.

The processing of @Transactional, and its parsing into the neutral transaction descriptor object model, is done by AnnotationTransactionAttributeSource.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号