我的连接属性如下所示
jdbc.debugUnreturnedConnectionStackTraces =真
偶尔会出现以下错误
引起:java.sql.SQLException:Io异常:软件导致连接中止:recv失败 at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:74) at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:131) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:197) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:261) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:566) at oracle.jdbc.driver.T4CPreparedStatement.executeForDescribe(T4CPreparedStatement.java:802) at oracle.jdbc.driver.T4CPreparedStatement.executeMaybeDescribe(T4CPreparedStatement.java:866) at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1186) at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3387) at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:3431) at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeQuery(OraclePreparedStatementWrapper.java:1203) 在com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.executeQuery(NewProxyPreparedStatement.java:76) 在org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:186) 在org.hibernate.loader.Loader.getResultSet(Loader.java:1787) 在org.hibernate.loader.Loader.doQuery(Loader.java:674) 在org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:236) 在org.hibernate.loader.Loader.loadEntity(Loader.java:1860)
之后它运作正常。
答案 0 :(得分:0)
这不太可能与连接池有很大关系。这是一个网络/ JDBC驱动程序问题。特别是,您可能希望查找Oracle错误9373409 - 请参阅https://forums.oracle.com/message/9176463#9176463 https://forums.oracle.com/message/10332437#10332437如果这是您的问题,您可能需要升级Oracle安装,错误9373409本来应该已经修复了“补丁集”11.2.0.3,见http://www.eygle.com/Notes/11203_buglist.htm