druid 1.0.31 版本 高并发的情况下偶尔报错: statement is closed

u4vypkhs  于 2022-10-22  发布在  Druid
关注(0)|答案(2)|浏览(817)

java.sql.SQLException: statement is closed at com.alibaba.druid.pool.DruidPooledStatement.checkOpen(DruidPooledStatement.java:86) at com.alibaba.druid.pool.DruidPooledStatement.getConnection(DruidPooledStatement.java:585) at com.dangdang.ddframe.rdb.sharding.executor.ExecutorEngine.executeInternal(ExecutorEngine.java:160) at com.dangdang.ddframe.rdb.sharding.executor.ExecutorEngine.access$000(ExecutorEngine.java:61) at com.dangdang.ddframe.rdb.sharding.executor.ExecutorEngine$1.call(ExecutorEngine.java:147) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)

配置项如下
dataSource.setUrl(dataUrl); dataSource.setDriverClassName(driverClassName); dataSource.setPassword(password); dataSource.setUsername(username); dataSource.setMinIdle(1); dataSource.setMaxActive(10); dataSource.setValidationQuery("select 1 from dual"); dataSource.setMaxWait(100000);

2skhul33

2skhul331#

应该是有场景把Statement关闭。没有更多信息无法诊断,要不你升级到最新版本1.1.12看是否能报更多错误信息。

sqougxex

sqougxex2#

应该是有场景把Statement关闭。没有更多信息无法诊断,要不你升级到最新版本1.1.12看是否能报更多错误信息。

我用的链接池 statement是链接池自动开启和关闭的吧 代码中没有主动关闭的地方。另外1.1.12版本有什么特质吗 错误信息会很详细吗

相关问题