ABOUT ME

-

Today
-
Yesterday
-
Total
-
  • HikariCP와 Slow Query로 인한 Commit 성공과 Rollback 실패
    글또 2024. 9. 19. 13:36

     

     

    0. 들어가며

     

    안녕하세요.
    이번 글에서는 회사에서 겪었던 DB 관련 이슈에 대해 이야기해보려 합니다.

    문제는 Spring Boot, HikariCP, MariaDB 환경에서 발생했으며, HikariCP와 Slow Query로 인해 트랜잭션 실패가 발생한 사례를 다룹니다.

    원인을 분석하고, 이에 대한 해결책을 함께 고민해보겠습니다.

    중간중간에 부가설명은 접은글(더보기)로 작성했습니다.

     

    1. 문제 상황
    2. 트랜잭션 사후 처리
    3. 대응
    4. 마무리

     

    1. 문제 상황

    저희 서비스는 MSA 구조로 되어있으며, 각 서비스는 동기와 비동기 통신으로 소통합니다. 

    이번 문제는 A 서비스와 B 서비스 간 동기 통신 중 발생했습니다.

     

    A 서비스는 B 서비스에 업데이트를 요청하고, B 서비스에서 성공적으로 업데이트가 반영되면 성공을 반환합니다.

    A 서비스는 B 서비스의 성공이 반환되면 상태를 변경하는 간단한 로직입니다.

     

    하지만 현장에서 보고된 문제는 다음과 같습니다:

    "B 서비스에서는 업데이트가 반영되었으나, A 서비스에서는 상태 변경이 반영되지 않았다."

     

     

     

    1-1. 의심한 초기 원인

     

    처음에는 B 서비스가 업데이트 후 A 서비스로 응답을 보내지 못했을 가능성을 의심했습니다.

    일반적인 장애 상황을 고려하면 다음과 같은 시나리오를 생각할 수 있습니다.

     

     

    네트워크 문제로 인해 A 서비스가 B 서비스의 응답을 받지 못했을 것이라고 추측했습니다.

    하지만 A 서비스의 로그를 확인해 보니, A 서비스는 응답을 제대로 받았고, 응답에 B 서비스의 에러 코드가 포함되어 있었습니다.

    다음으로 B 서비스의 로그를 확인해 보았습니다.

     

     

    1-2. Stack trace 

     

    더보기
    2024-09-04T13:18:18,507[org.springframework.jdbc.support.JdbcTransactionManager][/][XNIO-2 task-2]Initiating transaction commit
    2024-09-04T13:18:18,507[org.springframework.jdbc.support.JdbcTransactionManager][/][XNIO-2 task-2]Committing JDBC transaction on Connection [Transaction-aware proxy for target Connection [HikariProxyConnection@619714102 wrapping org.mariadb.jdbc.Connection@5e5bfda5]]
    2024-09-04T13:18:21,808[com.zaxxer.hikari.pool.ProxyLeakTask][/][sample-task-schedule-4]Connection leak detection triggered for org.mariadb.jdbc.Connection@5e5bfda5 on thread XNIO-2 task-2, stack trace follows
    java.lang.Exception: Apparent connection leak detected
    	at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:128) ~[HikariCP-5.0.1.jar:?]
    	at org.springframework.jdbc.datasource.LazyConnectionDataSourceProxy$LazyConnectionInvocationHandler.getTargetConnection(LazyConnectionDataSourceProxy.java:405) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.jdbc.datasource.LazyConnectionDataSourceProxy$LazyConnectionInvocationHandler.invoke(LazyConnectionDataSourceProxy.java:378) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.prepareStatement(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor140.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.TransactionAwareDataSourceProxy$TransactionAwareInvocationHandler.invoke(TransactionAwareDataSourceProxy.java:238) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.prepareStatement(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor140.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.apache.ibatis.logging.jdbc.ConnectionLogger.invoke(ConnectionLogger.java:53) ~[mybatis-3.5.14.jar:3.5.14]
    	at jdk.proxy3.$Proxy97.prepareStatement(Unknown Source) ~[?:?]
    	at org.apache.ibatis.executor.statement.PreparedStatementHandler.instantiateStatement(PreparedStatementHandler.java:88) ~[mybatis-3.5.14.jar:3.5.14]
    	at org.apache.ibatis.executor.statement.BaseStatementHandler.prepare(BaseStatementHandler.java:90) ~[mybatis-3.5.14.jar:3.5.14]
    	at org.apache.ibatis.executor.statement.RoutingStatementHandler.prepare(RoutingStatementHandler.java:60) ~[mybatis-3.5.14.jar:3.5.14]
    	at org.apache.ibatis.executor.ReuseExecutor.prepareStatement(ReuseExecutor.java:92) ~[mybatis-3.5.14.jar:3.5.14]
    	at org.apache.ibatis.executor.ReuseExecutor.doUpdate(ReuseExecutor.java:51) ~[mybatis-3.5.14.jar:3.5.14]
    	at org.apache.ibatis.executor.BaseExecutor.update(BaseExecutor.java:117) ~[mybatis-3.5.14.jar:3.5.14]
    	at org.apache.ibatis.executor.CachingExecutor.update(CachingExecutor.java:76) ~[mybatis-3.5.14.jar:3.5.14]
    	at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:197) ~[mybatis-3.5.14.jar:3.5.14]
    	at jdk.internal.reflect.GeneratedMethodAccessor271.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:425) ~[mybatis-spring-3.0.3.jar:3.0.3]
    	at jdk.proxy2.$Proxy101.update(Unknown Source) ~[?:?]
    	at org.mybatis.spring.SqlSessionTemplate.update(SqlSessionTemplate.java:288) ~[mybatis-spring-3.0.3.jar:3.0.3]
    	at org.apache.ibatis.binding.MapperMethod.execute(MapperMethod.java:67) ~[mybatis-3.5.14.jar:3.5.14]
    	at org.apache.ibatis.binding.MapperProxy$PlainMethodInvoker.invoke(MapperProxy.java:141) ~[mybatis-3.5.14.jar:3.5.14]
    	at org.apache.ibatis.binding.MapperProxy.invoke(MapperProxy.java:86) ~[mybatis-3.5.14.jar:3.5.14]
    	at jdk.proxy2.$Proxy152.updateSample(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor4953.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:196) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.dao.support.PersistenceExceptionTranslationInterceptor.invoke(PersistenceExceptionTranslationInterceptor.java:137) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:244) ~[spring-aop-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy153.updateSample(Unknown Source) ~[?:?]
    	at sample.SampleService.updateSample(SampleService.kt:700) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor15645.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:196) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:123) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:391) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleService$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at sample.SampleService.updateSample(SampleService.kt:26) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor15644.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:196) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:123) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:391) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleService$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at sample.SampleApiController.updateSample(SampleApiController.kt:667) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor8737.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:196) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.security.authorization.method.AuthorizationManagerBeforeMethodInterceptor.invoke(AuthorizationManagerBeforeMethodInterceptor.java:199) ~[spring-security-core-6.1.2.jar:6.1.2]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleApiController$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor8737.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:205) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:150) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:118) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:884) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:797) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1081) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:974) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1011) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:888) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:614) ~[jakarta.servlet-api-6.0.0.jar:6.0.0]
    	at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:74) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:129) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.security.web.FilterChainProxy.lambda$doFilterInternal$3(FilterChainProxy.java:231) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:365) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.intercept.AuthorizationFilter.doFilter(AuthorizationFilter.java:100) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:126) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:120) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:100) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:179) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:107) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:93) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.header.HeaderWriterFilter.doHeadersAfter(HeaderWriterFilter.java:90) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:75) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:82) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:69) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:62) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.session.DisableEncodeUrlFilter.doFilterInternal(DisableEncodeUrlFilter.java:42) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:233) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:191) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:91) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:84) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletChain$1.handleRequest(ServletChain.java:68) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.RedirectDirHandler.handleRequest(RedirectDirHandler.java:68) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:117) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) ~[undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46) ~[undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:60) ~[undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:77) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43) ~[undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) ~[undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.SendErrorPageHandler.handleRequest(SendErrorPageHandler.java:52) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) ~[undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:276) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:135) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:132) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:48) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:256) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:101) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:393) ~[undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:859) ~[undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18) ~[jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2513) ~[jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1538) ~[jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.xnio.XnioWorker$WorkerThreadFactory$1$1.run(XnioWorker.java:1282) ~[xnio-api-3.8.8.Final.jar:3.8.8.Final]
    	at java.lang.Thread.run(Thread.java:840) [?:?]
    2024-09-04T13:18:28,516[com.zaxxer.hikari.pool.ProxyConnection][/][XNIO-2 task-2]sampleDataSource - Connection org.mariadb.jdbc.Connection@5e5bfda5 marked as broken because of SQLSTATE(08000), ErrorCode(-1)
    java.net.SocketTimeoutException: Read timed out
    	at sun.nio.ch.NioSocketImpl.timedRead(NioSocketImpl.java:288) ~[?:?]
    	at sun.nio.ch.NioSocketImpl.implRead(NioSocketImpl.java:314) ~[?:?]
    	at sun.nio.ch.NioSocketImpl.read(NioSocketImpl.java:355) ~[?:?]
    	at sun.nio.ch.NioSocketImpl$1.read(NioSocketImpl.java:808) ~[?:?]
    	at java.net.Socket$SocketInputStream.read(Socket.java:966) ~[?:?]
    	at java.io.BufferedInputStream.fill(BufferedInputStream.java:244) ~[?:?]
    	at java.io.BufferedInputStream.read1(BufferedInputStream.java:284) ~[?:?]
    	at java.io.BufferedInputStream.read(BufferedInputStream.java:343) ~[?:?]
    	at org.mariadb.jdbc.client.socket.impl.PacketReader.readReusablePacket(PacketReader.java:66) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.message.ClientMessage.readPacket(ClientMessage.java:115) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readPacket(StandardClient.java:872) ~[mariadb-java-client-3.1.4.jar:?]
    	... 138 more
    Wrapped by: java.sql.SQLNonTransientConnectionException: (conn=40758862) Socket error
    	at org.mariadb.jdbc.export.ExceptionFactory.createException(ExceptionFactory.java:293) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.export.ExceptionFactory.create(ExceptionFactory.java:359) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readPacket(StandardClient.java:895) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readResults(StandardClient.java:811) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readResponse(StandardClient.java:730) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.execute(StandardClient.java:654) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.execute(StandardClient.java:511) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.Connection.commit(Connection.java:209) ~[mariadb-java-client-3.1.4.jar:?]
    	at com.zaxxer.hikari.pool.ProxyConnection.commit(ProxyConnection.java:377) ~[HikariCP-5.0.1.jar:?]
    	at com.zaxxer.hikari.pool.HikariProxyConnection.commit(HikariProxyConnection.java) ~[HikariCP-5.0.1.jar:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.LazyConnectionDataSourceProxy$LazyConnectionInvocationHandler.invoke(LazyConnectionDataSourceProxy.java:378) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.commit(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.TransactionAwareDataSourceProxy$TransactionAwareInvocationHandler.invoke(TransactionAwareDataSourceProxy.java:238) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.commit(Unknown Source) ~[?:?]
    	at org.springframework.jdbc.datasource.DataSourceTransactionManager.doCommit(DataSourceTransactionManager.java:337) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:743) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:711) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionAspectSupport.commitTransactionAfterReturning(TransactionAspectSupport.java:660) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:410) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleService$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at sample.SampleApiController.updateSample(SampleApiController.kt:667).kt:667) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor8737.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:196) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.security.authorization.method.AuthorizationManagerBeforeMethodInterceptor.invoke(AuthorizationManagerBeforeMethodInterceptor.java:199) ~[spring-security-core-6.1.2.jar:6.1.2]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleApiController$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor8737.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:205) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:150) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:118) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:884) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:797) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1081) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:974) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1011) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:888) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:614) ~[jakarta.servlet-api-6.0.0.jar:6.0.0]
    	at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:74) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:129) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.security.web.FilterChainProxy.lambda$doFilterInternal$3(FilterChainProxy.java:231) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:365) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.intercept.AuthorizationFilter.doFilter(AuthorizationFilter.java:100) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:126) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:120) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:100) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:179) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:107) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:93) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.header.HeaderWriterFilter.doHeadersAfter(HeaderWriterFilter.java:90) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:75) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:82) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:69) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:62) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.session.DisableEncodeUrlFilter.doFilterInternal(DisableEncodeUrlFilter.java:42) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:233) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:191) [spring-security-web-6.1.2.jar:6.1.2]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:91) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:84) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletChain$1.handleRequest(ServletChain.java:68) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.RedirectDirHandler.handleRequest(RedirectDirHandler.java:68) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:117) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:60) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:77) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.SendErrorPageHandler.handleRequest(SendErrorPageHandler.java:52) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:276) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:135) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:132) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:48) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:256) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:101) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:393) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:859) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2513) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1538) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.xnio.XnioWorker$WorkerThreadFactory$1$1.run(XnioWorker.java:1282) [xnio-api-3.8.8.Final.jar:3.8.8.Final]
    	at java.lang.Thread.run(Thread.java:840) [?:?]
    2024-09-04T13:18:28,518[com.zaxxer.hikari.pool.ProxyLeakTask][/][XNIO-2 task-2]Previously reported leaked connection org.mariadb.jdbc.Connection@5e5bfda5 on thread XNIO-2 task-2 was returned to the pool (unleaked)
    2024-09-04T13:18:28,519[org.springframework.jdbc.support.JdbcTransactionManager][/][XNIO-2 task-2]Initiating transaction rollback after commit exception
    java.net.SocketTimeoutException: Read timed out
    	at sun.nio.ch.NioSocketImpl.timedRead(NioSocketImpl.java:288) ~[?:?]
    	at sun.nio.ch.NioSocketImpl.implRead(NioSocketImpl.java:314) ~[?:?]
    	at sun.nio.ch.NioSocketImpl.read(NioSocketImpl.java:355) ~[?:?]
    	at sun.nio.ch.NioSocketImpl$1.read(NioSocketImpl.java:808) ~[?:?]
    	at java.net.Socket$SocketInputStream.read(Socket.java:966) ~[?:?]
    	at java.io.BufferedInputStream.fill(BufferedInputStream.java:244) ~[?:?]
    	at java.io.BufferedInputStream.read1(BufferedInputStream.java:284) ~[?:?]
    	at java.io.BufferedInputStream.read(BufferedInputStream.java:343) ~[?:?]
    	at org.mariadb.jdbc.client.socket.impl.PacketReader.readReusablePacket(PacketReader.java:66) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.message.ClientMessage.readPacket(ClientMessage.java:115) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readPacket(StandardClient.java:872) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readResults(StandardClient.java:811) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readResponse(StandardClient.java:730) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.execute(StandardClient.java:654) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.execute(StandardClient.java:511) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.Connection.commit(Connection.java:209) ~[mariadb-java-client-3.1.4.jar:?]
    	at com.zaxxer.hikari.pool.ProxyConnection.commit(ProxyConnection.java:377) ~[HikariCP-5.0.1.jar:?]
    	at com.zaxxer.hikari.pool.HikariProxyConnection.commit(HikariProxyConnection.java) ~[HikariCP-5.0.1.jar:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.LazyConnectionDataSourceProxy$LazyConnectionInvocationHandler.invoke(LazyConnectionDataSourceProxy.java:378) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.commit(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.TransactionAwareDataSourceProxy$TransactionAwareInvocationHandler.invoke(TransactionAwareDataSourceProxy.java:238) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.commit(Unknown Source) ~[?:?]
    	at org.springframework.jdbc.datasource.DataSourceTransactionManager.doCommit(DataSourceTransactionManager.java:337) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	... 120 more
    Wrapped by: java.sql.SQLNonTransientConnectionException: (conn=40758862) Socket error
    	at org.mariadb.jdbc.export.ExceptionFactory.createException(ExceptionFactory.java:293) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.export.ExceptionFactory.create(ExceptionFactory.java:359) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readPacket(StandardClient.java:895) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readResults(StandardClient.java:811) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readResponse(StandardClient.java:730) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.execute(StandardClient.java:654) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.execute(StandardClient.java:511) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.Connection.commit(Connection.java:209) ~[mariadb-java-client-3.1.4.jar:?]
    	at com.zaxxer.hikari.pool.ProxyConnection.commit(ProxyConnection.java:377) ~[HikariCP-5.0.1.jar:?]
    	at com.zaxxer.hikari.pool.HikariProxyConnection.commit(HikariProxyConnection.java) ~[HikariCP-5.0.1.jar:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.LazyConnectionDataSourceProxy$LazyConnectionInvocationHandler.invoke(LazyConnectionDataSourceProxy.java:378) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.commit(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.TransactionAwareDataSourceProxy$TransactionAwareInvocationHandler.invoke(TransactionAwareDataSourceProxy.java:238) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.commit(Unknown Source) ~[?:?]
    	at org.springframework.jdbc.datasource.DataSourceTransactionManager.doCommit(DataSourceTransactionManager.java:337) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	... 120 more
    Wrapped by: org.springframework.dao.DataAccessResourceFailureException: JDBC commit; (conn=40758862) Socket error
    	at org.springframework.jdbc.support.SQLExceptionSubclassTranslator.doTranslate(SQLExceptionSubclassTranslator.java:86) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:70) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.jdbc.support.JdbcTransactionManager.translateException(JdbcTransactionManager.java:178) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.jdbc.datasource.DataSourceTransactionManager.doCommit(DataSourceTransactionManager.java:340) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:743) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:711) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionAspectSupport.commitTransactionAfterReturning(TransactionAspectSupport.java:660) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:410) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleService$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at sample.SampleApiController.updateSample(SampleApiController.kt:667) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor8737.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:196) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.security.authorization.method.AuthorizationManagerBeforeMethodInterceptor.invoke(AuthorizationManagerBeforeMethodInterceptor.java:199) ~[spring-security-core-6.1.2.jar:6.1.2]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleApiController$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor8737.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:205) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:150) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:118) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:884) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:797) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1081) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:974) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1011) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:888) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:614) ~[jakarta.servlet-api-6.0.0.jar:6.0.0]
    	at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:74) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:129) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.security.web.FilterChainProxy.lambda$doFilterInternal$3(FilterChainProxy.java:231) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:365) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.intercept.AuthorizationFilter.doFilter(AuthorizationFilter.java:100) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:126) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:120) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:100) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:179) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:107) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:93) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.header.HeaderWriterFilter.doHeadersAfter(HeaderWriterFilter.java:90) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:75) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:82) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:69) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:62) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.session.DisableEncodeUrlFilter.doFilterInternal(DisableEncodeUrlFilter.java:42) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:233) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:191) [spring-security-web-6.1.2.jar:6.1.2]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:91) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:84) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletChain$1.handleRequest(ServletChain.java:68) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.RedirectDirHandler.handleRequest(RedirectDirHandler.java:68) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:117) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:60) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:77) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.SendErrorPageHandler.handleRequest(SendErrorPageHandler.java:52) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:276) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:135) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:132) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:48) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:256) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:101) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:393) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:859) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2513) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1538) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.xnio.XnioWorker$WorkerThreadFactory$1$1.run(XnioWorker.java:1282) [xnio-api-3.8.8.Final.jar:3.8.8.Final]
    	at java.lang.Thread.run(Thread.java:840) [?:?]
    2024-09-04T13:18:28,522[org.springframework.jdbc.support.JdbcTransactionManager][/][XNIO-2 task-2]Rolling back JDBC transaction on Connection [Transaction-aware proxy for target Connection [HikariProxyConnection@619714102 wrapping com.zaxxer.hikari.pool.ProxyConnection.ClosedConnection]]
    2024-09-04T13:18:28,523[org.springframework.jdbc.support.JdbcTransactionManager][/][XNIO-2 task-2]Commit exception overridden by rollback exception
    java.net.SocketTimeoutException: Read timed out
    	at sun.nio.ch.NioSocketImpl.timedRead(NioSocketImpl.java:288) ~[?:?]
    	at sun.nio.ch.NioSocketImpl.implRead(NioSocketImpl.java:314) ~[?:?]
    	at sun.nio.ch.NioSocketImpl.read(NioSocketImpl.java:355) ~[?:?]
    	at sun.nio.ch.NioSocketImpl$1.read(NioSocketImpl.java:808) ~[?:?]
    	at java.net.Socket$SocketInputStream.read(Socket.java:966) ~[?:?]
    	at java.io.BufferedInputStream.fill(BufferedInputStream.java:244) ~[?:?]
    	at java.io.BufferedInputStream.read1(BufferedInputStream.java:284) ~[?:?]
    	at java.io.BufferedInputStream.read(BufferedInputStream.java:343) ~[?:?]
    	at org.mariadb.jdbc.client.socket.impl.PacketReader.readReusablePacket(PacketReader.java:66) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.message.ClientMessage.readPacket(ClientMessage.java:115) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readPacket(StandardClient.java:872) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readResults(StandardClient.java:811) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readResponse(StandardClient.java:730) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.execute(StandardClient.java:654) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.execute(StandardClient.java:511) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.Connection.commit(Connection.java:209) ~[mariadb-java-client-3.1.4.jar:?]
    	at com.zaxxer.hikari.pool.ProxyConnection.commit(ProxyConnection.java:377) ~[HikariCP-5.0.1.jar:?]
    	at com.zaxxer.hikari.pool.HikariProxyConnection.commit(HikariProxyConnection.java) ~[HikariCP-5.0.1.jar:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.LazyConnectionDataSourceProxy$LazyConnectionInvocationHandler.invoke(LazyConnectionDataSourceProxy.java:378) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.commit(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.TransactionAwareDataSourceProxy$TransactionAwareInvocationHandler.invoke(TransactionAwareDataSourceProxy.java:238) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.commit(Unknown Source) ~[?:?]
    	at org.springframework.jdbc.datasource.DataSourceTransactionManager.doCommit(DataSourceTransactionManager.java:337) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	... 120 more
    Wrapped by: java.sql.SQLNonTransientConnectionException: (conn=40758862) Socket error
    	at org.mariadb.jdbc.export.ExceptionFactory.createException(ExceptionFactory.java:293) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.export.ExceptionFactory.create(ExceptionFactory.java:359) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readPacket(StandardClient.java:895) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readResults(StandardClient.java:811) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.readResponse(StandardClient.java:730) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.execute(StandardClient.java:654) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.client.impl.StandardClient.execute(StandardClient.java:511) ~[mariadb-java-client-3.1.4.jar:?]
    	at org.mariadb.jdbc.Connection.commit(Connection.java:209) ~[mariadb-java-client-3.1.4.jar:?]
    	at com.zaxxer.hikari.pool.ProxyConnection.commit(ProxyConnection.java:377) ~[HikariCP-5.0.1.jar:?]
    	at com.zaxxer.hikari.pool.HikariProxyConnection.commit(HikariProxyConnection.java) ~[HikariCP-5.0.1.jar:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.LazyConnectionDataSourceProxy$LazyConnectionInvocationHandler.invoke(LazyConnectionDataSourceProxy.java:378) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.commit(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor146.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.TransactionAwareDataSourceProxy$TransactionAwareInvocationHandler.invoke(TransactionAwareDataSourceProxy.java:238) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.commit(Unknown Source) ~[?:?]
    	at org.springframework.jdbc.datasource.DataSourceTransactionManager.doCommit(DataSourceTransactionManager.java:337) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	... 120 more
    Wrapped by: org.springframework.dao.DataAccessResourceFailureException: JDBC commit; (conn=40758862) Socket error
    	at org.springframework.jdbc.support.SQLExceptionSubclassTranslator.doTranslate(SQLExceptionSubclassTranslator.java:86) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:70) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.jdbc.support.JdbcTransactionManager.translateException(JdbcTransactionManager.java:178) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.jdbc.datasource.DataSourceTransactionManager.doCommit(DataSourceTransactionManager.java:340) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:743) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:711) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionAspectSupport.commitTransactionAfterReturning(TransactionAspectSupport.java:660) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:410) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleService$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at sample.SampleApiController.updateSample(SampleApiController.kt:667) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor8737.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:196) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.security.authorization.method.AuthorizationManagerBeforeMethodInterceptor.invoke(AuthorizationManagerBeforeMethodInterceptor.java:199) ~[spring-security-core-6.1.2.jar:6.1.2]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleApiController$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor8737.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:205) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:150) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:118) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:884) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:797) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1081) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:974) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1011) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:888) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:614) ~[jakarta.servlet-api-6.0.0.jar:6.0.0]
    	at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:74) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:129) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.security.web.FilterChainProxy.lambda$doFilterInternal$3(FilterChainProxy.java:231) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:365) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.intercept.AuthorizationFilter.doFilter(AuthorizationFilter.java:100) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:126) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:120) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:100) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:179) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:107) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:93) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.header.HeaderWriterFilter.doHeadersAfter(HeaderWriterFilter.java:90) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:75) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:82) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:69) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:62) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.session.DisableEncodeUrlFilter.doFilterInternal(DisableEncodeUrlFilter.java:42) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:233) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:191) [spring-security-web-6.1.2.jar:6.1.2]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:91) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:84) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletChain$1.handleRequest(ServletChain.java:68) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.RedirectDirHandler.handleRequest(RedirectDirHandler.java:68) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:117) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:60) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:77) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.SendErrorPageHandler.handleRequest(SendErrorPageHandler.java:52) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:276) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:135) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:132) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:48) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:256) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:101) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:393) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:859) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2513) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1538) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.xnio.XnioWorker$WorkerThreadFactory$1$1.run(XnioWorker.java:1282) [xnio-api-3.8.8.Final.jar:3.8.8.Final]
    	at java.lang.Thread.run(Thread.java:840) [?:?]
    2024-09-04T13:18:28,525[org.springframework.jdbc.support.JdbcTransactionManager][/][XNIO-2 task-2]Could not reset JDBC Connection after transaction
    java.sql.SQLException: Connection is closed
    	at com.zaxxer.hikari.pool.ProxyConnection$ClosedConnection.lambda$getClosedConnection$0(ProxyConnection.java:502) ~[HikariCP-5.0.1.jar:?]
    	at jdk.proxy3.$Proxy97.setAutoCommit(Unknown Source) ~[?:?]
    	at com.zaxxer.hikari.pool.ProxyConnection.setAutoCommit(ProxyConnection.java:401) ~[HikariCP-5.0.1.jar:?]
    	at com.zaxxer.hikari.pool.HikariProxyConnection.setAutoCommit(HikariProxyConnection.java) ~[HikariCP-5.0.1.jar:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor139.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.LazyConnectionDataSourceProxy$LazyConnectionInvocationHandler.invoke(LazyConnectionDataSourceProxy.java:378) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.setAutoCommit(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.GeneratedMethodAccessor139.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.jdbc.datasource.TransactionAwareDataSourceProxy$TransactionAwareInvocationHandler.invoke(TransactionAwareDataSourceProxy.java:238) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at jdk.proxy2.$Proxy211.setAutoCommit(Unknown Source) ~[?:?]
    	at org.springframework.jdbc.datasource.DataSourceTransactionManager.doCleanupAfterCompletion(DataSourceTransactionManager.java:382) ~[spring-jdbc-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.support.AbstractPlatformTransactionManager.cleanupAfterCompletion(AbstractPlatformTransactionManager.java:992) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:790) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:711) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionAspectSupport.commitTransactionAfterReturning(TransactionAspectSupport.java:660) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:410) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:119) ~[spring-tx-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleService$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at sample.SampleApiController.updateSample(SampleApiController.kt:667) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor8737.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:196) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.security.authorization.method.AuthorizationManagerBeforeMethodInterceptor.invoke(AuthorizationManagerBeforeMethodInterceptor.java:199) ~[spring-security-core-6.1.2.jar:6.1.2]
    	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:184) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:756) ~[spring-aop-6.0.11.jar:6.0.11]
    	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:708) ~[spring-aop-6.0.11.jar:6.0.11]
    	at sample.SampleApiController$$SpringCGLIB$$0.updateSample(<generated>) ~[sample-1.0.0-SNAPSHOT-plain.jar:1.0.0-SNAPSHOT]
    	at jdk.internal.reflect.GeneratedMethodAccessor8737.invoke(Unknown Source) ~[?:?]
    	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
    	at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
    	at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:205) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:150) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:118) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:884) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:797) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1081) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:974) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1011) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:888) ~[spring-webmvc-6.0.11.jar:6.0.11]
    	at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:614) ~[jakarta.servlet-api-6.0.0.jar:6.0.0]
    	at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:74) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:129) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93) ~[spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) ~[spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) ~[undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.security.web.FilterChainProxy.lambda$doFilterInternal$3(FilterChainProxy.java:231) ~[spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:365) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.intercept.AuthorizationFilter.doFilter(AuthorizationFilter.java:100) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:126) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:120) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:100) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:179) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:107) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:93) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.header.HeaderWriterFilter.doHeadersAfter(HeaderWriterFilter.java:90) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:75) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:82) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.SecurityContextHolderFilter.doFilter(SecurityContextHolderFilter.java:69) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:62) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.session.DisableEncodeUrlFilter.doFilterInternal(DisableEncodeUrlFilter.java:42) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:374) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:233) [spring-security-web-6.1.2.jar:6.1.2]
    	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:191) [spring-security-web-6.1.2.jar:6.1.2]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:91) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) [spring-web-6.0.11.jar:6.0.11]
    	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:116) [spring-web-6.0.11.jar:6.0.11]
    	at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:67) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:84) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletChain$1.handleRequest(ServletChain.java:68) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.RedirectDirHandler.handleRequest(RedirectDirHandler.java:68) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:117) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:60) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:77) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.SendErrorPageHandler.handleRequest(SendErrorPageHandler.java:52) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:276) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:135) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:132) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:48) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:256) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:101) [undertow-servlet-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:393) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:859) [undertow-core-2.3.7.Final.jar:2.3.7.Final]
    	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2513) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1538) [jboss-threads-3.5.0.Final.jar:3.5.0.Final]
    	at org.xnio.XnioWorker$WorkerThreadFactory$1$1.run(XnioWorker.java:1282) [xnio-api-3.8.8.Final.jar:3.8.8.Final]
    	at java.lang.Thread.run(Thread.java:840) [?:?]
    2024-09-04T13:18:28,526[org.springframework.jdbc.support.JdbcTransactionManager][/][XNIO-2 task-2]Releasing JDBC Connection [Transaction-aware proxy for target Connection [HikariProxyConnection@619714102 wrapping com.zaxxer.hikari.pool.ProxyConnection.ClosedConnection]] after transaction

     

     

    • 쿼리 시작:
      • 2024-09-04 13:18:16,807: SampleRepository.updateSample() 메서드에서 발행한 쿼리가 끝남.
    • 커밋 시도:
      • 2024-09-04T13:18:18,507: JdbcTransactionManager.commit() 호출로 트랜잭션 커밋이 시작됨.
    • HikariCP 경고:
      • 그러나 2024-09-04T13:18:21,808까지 커넥션이 반환되지 않음. 이는 hikari.leak-detection-threshold가 5000ms(5초)로 설정되어 있기 때문에 감지됨. HikariCP는 이 시점에서 커넥션 누수를 감지하고 경고를 로그로 남김.
      • HikariCP의 누수 감지 스케줄링이 누수를 감지할 경우 ProxyLeakTask를 통해 stackTrace를 찍음.
      • 하지만 이 경고는 단순히 로그를 기록하는 역할을 하며, 실제 커밋 작업에는 영향을 미치지 않음. HikariCP는 예외를 던지지 않고 작업을 중단시키지도 않음.
    • ProxyConnection 반환 및 커밋 후 에러 발생:
      • 2024-09-04T13:18:28,516: ProxyConnection.commit() , Socket에 SqlExcute호출 후, 소켓 타임아웃 발생. 이때 Socket error 로그가 찍히고 destroySocket() 메소드가 호출되어 소켓이 닫힘.
      • 어플리케이션의 socketTimeout=10000(ms)이므로 2024-09-04 13:18:16,807에 커밋 실행 뒤 10초 뒤에 타임아웃이 발생.
      • Socket의 IOException는 SQLException으로 wrapping됨
      • HikariProxyConnection이 이 에러를 캐치하고, SQLSTATE(08000)와 ErrorCode(-1) 로그를 남김.
      • 그 후, 커넥션이 ClosedConnection 상태로 변경됨. 즉, 이 시점부터 커넥션이 더 이상 유효하지 않음.
    • 롤백 시도 및 로그 출력:
      • 2024-09-04T13:18:28,519: 소켓 타임아웃 이후, 트랜잭션이 롤백되기 시작함. 이 과정에서 Throwable을 다시 한 번 debug 모드에서 찍기 때문에 이전 로그가 중복 출력됨.
    • 롤백 실패:
      • 2024-09-04T13:18:28,522: DataSourceTransactionManager가 doRollback() 호출 직전 로그를 출력하며, 이 시점에서 커넥션은 이미 ClosedConnection 상태임.
      • 2024-09-04T13:18:28,523: 롤백이 시도되지만, ClosedConnection 상태이므로 롤백 도중 예외가 발생함. ClosedConnection은 생성될 때 예외를 던지며, 롤백이 실패하게 됨.
    • 롤백 예외 처리:
      • AbstractPlatformTransactionManager가 롤백 실패 시 발생한 Throwable을 다시 debug 로그로 찍고 나서, doRollback()에서 발생한 예외를 던짐.
      • 이 예외는 별도의 catch 블록이 없어서 상위로 전파됨.
      •   AbstractPlatformTransactionManager는 finally 블록을 실행함.
    • 마무리 처리 및 추가 예외 발생:
      • cleanupAfterCompletion() 메소드가 호출되며, 여기서 이미 닫힌 커넥션을 참조하여 또 다른 예외가 발생함. 이때 발생한 예외 메시지는 "Connection is closed"임.

     

     

     

    1-3. 요약

    1. 커밋은 시도되었으나, 응답이 반환되기 전에 소켓 타임아웃이 발생하면서 결과를 받지 못함.
    2. 어플리케이션은 커넥션이 닫히면서  롤백이 실패하고, 최종적으로 트랜잭션이 정상적으로 종료되지 않음.
    3. 다만 DB는 커밋 요청을 받았고 때문에 쿼리가 반영되었음
      • 슬로우 쿼리에 찍혀있었음

     

     

    이 문제는 DB와 애플리케이션 사이에서 커밋의 성공 여부가 달라져 발생한 것 같습니다.

    DB는 소켓이 타임아웃이 난 이후에도 DB에서의 커밋은 성공했지만, 애플리케이션에서는 오류로 인식하는 경우였습니다.

     

    DB설정 중에는 타임아웃과 관련된 옵션들이 있습니다.

    • Connection timeout: 이 설정은 DB와 애플리케이션 사이의 3-way handshake에 필요한 시간을 나타냅니다. 네트워크 측면에서는 네트워크 전송 시간 (RTT: Round Trip Time)와 관련이 있습니다.
    • Socket timeout: 커넥션이 성립된 이후, DB로부터 데이터를 주고받을 때 개별 패킷에서 소요되는 시간의 임계치입니다.
    • Statement timeout: SQL의 수행시간을 제한합니다. socket timeout보다는 짧게 잡아야 각자 다른 의미로 사용할 수 있습니다. statemnet timout을 더 길게 잡으면 socket timout이 항상 먼저 작동하게 됩니다. (Streaming 제외)

    문제가 발생한 원인은 socket timeout으로, 이는 DB에서 프로세싱 시간이 오래 걸렸기 때문으로 보입니다.

     

    더보기
     

    프로젝트 설정을 살펴보니, socket timeout은 10초, statement timeout은 30초로 설정되어 있었습니다.

    이 설정을 기준으로 보면 statement timeout은 발생하지 않고, socket timeout만 발생해야 한다고 생각했습니다.

    그런데 다른 로그를 보니, statement timeout도 발생하고 있었습니다.

     

    차이를 살펴보면, socket timeout은 slow 쿼리에서 발생했고, statement timeout은 대용량 조회 시에 발생한 것이었습니다.

    fetchSize를 설정한 경우, 대용량 조회 시 StreamingResultSet, cursor를 사용하게 됩니다.

    이 방식은 데이터를 한 번에 모두 가져오는 것이 아니라 일정 크기 단위로 받아오게됩니다.

    socket timeout(10초)은 넘지 않지만, 전체 쿼리는 끝나지 않았기에 statement timeout(30초)에 걸려 쿼리가 중단된 것입니다.

     

    에러 코드의 차이를 보면, socket timeout은 NioSocketImpl.timedRead에서 예외가 발생하고, statement timeout의 stack trace는 ClientMessage.readPacket에서 errorCode를 받아 발생합니다.

    즉, socket timeout은 패킷 데이터를 읽는 동안 시간이 초과될 때 발생한 것이고 statement timeout은 DB에서 발생한 timeout으로 인해 쿼리가 중단된 것입니다.

     

     

     

     

     

    코드로 살펴보겠습니다.

     

    https://github.com/brettwooldridge/HikariCP/blob/0a6ccdb334b2ecde25ae090034669d534736a0de/src/main/java/com/zaxxer/hikari/pool/ProxyConnection.java#L151

     

     

     

    Socket에서 발생한 쿼리 오류 후, HikariCP 커넥션에서 어떻게 에러가 처리되는지 살펴보겠습니다.

    먼저 에러 코드를 보면, '08'은 주로 연결 예외를 의미하고, 나머지 코드들도 DB 상태나 연결 장애를 나타냅니다.

    즉, 데이터베이스와의 연결이 불안정할 때 해당 커넥션이 Closed 상태로 처리된다는 것을 알 수 있습니다.

    이때, HikariCP는 연결 문제를 감지하면 그 커넥션을 풀에서 제거하고 닫아버립니다.

    기본적인 SQL 문법 오류 등은 이 단계에 포함되지 않지만, 이와 달리 소켓 오류가 발생하면 SQLException으로 변환되고 상위로 예외가 전파됩니다.

    문제는 이때 커넥션이 이미 Closed 상태이기 때문에, 롤백 시도조차 실패하게 된다는 점입니다.

     

    이를 바탕으로 잠금 대기로 인해 발생한 상황도 추측해 볼 수 있습니다.

    즉, DB에서 잠금이 걸려 대기 중일 때, InnoDB의 innodb_lock_wait_timeout 설정 값(50초)보다 애플리케이션의 socket timeout 설정 값(10초)이 먼저 발생하는 경우가 있을 수 있습니다.

    (사실 statement timeout을 더 짧게 했다면 statement timeout이 발생합니다.)

     

     

     

    2. 트랜잭션 사후 처리

    그럼, 애플리케이션에서 롤백하지 못한 트랜잭션은 DB에서 어떻게 처리될까요?

    애플리케이션과 DB의 기본 동작 방식을 살펴보겠습니다.

     

     

    2-1. DB의 Conncetion 동작 방식

    DB에는 wait_timeout 설정이 있습니다.

    이는 커넥션이 일정 시간 이상 쿼리를 실행시키지 않으면, 해당 커넥션을 종료시키는 역할을 합니다.

    만약 애플리케이션에서 커넥션 close를 호출하지 않았고, DB는 wait_timeout 시간이 지나면 해당 트랜잭션에 대해 롤백을 수행하게 됩니다.

    하지만 이번 사례처럼 커밋이 마지막으로 요청된 상황이었다면, DB가 이를 반영하고 트랜잭션을 종료했을 가능성이 큽니다.

     

     

    2-2. 어플리케이션 (HikariCP)의 Conncetion 동작방식

     

    Spring Boot 2.0부터 기본 DBCP로 HikariCP를 사용하게 되었고, 저희도 몇 가지 커스터마이징을 했지만 기본적으로는 HikariCP를 사용 중입니다. 

    HikariCP의 기본 동작 방식은 다른 자료에서 잘 설명되어 있으니, 여기서는 문제와 관련된 부분만 살펴보겠습니다.

     

    먼저, HikariCP는 커넥션 풀로서 커넥션을 미리 맺어 두는 역할을 합니다.

    그리고 maxLifeTime이라는 설정 값이 있는데, 이는 커넥션의 최대 수명을 뜻합니다.

    커넥션은 어플리케이션이 종료될 때까지 유지되는 것이 아니라, maxLifeTime이 지나면 스케줄러에의해 종료됩니다.

     

     

     

    wait_timeout(DB)와 maxLifeTime의 관계

     

    https://github.com/brettwooldridge/HikariCP/blob/0a6ccdb334b2ecde25ae090034669d534736a0de/src/main/java/com/zaxxer/hikari/pool/HikariPool.java#L154

     

     

    잘 알려진 정보 중 하나는 HikariCP의 maxLifeTime을 DB의 wait_timeout보다 짧게 설정해야 한다는 점입니다. 

    그 이유는 DB의 wait_timeout이 더 짧을 경우, DB에서 먼저 연결을 끊으면 애플리케이션이 그 사실을 즉시 알지 못하기 때문입니다. 

    이를 알기 위해서는 주기적으로 연결 상태를 확인하거나, 실제로 연결을 사용하려는 순간에 끊긴 것을 알게 됩니다.

    따라서 wait_timeout을 maxLifeTime보다 길게 설정하면, 애플리케이션과 DB 간의 연결이 자연스럽게 순차적으로 종료되어 추가적인 관리 없이도 안정적으로 커넥션을 관리할 수 있습니다.

     

    결과적으로, HikariCP는 이러한 방식으로 커넥션을 관리하고 스케줄러가 도는 시점에 커넥션을 적절히 종료하게 됩니다.

     

    JDBC autoReconnect Option

    JDBC의 autoReconnect 옵션은 사실 HikariCP를 사용할 때는 큰 의미가 없는 설정 같습니다.

    특히 HikariCP의 maxLifeTime을 DB의 wait_timeout보다 짧게 설정했다면 더욱 그렇습니다.

    HikariCP 자체적으로 재연결 기능을 제공하기 때문에 굳이 이 옵션을 사용할 필요가 없습니다.

    하지만 HikariCP나 다른 DBCP(Connection Pool)를 사용하지 않는 경우에는 autoReconnect 옵션을 고려해 볼 수 있습니다.

    다만, MySQL에서도 이 설정을 권장하지 않으며, 트랜잭션 중간에 발생하는 연결 문제는 직접 처리해야 할 가능성이 큽니다.

     

     


    2-3. HikariCP Seceduler

    더보기

    HikariCP 스케줄러는 주기적으로 커넥션을 관리하고 종료시키는 작업을 수행합니다.

    여기서는 MaxTimeTask, HouseKeeperTask, KeepAliveTimeTask 그리고 ProxyLeakTask에 대해 설명드리겠습니다.

     

    MaxTimeTask

    maxLifeTime은 커넥션 생성 시 스케줄러에 등록되고, 주기적으로 돌면서 커넥션의 수명이 끝났는지 확인하고 종료시키는 역할을 합니다.

    모든 커넥션을 한 번에 종료하지 않기 위해 2.5%의 시간차를 두고 순차적으로 종료하는 로직이 있습니다.

    이 과정에서 새로운 커넥션이 필요한 경우 생성 요청이 발생하게 됩니다.

     

    HouseKeeperTask

    idleTimeout은 커넥션이 유휴 상태로 얼마나 있었는지를 확인하여, 그 시간이 넘으면 종료시키는 역할을 합니다.

    예를 들어 maxLifeTime이 94초이고 idleTimeout이 30초일 경우, 커넥션이 30초 이상 유휴 상태였다면 maxLifeTime에 도달하지 않아도 종료됩니다.

    따라서 idleTimeout은 maxLifeTime보다 짧게 설정해야 효과적으로 동작할 수 있습니다.

    추가적으로 커넥션이 부족하면 자동으로 새 커넥션을 생성합니다.

     

    KeepAliveTimeTask

    keepAliveTime은 풀에 있는 커넥션이 정상적으로 살아 있는지 미리 확인하는 절차입니다.

    이를 통해 트래픽이 발생할 때 새로운 커넥션을 생성하는 대신, 미리 관리하여 빠른 응답성을 제공할 수 있습니다.

    DB에서 커넥션이 끊어지는 주된 이유는 자원 부족이나 maxLifeTime이 wait_timeout보다 긴 경우입니다. 이는 드물게 발생하는 일이지만, idle 상태의 커넥션이 DB에 의해 필요에 따라 끊어질 수 있습니다.

     

    ProxyLeakTask

    getConnection을 통해 커넥션을 반환할 때, 누수 감지 스케줄러도 함께 등록합니다.

    설정된 누수 감시 시간 내에 커넥션이 반환되지 않으면 로그가 기록됩니다.

    커넥션을 반환할 때 해당 task를 종료하기 때문에, 정상적으로 반환된 커넥션은 누수 감지에 걸리지 않게 됩니다.

     

     

     

    +

    재밌는 것은 넷마블같이 게임 서비스는 커넥션을 끊지 않고 계속 유지한다고 합니다.

     

     

     

    3. 대응

    사실, 커밋이 슬로우 쿼리로 잡히는 상황에서는 별다른 해결책이 없다고 생각합니다.
    단일 서비스였다면 관련된 작업들을 하나의 트랜잭션으로 묶어 상태 일관성 문제를 해결할 수 있었겠지만, 분산 서비스에서는 커밋 과정에서 오류가 발생하면 분산 트랜잭션으로도 해결하기 어렵습니다. 

    어플리케이션은 오류로 인식하지만, 실제로는 DB에 반영되었기 때문입니다.


     

     

     

    이 때문에 멱등성을 고려한 설계를 하는 것으로 해결할 수 있습니다.

    즉, API 호출이 여러 번 발생해도 같은 결과를 유지하도록 해야 합니다. 

    이렇게 하면 네트워크 장애로 인해 커밋이 슬로우 쿼리로 잡히더라도, 다른 서비스는 재시도를 통해 올바른 응답을 받을 수 있고, 이후 자신의 상태를 정상적으로 변경할 수 있습니다.

     

    사실 근본적으로 DB에 Slow Query가 잡히지 않도록 하는 것이 좋습니다.

    트랜잭션의 크기를 줄이고, DB서버의 CPU, 메모리 부하가 왜 이뤄졌는지 원인을 파악해야합니다.

     

     

     

    4. 마무리

    HikariCP에 대해 항상 궁금했었는데, 이번 기회에 공부할 수 있어서 좋았습니다.

    코드를 보면서 굉장히 잘 짜여 있다는 인상을 받았고, 여러 디자인 패턴이 적절하게 사용된 것도 인상적이었습니다.

    이 코드만 봐도 공부가 될 정도였습니다. 특히 스케줄러 관련 코드도 상황에 맞게 잘 활용된 부분에서 감탄하게 되었습니다.

    저도 비즈니스 로직도 이런 식으로 설계할 수 있다면 정말 좋을 것 같습니다.

     

    추가로, statement timeout과 socket timeout의 관계에 대해 흥미로운 사실을 알게 되었습니다.

    경험에 따르면, statement timeout이 socket timeout보다 길더라도 항상 socket timeout이 발생하는 것은 아니었습니다.

     streaming이 이루어질 때는 socket timeout이 발생하지 않는다것을 확인했습니다.

     

    여러 방면에서 코드를 디버깅하는 것은 재미있고, 많은 배움을 주는 작업이라는 생각이 듭니다.

     

     

     

     

     

     

     

     

    댓글

Designed by Tistory.