您好,登錄后才能下訂單哦!
報(bào)錯(cuò)信息:
ERROR c.alibaba.druid.pool.DruidDataSource - recyle error
java.sql.SQLException: Connection.clearWarnings cannot be called on a closed connection
at org.mariadb.jdbc.internal.util.exceptions.ExceptionMapper.getSqlException(ExceptionMapper.java:271)
at org.mariadb.jdbc.MariaDbConnection.clearWarnings(MariaDbConnection.java:1070)
at com.alibaba.druid.filter.FilterChainImpl.connection_clearWarnings(FilterChainImpl.java:165)
at com.alibaba.druid.filter.FilterAdapter.connection_clearWarnings(FilterAdapter.java:771)
at com.alibaba.druid.filter.FilterChainImpl.connection_clearWarnings(FilterChainImpl.java:161)
at com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl.clearWarnings(ConnectionProxyImpl.java:108)
at com.alibaba.druid.pool.DruidConnectionHolder.reset(DruidConnectionHolder.java:295)
at com.alibaba.druid.pool.DruidDataSource.recycle(DruidDataSource.java:1662)
問題:
spring.datasource.druid.initial-size=1
spring.datasource.druid.min-idle=1
spring.datasource.druid.max-active=20
spring.datasource.druid.test-on-borrow=true
spring.datasource.druid.stat-view-servlet.allow=true
spring.datasource.druid.max-wait=60000
解決方案:
spring.datasource.druid.initial-size=1
spring.datasource.druid.min-idle=1
spring.datasource.druid.max-active=20
spring.datasource.druid.test-on-borrow=false
spring.datasource.druid.test-while-idle=true
spring.datasource.druid.validation-query=select 'X'
因?yàn)樯倥渲昧诉@個(gè)所以拿到了連接不檢查,哭暈.........
怪自己太年輕......
spring.datasource.druid.validation-query=select 'X'
免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點(diǎn)不代表本網(wǎng)站立場,如果涉及侵權(quán)請(qǐng)聯(lián)系站長郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。