java.sql.SQLException: connection holder is null

简介: java.sql.SQLException: connection holder is nullCause: java.sql.SQLException: connection holder is null; uncategorized SQLEx...

java.sql.SQLException: connection holder is null

Cause: java.sql.SQLException: connection holder is null

; uncategorized SQLException for SQL []; SQL state [null]; error code [0]; connection holder is null; nested exception is java.sql.SQLException: connection holder is null
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:83)
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
at org.mybatis.spring.MyBatisExceptionTranslator.translateExceptionIfPossible(MyBatisExceptionTranslator.java:75)
at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:447)
at com.sun.proxy.$Proxy72.selectOne(Unknown Source)
at org.mybatis.spring.SqlSessionTemplate.selectOne(SqlSessionTemplate.java:167)
at org.apache.ibatis.binding.MapperMethod.execute(MapperMethod.java:82)
at org.apache.ibatis.binding.MapperProxy.invoke(MapperProxy.java:53)
at com.sun.proxy.$Proxy168.getIssueTotalValid(Unknown Source)
at com.alibaba.swork.info.common.service.quality.impl.QualityDataOfTeamServiceImpl.syncQualityDataOfTeam(QualityDataOfTeamServiceImpl.java:63)
at com.alibaba.swork.info.common.service.quality.impl.QualityDataOfTeamServiceImpl.saveQualityDataOfTeamDTS(QualityDataOfTeamServiceImpl.java:48)
at com.alibaba.swork.info.common.service.quality.impl.QualityDataOfTeamServiceImpl$$FastClassByCGLIB$$8eb081d2.invoke(<generated>)
at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204)
at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:698)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:96)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:260)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:94)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:91)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:631)
at com.alibaba.swork.info.common.service.quality.impl.QualityDataOfTeamServiceImpl$$EnhancerByCGLIB$$7e8e4849.saveQualityDataOfTeamDTS(<generated>)
at com.alibaba.swork.info.common.biz.job.dts.QualityDataOfTeamJob.job(QualityDataOfTeamJob.java:24)
at com.alibaba.swork.info.common.biz.job.dts.QualityDataOfTeamJob.onProcess(QualityDataOfTeamJob.java:20)
at com.alibaba.swork.info.common.biz.job.dts.AbstractDTSJob.process(AbstractDTSJob.java:28)
at com.alibaba.dts.client.executor.simple.processor.SimpleTaskProcessor.executeTask(SimpleTaskProcessor.java:146)
at com.alibaba.dts.client.executor.simple.processor.SimpleTaskProcessor.run(SimpleTaskProcessor.java:100)
Caused by: java.sql.SQLException: connection holder is null
at com.alibaba.druid.pool.DruidPooledConnection.checkStateInternal(DruidPooledConnection.java:1120)
at com.alibaba.druid.pool.DruidPooledConnection.checkState(DruidPooledConnection.java:1113)
at com.alibaba.druid.pool.DruidPooledConnection.getHoldability(DruidPooledConnection.java:969)
at com.taobao.tddl.atom.jdbc.TConnectionWrapper.getHoldability(TConnectionWrapper.java:145)
at com.taobao.tddl.group.jdbc.TGroupPreparedStatement.createPreparedStatementInternal(TGroupPreparedStatement.java:78)
at com.taobao.tddl.group.jdbc.TGroupPreparedStatement.executeQueryOnConnection(TGroupPreparedStatement.java:120)
at com.taobao.tddl.group.jdbc.TGroupStatement.executeQuery(TGroupStatement.java:488)
at com.taobao.tddl.group.jdbc.TGroupStatement.executeInternal(TGroupStatement.java:131)
at com.taobao.tddl.group.jdbc.TGroupStatement.execute(TGroupStatement.java:101)
at com.taobao.tddl.group.jdbc.TGroupPreparedStatement.execute(TGroupPreparedStatement.java:104)
at org.apache.ibatis.executor.statement.PreparedStatementHandler.query(PreparedStatementHandler.java:63)
at org.apache.ibatis.executor.statement.RoutingStatementHandler.query(RoutingStatementHandler.java:79)
at org.apache.ibatis.executor.SimpleExecutor.doQuery(SimpleExecutor.java:63)
at org.apache.ibatis.executor.BaseExecutor.queryFromDatabase(BaseExecutor.java:324)
at org.apache.ibatis.executor.BaseExecutor.query(BaseExecutor.java:156)
at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:109)
at com.github.pagehelper.PageInterceptor.intercept(PageInterceptor.java:142)
at org.apache.ibatis.plugin.Plugin.invoke(Plugin.java:61)
at com.sun.proxy.$Proxy219.query(Unknown Source)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:148)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:141)
at org.apache.ibatis.session.defaults.DefaultSqlSession.selectOne(DefaultSqlSession.java:77)
at sun.reflect.GeneratedMethodAccessor123.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:434)
... 24 more
Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure

The last packet successfully received from the server was 12,014 milliseconds ago. The last packet sent successfully to the server was 12,012 milliseconds ago.

相关文章
|
1月前
|
SQL 存储 数据库
SQL NOT NULL
【11月更文挑战第14天】
40 6
|
2月前
|
SQL 关系型数据库 MySQL
|
4月前
|
IDE Java 测试技术
如何优雅地根治Java中Null值引起的Bug问题
【8月更文挑战第18天】在Java开发中,null 值是一个既常见又危险的存在。它常常是导致程序崩溃、难以调试的“罪魁祸首”。然而,通过一系列优雅的策略和实践,我们可以有效地减少甚至根除由 null 值引发的Bug。本文将从多个方面探讨如何做到这一点。
92 4
|
4月前
|
Java 测试技术
Java系列之判断字符串是为空或者null
这篇文章介绍了如何在Java中使用`isEmpty()`方法判断字符串是否为空或`null`,并提供了相应的测试用例来演示其用法。
|
4月前
|
存储 JavaScript Java
Java中未被初始化的字符串打印出“null”?
在Java中,未初始化的`String`变量默认值为`null`。打印此类变量时输出“null”,是因为`PrintStream`类中的`print`方法特别处理了`null`值,将其转换为字符串“null”。从JDK 17开始,`println`方法通过`String.valueOf`间接实现相同功能。当拼接包含`null`的字符串时,如`s1 + &quot;BLACK&quot;`,结果为“nullBLACK”,这是因为字符串构建过程中`StringBuilder`的`append`方法将`null`转换为“null”。
|
4月前
|
NoSQL Java Redis
【Azure Spring Cloud】Java Spring Cloud 应用部署到Azure上后,发现大量的 java.lang.NullPointerException: null at io.lettuce.core.protocol.CommandHandler.writeSingleCommand(CommandHandler.java:426) at ... 异常
【Azure Spring Cloud】Java Spring Cloud 应用部署到Azure上后,发现大量的 java.lang.NullPointerException: null at io.lettuce.core.protocol.CommandHandler.writeSingleCommand(CommandHandler.java:426) at ... 异常
|
5月前
|
SQL
SQL NOT NULL 约束
【7月更文挑战第18天】SQL NOT NULL 约束。
50 6
|
5月前
|
SQL
SQL NOT NULL 约束
【7月更文挑战第16天】SQL NOT NULL 约束。
36 3
|
4月前
|
Java 程序员 开发者
Java之! = null判空
总之,`!= null`的判空技巧对于任何使用Java进行开发的程序员都是基本功,它有助于维护代码的清晰度和安全性,在编写可靠和维护性强的软件应用时扮演着关键角色。掌握这个简单却重要的技术,将对任何Java开发者的职业生涯大有裨益。
84 0
|
5月前
|
网络协议 Java 应用服务中间件
解决java.net.ConnectException: Connection refused:connect报错
解决java.net.ConnectException: Connection refused:connect报错
1089 1