运行环境:
openjdk 11.0.4 2019-07-16 OpenJDK Runtime Environment (build 11.0.4+11-post-Debian-1deb10u1) OpenJDK 64-Bit Server VM (build 11.0.4+11-post-Debian-1deb10u1, mixed mode, sharing)
tomcat 9.0.16
PostgreSQL 11.5 (Debian 11.5-1+deb10u1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 8.3.0-6) 8.3.0, 64-bit
JDBC driver pgJDBC 42.2.5
原本使用druid 1.1.19版本,最近升级到最新版本1.2.15后,只升级了druid,其他没有改变,出现以下问题:
tomcat应用程序日志出现: org.postgresql.util.PSQLException: An I/O error occurred while sending to the backend.
postgresql数据库日志出现: unexpected EOF on client connection with an open transaction
应用程序闲置一段时间会出现此问题 ,比如晚上没人使用,早上第一次访问时应用程序会出错,但再次访问就不再出错了。
这个错误每天都出现几次,现在换回了1.1.24版本,问题消失不见了。