记一次springboot配置事务@transactional失效的事故

问题:

有两张表,分别是user(用户信息表),user_role(用户角色信息表),添加一个用户的同时会在user_info表中插入该用户的用户角色信息记录。在添加一个用户信息时,由于用户信息重复,导致主键冲突,user表插入用户信息失败,此时按照正常逻辑,user_info表也会插入不成功,事务会回滚。但是结果是user_info中的记录插入成功了。

项目启动后的日志如下:

2018-08-08 17:17:41.496 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10008ms elapsed since last write check.
2018-08-08 17:17:41.496 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:41.655 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10010ms elapsed since last write check.
2018-08-08 17:17:41.655 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:41.710 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10003ms elapsed since last write check.
2018-08-08 17:17:41.710 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:41.710 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10003ms elapsed since last write check.
2018-08-08 17:17:41.710 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:41.710 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10003ms elapsed since last write check.
2018-08-08 17:17:41.710 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:41.710 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10003ms elapsed since last write check.
2018-08-08 17:17:41.710 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:51.497 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10001ms elapsed since last write check.
2018-08-08 17:17:51.498 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:51.664 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10009ms elapsed since last write check.
2018-08-08 17:17:51.664 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:51.726 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10016ms elapsed since last write check.
2018-08-08 17:17:51.726 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:51.726 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10016ms elapsed since last write check.
2018-08-08 17:17:51.726 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10016ms elapsed since last write check.
2018-08-08 17:17:51.726 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:51.726 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:51.726 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10016ms elapsed since last write check.
2018-08-08 17:17:51.726 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:17:52.591 DEBUG 7692 --- [8080-Acceptor-0] o.apache.tomcat.util.threads.LimitLatch  : Counting up[http-nio-8080-Acceptor-0] latch=1
2018-08-08 17:17:52.592 DEBUG 7692 --- [8080-Acceptor-0] o.apache.tomcat.util.threads.LimitLatch  : Counting up[http-nio-8080-Acceptor-0] latch=2
2018-08-08 17:17:52.595 DEBUG 7692 --- [nio-8080-exec-3] o.a.coyote.http11.Http11InputBuffer      : Received [GET /user/insertUser HTTP/1.1
Host: localhost:8080
Connection: keep-alive
Cache-Control: max-age=0
Upgrade-Insecure-Requests: 1
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8
Accept-Encoding: gzip, deflate, br
Accept-Language: zh-CN,zh;q=0.9

]
2018-08-08 17:17:52.597 DEBUG 7692 --- [nio-8080-exec-3] o.a.c.authenticator.AuthenticatorBase    : Security checking request GET /user/insertUser
2018-08-08 17:17:52.597 DEBUG 7692 --- [nio-8080-exec-3] org.apache.catalina.realm.RealmBase      :   No applicable constraints defined
2018-08-08 17:17:52.597 DEBUG 7692 --- [nio-8080-exec-3] o.a.c.authenticator.AuthenticatorBase    :  Not subject to any constraint
2018-08-08 17:17:52.598 DEBUG 7692 --- [nio-8080-exec-3] org.apache.tomcat.util.http.Parameters   : Set encoding to UTF-8
2018-08-08 17:17:52.598 DEBUG 7692 --- [nio-8080-exec-3] o.s.b.w.f.OrderedRequestContextFilter    : Bound request context to thread: [email protected]
2018-08-08 17:17:52.598 DEBUG 7692 --- [nio-8080-exec-3] o.s.web.servlet.DispatcherServlet        : DispatcherServlet with name ‘dispatcherServlet‘ processing GET request for [/user/insertUser]
2018-08-08 17:17:52.598 DEBUG 7692 --- [nio-8080-exec-3] s.w.s.m.m.a.RequestMappingHandlerMapping : Looking up handler method for path /user/insertUser
2018-08-08 17:17:52.598 DEBUG 7692 --- [nio-8080-exec-3] s.w.s.m.m.a.RequestMappingHandlerMapping : Returning handler method [public java.lang.String org.spring.web.controller.UserController.insertUser()]
2018-08-08 17:17:52.599 DEBUG 7692 --- [nio-8080-exec-3] o.s.b.f.s.DefaultListableBeanFactory     : Returning cached instance of singleton bean ‘userController‘
2018-08-08 17:17:52.599 DEBUG 7692 --- [nio-8080-exec-3] o.s.web.servlet.DispatcherServlet        : Last-Modified value for [/user/insertUser] is: -1
2018-08-08 17:17:52.599 DEBUG 7692 --- [nio-8080-exec-3] o.s.j.d.DataSourceTransactionManager     : Creating new transaction with name [org.spring.web.controller.UserController.insertUser]: PROPAGATION_REQUIRED,ISOLATION_DEFAULT; ‘‘
2018-08-08 17:17:52.601 DEBUG 7692 --- [nio-8080-exec-3] o.s.j.d.DataSourceTransactionManager     : Acquired Connection [ProxyConnection[PooledConnection[[email protected]]]] for JDBC transaction
2018-08-08 17:17:52.601 DEBUG 7692 --- [nio-8080-exec-3] o.s.j.d.DataSourceTransactionManager     : Switching JDBC Connection [ProxyConnection[PooledConnection[[email protected]]]] to manual commit
2018-08-08 17:17:52.601 DEBUG 7692 --- [nio-8080-exec-3] org.mybatis.spring.SqlSessionUtils       : Creating a new SqlSession
2018-08-08 17:17:52.601 DEBUG 7692 --- [nio-8080-exec-3] org.mybatis.spring.SqlSessionUtils       : Registering transaction synchronization for SqlSession [[email protected]]
2018-08-08 17:17:52.602 DEBUG 7692 --- [nio-8080-exec-3] o.m.s.t.SpringManagedTransaction         : JDBC Connection [ProxyConnection[PooledConnection[[email protected]]]] will be managed by Spring
2018-08-08 17:17:52.602 DEBUG 7692 --- [nio-8080-exec-3] o.s.w.m.UserRoleMapper.insertUserRole    : ==>  Preparing: insert into user_role ( user_id, role_id, descInfo ) values ( ?, ?, ? )
2018-08-08 17:17:52.602 DEBUG 7692 --- [nio-8080-exec-3] o.s.w.m.UserRoleMapper.insertUserRole    : ==> Parameters: 111(String), 999(String), uuuu(String)
2018-08-08 17:17:52.603 DEBUG 7692 --- [nio-8080-exec-3] o.s.w.m.UserRoleMapper.insertUserRole    : <==    Updates: 1
2018-08-08 17:17:52.603 DEBUG 7692 --- [nio-8080-exec-3] org.mybatis.spring.SqlSessionUtils       : Releasing transactional SqlSession [[email protected]]
2018-08-08 17:17:52.603 DEBUG 7692 --- [nio-8080-exec-3] org.mybatis.spring.SqlSessionUtils       : Fetched SqlSession [[email protected]] from current transaction
2018-08-08 17:17:52.604 DEBUG 7692 --- [nio-8080-exec-3] o.s.web.mapper.UserMapper.insertUser     : ==>  Preparing: insert into user ( id, age, user_name, password ) values ( ?, ?, ?, ? )
2018-08-08 17:17:52.604 DEBUG 7692 --- [nio-8080-exec-3] o.s.web.mapper.UserMapper.insertUser     : ==> Parameters: 11(Integer), 11(Integer), nihao(String), password(String)
2018-08-08 17:17:52.662 DEBUG 7692 --- [nio-8080-exec-3] o.s.web.mapper.UserMapper.insertUser     : <==    Updates: 1
2018-08-08 17:17:52.662 DEBUG 7692 --- [nio-8080-exec-3] org.mybatis.spring.SqlSessionUtils       : Releasing transactional SqlSession [[email protected]]
2018-08-08 17:17:52.662 DEBUG 7692 --- [nio-8080-exec-3] org.mybatis.spring.SqlSessionUtils       : Transaction synchronization deregistering SqlSession [[email protected]]
2018-08-08 17:17:52.662 DEBUG 7692 --- [nio-8080-exec-3] org.mybatis.spring.SqlSessionUtils       : Transaction synchronization closing SqlSession [[email protected]]
2018-08-08 17:17:52.662 DEBUG 7692 --- [nio-8080-exec-3] o.s.j.d.DataSourceTransactionManager     : Initiating transaction rollback
2018-08-08 17:17:52.663 DEBUG 7692 --- [nio-8080-exec-3] o.s.j.d.DataSourceTransactionManager     : Rolling back JDBC transaction on Connection [ProxyConnection[PooledConnection[[email protected]]]]
2018-08-08 17:17:52.702 DEBUG 7692 --- [nio-8080-exec-3] o.s.j.d.DataSourceTransactionManager     : Releasing JDBC Connection [ProxyConnection[PooledConnection[[email protected]]]] after transaction
2018-08-08 17:17:52.702 DEBUG 7692 --- [nio-8080-exec-3] o.s.jdbc.datasource.DataSourceUtils      : Returning JDBC Connection to DataSource
2018-08-08 17:17:52.702 DEBUG 7692 --- [nio-8080-exec-3] .m.m.a.ExceptionHandlerExceptionResolver : Resolving exception from handler [public java.lang.String org.spring.web.controller.UserController.insertUser()]: java.lang.RuntimeException: 抛异常
2018-08-08 17:17:52.702 DEBUG 7692 --- [nio-8080-exec-3] .w.s.m.a.ResponseStatusExceptionResolver : Resolving exception from handler [public java.lang.String org.spring.web.controller.UserController.insertUser()]: java.lang.RuntimeException: 抛异常
2018-08-08 17:17:52.702 DEBUG 7692 --- [nio-8080-exec-3] .w.s.m.s.DefaultHandlerExceptionResolver : Resolving exception from handler [public java.lang.String org.spring.web.controller.UserController.insertUser()]: java.lang.RuntimeException: 抛异常
2018-08-08 17:17:52.703 DEBUG 7692 --- [nio-8080-exec-3] o.s.web.servlet.DispatcherServlet        : Could not complete request

java.lang.RuntimeException: 抛异常
    at org.spring.web.controller.UserController.insertUser(UserController.java:81) ~[classes/:na]
    at org.spring.web.controller.UserController$$FastClassBySpringCGLIB$$8630d08.invoke(<generated>) ~[classes/:na]
    at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204) ~[spring-core-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:720) ~[spring-aop-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) ~[spring-aop-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99) ~[spring-tx-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281) ~[spring-tx-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96) ~[spring-tx-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) ~[spring-aop-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:655) ~[spring-aop-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.spring.web.controller.UserController$$EnhancerBySpringCGLIB$$c0911a9d.insertUser(<generated>) ~[classes/:na]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_121]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_121]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_121]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_121]
    at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:221) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:136) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:114) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:827) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:738) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:85) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:963) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:897) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:970) [spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:861) [spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:622) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:846) [spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) [tomcat-embed-websocket-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99) [spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.springframework.web.filter.HttpPutFormContentFilter.doFilterInternal(HttpPutFormContentFilter.java:89) [spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:77) [spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:197) [spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) [spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:108) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:349) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:784) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:802) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1410) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_121]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_121]
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at java.lang.Thread.run(Thread.java:745) [na:1.8.0_121]

2018-08-08 17:17:52.704 DEBUG 7692 --- [nio-8080-exec-3] o.s.b.w.f.OrderedRequestContextFilter    : Cleared thread-bound request context: [email protected]
2018-08-08 17:17:52.705 ERROR 7692 --- [nio-8080-exec-3] o.a.c.c.C.[.[.[/].[dispatcherServlet]    : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is java.lang.RuntimeException: 抛异常] with root cause

java.lang.RuntimeException: 抛异常
    at org.spring.web.controller.UserController.insertUser(UserController.java:81) ~[classes/:na]
    at org.spring.web.controller.UserController$$FastClassBySpringCGLIB$$8630d08.invoke(<generated>) ~[classes/:na]
    at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204) ~[spring-core-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:720) ~[spring-aop-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) ~[spring-aop-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99) ~[spring-tx-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281) ~[spring-tx-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96) ~[spring-tx-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) ~[spring-aop-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:655) ~[spring-aop-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.spring.web.controller.UserController$$EnhancerBySpringCGLIB$$c0911a9d.insertUser(<generated>) ~[classes/:na]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_121]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_121]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_121]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_121]
    at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:221) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:136) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:114) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:827) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:738) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:85) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:963) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:897) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:970) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:861) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:622) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:846) ~[spring-webmvc-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) ~[tomcat-embed-websocket-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.springframework.web.filter.HttpPutFormContentFilter.doFilterInternal(HttpPutFormContentFilter.java:89) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:77) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:197) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-4.3.3.RELEASE.jar:4.3.3.RELEASE]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198) ~[tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:108) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:349) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:784) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:802) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1410) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_121]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_121]
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-embed-core-8.5.5.jar:8.5.5]
    at java.lang.Thread.run(Thread.java:745) [na:1.8.0_121]

2018-08-08 17:17:52.706 DEBUG 7692 --- [nio-8080-exec-3] o.a.c.c.C.[Tomcat].[localhost]           : Processing ErrorPage[errorCode=0, location=/error]
2018-08-08 17:17:52.707 DEBUG 7692 --- [nio-8080-exec-3] o.s.web.servlet.DispatcherServlet        : DispatcherServlet with name ‘dispatcherServlet‘ processing GET request for [/error]
2018-08-08 17:17:52.707 DEBUG 7692 --- [nio-8080-exec-3] s.w.s.m.m.a.RequestMappingHandlerMapping : Looking up handler method for path /error
2018-08-08 17:17:52.707 DEBUG 7692 --- [nio-8080-exec-3] s.w.s.m.m.a.RequestMappingHandlerMapping : Returning handler method [public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)]
2018-08-08 17:17:52.708 DEBUG 7692 --- [nio-8080-exec-3] o.s.b.f.s.DefaultListableBeanFactory     : Returning cached instance of singleton bean ‘basicErrorController‘
2018-08-08 17:17:52.708 DEBUG 7692 --- [nio-8080-exec-3] o.s.web.servlet.DispatcherServlet        : Last-Modified value for [/error] is: -1
2018-08-08 17:17:52.708 DEBUG 7692 --- [nio-8080-exec-3] o.s.c.e.PropertySourcesPropertyResolver  : Found key ‘spring.template.provider.cache‘ in [refresh] with type [String]
2018-08-08 17:17:52.712 DEBUG 7692 --- [nio-8080-exec-3] o.s.c.e.PropertySourcesPropertyResolver  : Found key ‘spring.template.provider.cache‘ in [refresh] with type [String]
2018-08-08 17:17:52.715 DEBUG 7692 --- [nio-8080-exec-3] o.s.w.s.v.ContentNegotiatingViewResolver : Requested media types are [text/html, text/html;q=0.8] based on Accept header types and producible media types [text/html])
2018-08-08 17:17:52.715 DEBUG 7692 --- [nio-8080-exec-3] o.s.b.f.s.DefaultListableBeanFactory     : Returning cached instance of singleton bean ‘error‘
2018-08-08 17:17:52.715 DEBUG 7692 --- [nio-8080-exec-3] o.s.w.s.v.ContentNegotiatingViewResolver : Returning [org.springfram[email protected]2f2af303] based on requested media type ‘text/html‘
2018-08-08 17:17:52.715 DEBUG 7692 --- [nio-8080-exec-3] o.s.web.servlet.DispatcherServlet        : Rendering view [org.springfram[email protected]2f2af303] in DispatcherServlet with name ‘dispatcherServlet‘
2018-08-08 17:17:52.715 DEBUG 7692 --- [nio-8080-exec-3] o.s.web.servlet.DispatcherServlet        : Successfully completed request
2018-08-08 17:17:52.716 DEBUG 7692 --- [nio-8080-exec-3] o.a.c.c.C.[.[.[/].[dispatcherServlet]    :  Disabling the response for futher output
2018-08-08 17:17:52.719 DEBUG 7692 --- [nio-8080-exec-3] o.apache.coyote.http11.Http11Processor   : Socket: [[email protected]:[email protected]:java.nio.channels.SocketChannel[connected local=/0:0:0:0:0:0:0:1:8080 remote=/0:0:0:0:0:0:0:1:53329]], Status in: [OPEN_READ], State out: [CLOSED]
2018-08-08 17:17:52.719 DEBUG 7692 --- [nio-8080-exec-3] o.apache.tomcat.util.threads.LimitLatch  : Counting down[http-nio-8080-exec-3] latch=2
2018-08-08 17:18:01.307 DEBUG 7692 --- [ ReadCheckTimer] o.a.a.t.AbstractInactivityMonitor        : 30003ms elapsed since last read check.
2018-08-08 17:18:01.310 DEBUG 7692 --- [ ReadCheckTimer] o.a.a.t.AbstractInactivityMonitor        : 30002ms elapsed since last read check.
2018-08-08 17:18:01.310 DEBUG 7692 --- [ ReadCheckTimer] o.a.a.t.AbstractInactivityMonitor        : 30002ms elapsed since last read check.
2018-08-08 17:18:01.328 DEBUG 7692 --- [ ReadCheckTimer] o.a.a.t.AbstractInactivityMonitor        : 30001ms elapsed since last read check.
2018-08-08 17:18:01.328 DEBUG 7692 --- [ ReadCheckTimer] o.a.a.t.AbstractInactivityMonitor        : 30001ms elapsed since last read check.
2018-08-08 17:18:01.328 DEBUG 7692 --- [ ReadCheckTimer] o.a.a.t.AbstractInactivityMonitor        : 30001ms elapsed since last read check.
2018-08-08 17:18:01.503 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10006ms elapsed since last write check.
2018-08-08 17:18:01.503 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:18:01.675 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10011ms elapsed since last write check.
2018-08-08 17:18:01.676 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:18:01.742 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10016ms elapsed since last write check.
2018-08-08 17:18:01.742 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:18:01.742 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10016ms elapsed since last write check.
2018-08-08 17:18:01.742 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10016ms elapsed since last write check.
2018-08-08 17:18:01.742 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:18:01.742 DEBUG 7692 --- [WriteCheckTimer] o.a.a.t.AbstractInactivityMonitor        : WriteChecker: 10016ms elapsed since last write check.
2018-08-08 17:18:01.742 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]
2018-08-08 17:18:01.742 DEBUG 7692 --- [yMonitor Worker] o.a.a.t.AbstractInactivityMonitor        : Running WriteCheck[tcp://127.0.0.1:61616]

日志中可以看到是有事务回滚的。

解决方法:

创建user_info表的语句如下:

CREATE TABLE `user_role` (
  `user_id` varchar(20) NOT NULL,
  `role_id` varchar(20) NOT NULL,
  `descInfo` varchar(50) DEFAULT ‘描述信息‘,
  UNIQUE KEY `user_role` (`user_id`(10),`role_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8

由于mysql 中 myisam不支持事务,修改该表的engine为innodb

原文地址:https://www.cnblogs.com/li-zhan/p/9446370.html

时间: 2024-10-16 07:47:44

记一次springboot配置事务@transactional失效的事故的相关文章

SpringBoot整合Shiro 涉及跨域和@Cacheable缓存/@Transactional事务注解失效问题(五)

1. 跨域(多出现在前后端分离项目中) (1) 跨域介绍可参考:跨域(CORS) (2) SpringBoot中解决跨域方式有: A. 使用@CrossOrigin注解: B. 实现Filter类,重写doFilter方法 package com.ruhuanxingyun.config; import cn.hutool.core.util.StrUtil; import org.springframework.context.annotation.Configuration; import

[转]@Transactional spring 配置事务 注意事项

@Transactional spring 配置事务 注意事项 [@[email protected]] @Transactional spring 配置事务 注意事项 1. 在需要事务管理的地方加@Transactional 注解.@Transactional 注解可以被应用于接口定义和接口方法.类定义和类的 public 方法上. 2. @Transactional 注解只能应用到 public 可见度的方法上. 如果你在 protected.private 或者 package-visib

@Transactional spring 配置事务 注意事项

http://epine.itpub.net/post/8159/526281 @Transactional spring 配置事务 注意事项 1. 在需要事务管理的地方加@Transactional 注解.@Transactional 注解可以被应用于接口定义和接口方法.类定义和类的 public 方法上. 2. @Transactional 注解只能应用到 public 可见度的方法上. 如果你在 protected.private 或者 package-visible 的方法上使用 @Tr

@Transactional(事务讲解)和springboot 整合事务

概述 事务在编程中分为两种:声明式事务处理和编程式事务处理 编程式事务处理:编码方式实现事务管理,常与模版类TransactionTemplate(推荐使用) 在业务代码中实现事务. 可知编程式事务每次实现都要单独实现,但业务量大功能复杂时,使用编程式事务无疑是痛苦的,而声明式事务不同,声明式事务属于无侵入式,不会影响业务逻辑的实现. 声明式事务处理: 声明式事务实现方式主要有2种,一种为通过使用Spring的<tx:advice>定义事务通知与AOP相关配置实现,另为一种通过@Transac

spring,mybatis事务管理配置与@Transactional注解使用

spring,mybatis事务管理配置与@Transactional注解使用[转] 概述事务管理对于企业应用来说是至关重要的,即使出现异常情况,它也可以保证数据的一致性.Spring Framework对事务管理提供了一致的抽象,其特点如下: 为不同的事务API提供一致的编程模型,比如JTA(Java Transaction API), JDBC, Hibernate, JPA(Java Persistence API和JDO(Java Data Objects) 支持声明式事务管理,特别是基

spring,mybatis事务管理配置与@Transactional注解使用[转]

spring,mybatis事务管理配置与@Transactional注解使用[转] spring,mybatis事务管理配置与@Transactional注解使用 概述事务管理对于企业应用来说是至关重要的,即使出现异常情况,它也可以保证数据的一致性.Spring Framework对事务管理提供了一致的抽象,其特点如下: 为不同的事务API提供一致的编程模型,比如JTA(Java Transaction API), JDBC, Hibernate, JPA(Java Persistence A

事务管理配置与@Transactional注解使用

spring,mybatis事务管理配置与@Transactional注解使用 概述 事务管理对于企业应用来说是至关重要的,即使出现异常情况,它也可以保证数据的一致性. Spring Framework对事务管理提供了一致的抽象,其特点如下: 为不同的事务API提供一致的编程模型,比如JTA(Java Transaction API), JDBC, Hibernate, JPA(Java Persistence API和JDO(Java Data Objects) 支持声明式事务管理,特别是基于

[转]终于找到全annotation配置springMVC的方法了(事务不失效)

原文:http://icanfly.iteye.com/blog/778401 icanfly 写道 如果带上事务,那么用annotation方式的事务注解和bean配置,事务会失效,要将service bean配置到xml文件中才行 这个问题是由于问答上有解决方案 引用 这个问题很经典了 在主容器中(applicationContext.xml),将Controller的注解排除掉 <context:component-scan base-package="com"> &

项目记录:spring+springmvc 项目中 @Transactional 失效的解决方法

第一步,修改spring的配置文件和springmvc的配置文件 --------------------------------applicationContext.xml <context:annotation-config/>  <context:component-scan base-package="com.xxx"> <context:exclude-filter type="annotation" expression=&