Spring Transactional 日誌記錄

一、主要代碼java

// 切換數據源
@DataSourceRouting
// 開始事務
@Transactional(rollbackFor = Exception.class)
public boolean test1(Long userId, List<String> labelList) {
    biz1(userId, labelList);

    biz2(userId, labelList);

    return true;
}

public boolean biz1(Long userId, List<String> labelList) {
    log.info("》》》》》》》》插入 FamilyPlanLabelDetail 》》》 開始");

    FamilyPlanLabelDetail familyPlanLabelDetail = new FamilyPlanLabelDetail();
    familyPlanLabelDetail.setUserId(userId);
    familyPlanLabelDetail.setCreateTime(new Date());
    int numLabelDetail = familyPlanDao.saveFamilyPlanLabelDetail(familyPlanLabelDetail);

    log.info("》》》》》》》》插入 FamilyPlanLabelDetail 》》》 結束");

    return true;
}

public boolean biz2(Long userId, List<String> labelList) throws Exception {
    log.info("》》》》》》》》插入 FamilyPlanLabel 》》》 開始");

    List<FamilyPlanLabel> list = new ArrayList();
    for (String labelName : labelList) {
        FamilyPlanLabel familyPlanLabel = new FamilyPlanLabel();
        familyPlanLabel.setUserId(userId);
        familyPlanLabel.setLabelName(labelName);
        familyPlanLabel.setType(FamilyPlanLabelTypeEnum.SYS_ADD.getCode());
        familyPlanLabel.setStatus(FamilyPlanLabelStatusEnum.USE.getCode());
        familyPlanLabel.setCreateTime(new Date());
        familyPlanLabel.setUpdateTime(new Date());

        list.add(familyPlanLabel);
    }
    int labelNum = familyPlanDao.saveFamilyPlanLabelByBatch(list);

    if (true) {
        // 模擬出異常
        throw new Exception("手動拋異常");
    }

    log.info("》》》》》》》》插入 FamilyPlanLabel 》》》 結束");

    return true;
}

 

2 開事務spring

2.1 開事務,正常的日誌apache

// 方法上有註解 @DataSourceRouting  @Transactional
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.client.transaction.manager.FamilyPlanTransactionManager.test1(...)方法執行開始執行,數據源切換到:master 

com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》查詢 FamilyPlanLabelDetail 》》》 開始 
// 由於在事務中,切換數據源並無用
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.queryFamilyPlanLabelDetailByUserId(...)方法執行開始執行,沒有配置數據源,切換到默認:master 
// 開啓事務
org.mybatis.spring.SqlSessionUtils Creating a new SqlSession 
org.mybatis.spring.SqlSessionUtils Registering transaction synchronization for SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@cdf939b] 
org.mybatis.spring.transaction.SpringManagedTransaction JDBC Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@eeede52] will be managed by Spring 
com.moon.core.dao.FamilyPlanDao.queryFamilyPlanLabelDetailByUserId ooo Using Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@eeede52] 
com.moon.core.dao.FamilyPlanDao.queryFamilyPlanLabelDetailByUserId ==>  Preparing: SELECT id, user_id AS userId, create_time AS createTime FROM t_detail WHERE user_id = ?  
com.moon.core.dao.FamilyPlanDao.queryFamilyPlanLabelDetailByUserId ==> Parameters: 1(Long) 
org.mybatis.spring.SqlSessionUtils Releasing transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@cdf939b] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.queryFamilyPlanLabelDetailByUserId(...)方法執行完成,清理數據源 
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》查詢 FamilyPlanLabelDetail 》》》 結束 

com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabelDetail 》》》 開始 
// 由於在事務中,切換數據源並無用
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail(...)方法執行開始執行,沒有配置數據源,切換到默認:master 
org.mybatis.spring.SqlSessionUtils Fetched SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@cdf939b] from current transaction 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ooo Using Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@eeede52] 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ==>  Preparing: INSERT INTO t_detail ( user_id, create_time ) VALUES ( ?, ? )  
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ==> Parameters: 1(Long), 2019-09-16 12:02:00.075(Timestamp) 
org.mybatis.spring.SqlSessionUtils Releasing transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@cdf939b] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail(...)方法執行完成,清理數據源 
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabelDetail 》》》 結束 

com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabel 》》》 開始 
// 由於在事務中,切換數據源並無用
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch(...)方法執行開始執行,沒有配置數據源,切換到默認:master 
org.mybatis.spring.SqlSessionUtils Fetched SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@cdf939b] from current transaction 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ooo Using Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@eeede52] 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ==>  Preparing: INSERT INTO t_label ( user_id, label_name, type, status, create_time, update_time ) VALUES ( ?, ?, ?, ?, ?, ? )  
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ==> Parameters: 1(Long), test1342966(String), 1(Integer), 1(Integer), 2019-09-16 12:02:00.917(Timestamp), 2019-09-16 12:02:00.917(Timestamp) 
org.mybatis.spring.SqlSessionUtils Releasing transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@cdf939b] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch(...)方法執行完成,清理數據源 
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabel 》》》 結束 

// 提交事務
org.mybatis.spring.SqlSessionUtils Transaction synchronization committing SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@cdf939b] 
org.mybatis.spring.SqlSessionUtils Transaction synchronization closing SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@cdf939b] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.client.transaction.manager.FamilyPlanTransactionManager.test1(...)方法執行完成,清理數據源

注意:session

(1)org.mybatis.spring.transaction.SpringManagedTransaction JDBC Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@3d2fb2bf] will be managed by Spring mybatis

(2)org.mybatis.spring.SqlSessionUtils Transaction synchronization committing SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@251c52c5] 
 app

2.2 開事務,出現異常回滾的日誌ui

com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.client.transaction.manager.FamilyPlanTransactionManager.test1(...)方法執行開始執行,數據源切換到:master 
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabelDetail 》》》 開始 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail(...)方法執行開始執行,沒有配置數據源,切換到默認:master 
org.mybatis.spring.SqlSessionUtils Creating a new SqlSession 
org.mybatis.spring.SqlSessionUtils Registering transaction synchronization for SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@67334835] 
org.mybatis.spring.transaction.SpringManagedTransaction JDBC Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@3d2fb2bf] will be managed by Spring 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ooo Using Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@3d2fb2bf] 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ==>  Preparing: INSERT INTO t_detail ( user_id, create_time ) VALUES ( ?, ? )  
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ==> Parameters: 1(Long), 2019-09-16 10:26:50.722(Timestamp) 
org.mybatis.spring.SqlSessionUtils Releasing transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@67334835] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail(...)方法執行完成,清理數據源 
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabelDetail 》》》 結束 

com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabel 》》》 開始 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch(...)方法執行開始執行,沒有配置數據源,切換到默認:master 
org.mybatis.spring.SqlSessionUtils Fetched SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@67334835] from current transaction 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ooo Using Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@3d2fb2bf] 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ==>  Preparing: INSERT INTO t_label ( user_id, label_name, type, status, create_time, update_time ) VALUES ( ?, ?, ?, ?, ?, ? )  
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ==> Parameters: 1(Long), test1591984(String), 1(Integer), 1(Integer), 2019-09-16 10:27:12.847(Timestamp), 2019-09-16 10:27:12.847(Timestamp) 
org.mybatis.spring.SqlSessionUtils Releasing transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@67334835] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch(...)方法執行完成,清理數據源 
org.mybatis.spring.SqlSessionUtils Transaction synchronization rolling back SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@67334835] 
org.mybatis.spring.SqlSessionUtils Transaction synchronization closing SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@67334835] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.client.transaction.manager.FamilyPlanTransactionManager.test1(...)方法執行完成,清理數據源 
com.moon.home.controller.AtestController 出現了異常 
java.lang.RuntimeException: 家庭計劃,初始化帳戶系統默認帳戶類型.出現異常
	at com.moon.client.transaction.manager.FamilyPlanTransactionManager.biz2(FamilyPlanTransactionManager.java:367) ~[CKclient-1.0.0-SNAPSHOT.jar:na]
	at com.moon.client.transaction.manager.FamilyPlanTransactionManager.test1(FamilyPlanTransactionManager.java:382) ~[CKclient-1.0.0-SNAPSHOT.jar:na]
	at com.moon.client.transaction.manager.FamilyPlanTransactionManager$$FastClassBySpringCGLIB$$728e76cf.invoke(<generated>) ~[CKclient-1.0.0-SNAPSHOT.jar:na]
	at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204) ~[spring-core-4.3.11.RELEASE.jar:4.3.11.RELEASE]
	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:738) ~[spring-aop-4.3.11.RELEASE.jar:4.3.11.RELEASE]

注意:.net

(1)org.mybatis.spring.transaction.SpringManagedTransaction JDBC Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@3d2fb2bf] will be managed by Spring 
(2)org.mybatis.spring.SqlSessionUtils Transaction synchronization rolling back SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@67334835] 3d

2.3 開啓事務總結日誌

(1)方法上加了@Transactional ,在進入方法的業務代碼前(本例就是進入 test1() 的業務代碼前)已經決定了使用哪一個數據源,在業務方法 biz1()或biz2()內切換數據源是無效的。

  (2) 加了@Transactional註解,若是在進入test1()方法前指定了數據源,test1() 沒有在切面中切換數據源,則以進入test1()方法前用的數據源爲準;若是沒有指定數據源,以系統配置的默認數據源。

(3)並非加了@Transactional 註解,在進入test1() 方法後就開啓事務,是有SQL執行時纔會開啓事務。

 

3 不開事務

3.1 不開事務,執行成功日誌

// 進入 biz1(...)方法
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabelDetail 》》》 開始 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail(...)方法執行開始執行,沒有配置數據源,切換到默認:master 
org.mybatis.spring.SqlSessionUtils Creating a new SqlSession 
org.mybatis.spring.SqlSessionUtils SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@57494412] was not registered for synchronization because synchronization is not active 
org.mybatis.spring.transaction.SpringManagedTransaction JDBC Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@320e24b0] will not be managed by Spring 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ooo Using Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@320e24b0] 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ==>  Preparing: INSERT INTO t_detail ( user_id, create_time ) VALUES ( ?, ? )  
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ==> Parameters: 1(Long), 2019-09-17 11:06:00.781(Timestamp) 
org.mybatis.spring.SqlSessionUtils Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@57494412] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail(...)方法執行完成,清理數據源 
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabelDetail 》》》 結束 

// 進入 biz2(...)方法
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabel 》》》 開始 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch(...)方法執行開始執行,沒有配置數據源,切換到默認:master 
org.mybatis.spring.SqlSessionUtils Creating a new SqlSession 
org.mybatis.spring.SqlSessionUtils SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@5471460] was not registered for synchronization because synchronization is not active 
org.mybatis.spring.transaction.SpringManagedTransaction JDBC Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@320e24b0] will not be managed by Spring 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ooo Using Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@320e24b0] 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ==>  Preparing: INSERT INTO t_label ( user_id, label_name, type, status, create_time, update_time ) VALUES ( ?, ?, ?, ?, ?, ? )  
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ==> Parameters: 1(Long), test1(String), 1(Integer), 1(Integer), 2019-09-17 11:06:01.056(Timestamp), 2019-09-17 11:06:01.056(Timestamp) 
org.mybatis.spring.SqlSessionUtils Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@5471460] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch(...)方法執行完成,清理數據源 
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabel 》》》 結束

3.2 不開事務,拋出異常日誌

// 進入 biz1(...)方法
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabelDetail 》》》 開始 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail(...)方法執行開始執行,沒有配置數據源,切換到默認:master 
org.mybatis.spring.SqlSessionUtils Creating a new SqlSession 
org.mybatis.spring.SqlSessionUtils SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@65ad141b] was not registered for synchronization because synchronization is not active 
org.mybatis.spring.transaction.SpringManagedTransaction JDBC Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@320e24b0] will not be managed by Spring 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ooo Using Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@320e24b0] 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ==>  Preparing: INSERT INTO t_detail ( user_id, create_time ) VALUES ( ?, ? )  
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail ==> Parameters: 1(Long), 2019-09-17 10:55:05.748(Timestamp) 
org.mybatis.spring.SqlSessionUtils Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@65ad141b] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelDetail(...)方法執行完成,清理數據源 
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabelDetail 》》》 結束 

// 進入 biz2(...)方法
com.moon.client.transaction.manager.FamilyPlanTransactionManager 》》》》》》》》插入 FamilyPlanLabel 》》》 開始 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch(...)方法執行開始執行,沒有配置數據源,切換到默認:master 
org.mybatis.spring.SqlSessionUtils Creating a new SqlSession 
org.mybatis.spring.SqlSessionUtils SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@4d1121df] was not registered for synchronization because synchronization is not active 
org.mybatis.spring.transaction.SpringManagedTransaction JDBC Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@320e24b0] will not be managed by Spring 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ooo Using Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@320e24b0] 
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ==>  Preparing: INSERT INTO t_label ( user_id, label_name, type, status, create_time, update_time ) VALUES ( ?, ?, ?, ?, ?, ? )  
com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch ==> Parameters: 1(Long), test1(String), 1(Integer), 1(Integer), 2019-09-17 10:55:06.6(Timestamp), 2019-09-17 10:55:06.6(Timestamp) 
org.mybatis.spring.SqlSessionUtils Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@4d1121df] 
com.moon.core.dbUtils.DataSourceAspect 【數據源處理】com.moon.core.dao.FamilyPlanDao.saveFamilyPlanLabelByBatch(...)方法執行完成,清理數據源 

// biz2裏的saveFamilyPlanLabelByBatch()方法拋出異常
com.moon.appserver.controller.privates.TestTranController  
java.lang.Exception: 手動拋異常
	at com.moon.client.transaction.manager.FamilyPlanTransactionManager.biz2(FamilyPlanTransactionManager.java:366) ~[CKclient-1.0.0-SNAPSHOT.jar:na]
	at com.moon.client.transaction.manager.FamilyPlanTransactionManager.test1(FamilyPlanTransactionManager.java:380) ~[CKclient-1.0.0-SNAPSHOT.jar:na]
	at com.moon.client.transaction.manager.FamilyPlanTransactionManager.test2(FamilyPlanTransactionManager.java:385) ~[CKclient-1.0.0-SNAPSHOT.jar:na]
	at com.moon.client.transaction.manager.FamilyPlanTransactionManager$$FastClassBySpringCGLIB$$728e76cf.invoke(<generated>) ~[CKclient-1.0.0-SNAPSHOT.jar:na]
	at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204) ~[spring-core-4.3.11.RELEASE.jar:4.3.11.RELEASE]
	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:738) ~[spring-aop-4.3.11.RELEASE.jar:4.3.11.RELEASE]
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) ~[spring-aop-4.3.11.RELEASE.jar:4.3.11.RELEASE]
	at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:92) ~[spring-aop-4.3.11.RELEASE.jar:4.3.11.RELEASE]
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) ~[spring-aop-4.3.11.RELEASE.jar:4.3.11.RELEASE]
	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:673) ~[spring-aop-4.3.11.RELEASE.jar:4.3.11.RELEASE]
	at com.moon.client.transaction.manager.FamilyPlanTransactionManager$$EnhancerBySpringCGLIB$$d931e707.test2(<generated>) ~[CKclient-1.0.0-SNAPSHOT.jar:na]
	at com.moon.appserver.controller.privates.TestTranController.test(TestTranController.java:29) ~[classes/:na]

注意:

(1)org.mybatis.spring.transaction.SpringManagedTransaction JDBC Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@320e24b0] will not be managed by Spring 

(2)org.mybatis.spring.SqlSessionUtils Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@65ad141b] 

相關文章
相關標籤/搜索