springboot-multiple-dataSources icon indicating copy to clipboard operation
springboot-multiple-dataSources copied to clipboard

使用注解事务的问题

Open BrightMi opened this issue 8 years ago • 2 comments
trafficstars

使用事务的时候会有问题,切换不到另外一个数据源上

BrightMi avatar Jun 22 '17 04:06 BrightMi

您好,我也遇到这个问题了,请问这个bug现在有解决办法了吗?

anyuan95 avatar Oct 11 '17 10:10 anyuan95

已解决 在DataSourceAspect类上加注解 @Order(-1)// 保证该AOP在@Transactional之前执行

BrightMi avatar Oct 11 '17 10:10 BrightMi