mybatis与spring事物处理日志

   o.s.web.servlet.DispatcherServlet - DispatcherServlet with name 'o2o' processing GET request for [/o2o/product_1.html]
o.s.w.s.m.a.DefaultAnnotationHandlerMapping - Matching patterns for request [/product_1.html] are [/product_{id}.*, /product_{id}]
o.s.w.s.m.a.DefaultAnnotationHandlerMapping - URI Template variables for request [/product_1.html] are {id=1}
o.s.w.s.m.a.DefaultAnnotationHandlerMapping - Mapping [/product_1.html] to HandlerExecutionChain with handler [com.lovebuy.o2o.controller.ProductController@bdbf8] and 2 interceptors
o.s.web.servlet.DispatcherServlet - Last-Modified value for [/o2o/product_1.html] is: -1
o.s.w.b.a.s.HandlerMethodInvoker - Invoking request handler method: public java.lang.String com.lovebuy.o2o.controller.ProductController.get(java.lang.Long,org.springframework.ui.ModelMap)
o.s.b.f.s.DefaultListableBeanFactory - Returning cached instance of singleton bean 'txManager'
//创建一个新事物
o.s.j.d.DataSourceTransactionManager - Creating new transaction with name [com.lovebuy.o2o.service.ProductService.getProduct]: PROPAGATION_REQUIRED,ISOLATION_DEFAULT; ''
//获得一个连接
o.s.j.d.DataSourceTransactionManager - Acquired Connection [jdbc:mysql://localhost:6/o2o?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull, UserName=root@localhost, MySQL-AB JDBC Driver] for JDBC transaction
//打开jdbc连接
o.s.j.d.DataSourceTransactionManager - Switching JDBC Connection [jdbc:mysql://localhost:6/o2o?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull, UserName=root@localhost, MySQL-AB JDBC Driver] to manual commit
//创建一个sqlsession
org.mybatis.spring.SqlSessionUtils - Creating a new SqlSession
//在session上注册事物
org.mybatis.spring.SqlSessionUtils - Registering transaction synchronization for SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@af]
o.m.s.t.SpringManagedTransaction - JDBC Connection [jdbc:mysql://localhost:6/o2o?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull, UserName=root@localhost, MySQL-AB JDBC Driver] will be managed by Spring
c.l.o.m.ProductMapper.insertProduct - ==> Preparing: insert into t_product(id, name, price) values (?, ?, ?)
c.l.o.m.ProductMapper.insertProduct - ==> Parameters: 0(Long), ???0(String), 0(Long)
c.l.o.m.ProductMapper.insertProduct - <== Updates: 1
//在sesssion上的事物先
org.mybatis.spring.SqlSessionUtils - Releasing transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@af]
//从当前事物中取session
org.mybatis.spring.SqlSessionUtils - Fetched SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@af] from current transaction
c.l.o.m.P.selectProductByID - ==> Preparing: select * from t_product where id = ?
c.l.o.m.P.selectProductByID - ==> Parameters: 1(Long)
c.l.o.m.P.selectProductByID - <== Total: 1
//Releasing transactional SqlSession ?????
org.mybatis.spring.SqlSessionUtils - Releasing transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@af]
//事物提交
org.mybatis.spring.SqlSessionUtils - Transaction synchronization committing SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@af]
//注销事物上的session
org.mybatis.spring.SqlSessionUtils - Transaction synchronization deregistering SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@af]
org.mybatis.spring.SqlSessionUtils - Transaction synchronization closing SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@af]
o.s.j.d.DataSourceTransactionManager - Initiating transaction commit
o.s.j.d.DataSourceTransactionManager - Committing JDBC transaction on Connection [jdbc:mysql://localhost:6/o2o?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull, UserName=root@localhost, MySQL-AB JDBC Driver]
o.s.j.d.DataSourceTransactionManager - Releasing JDBC Connection [jdbc:mysql://localhost:6/o2o?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull, UserName=root@localhost, MySQL-AB JDBC Driver] after transaction
o.s.jdbc.datasource.DataSourceUtils - Returning JDBC Connection to DataSource
o.s.b.f.s.DefaultListableBeanFactory - Invoking afterPropertiesSet() on bean with name '/product'
o.s.web.servlet.DispatcherServlet - Rendering view [org.springframework.web.servlet.view.JstlView: name '/product'; URL [/WEB-INF/jsp//product.jsp]] in DispatcherServlet with name 'o2o'
o.s.web.servlet.view.JstlView - Added model object 'product' of type [com.lovebuy.o2o.entity.Product] to request in view with name '/product'
o.s.web.servlet.view.JstlView - Added model object 'org.springframework.validation.BindingResult.product' of type [org.springframework.validation.BeanPropertyBindingResult] to request in view with name '/product'
o.s.web.servlet.view.JstlView - Forwarding to resource [/WEB-INF/jsp//product.jsp] in InternalResourceView '/product'
o.s.web.servlet.DispatcherServlet - Successfully completed request
o.s.b.f.s.DefaultListableBeanFactory - Returning cached instance of singleton bean 'sqlSessionFactory'
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值