tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From הילה <hilavalen...@gmail.com>
Subject JDBC Pool Disconnections
Date Tue, 05 Apr 2011 13:31:36 GMT
Hey,

I have lately (with your help) switched the pool that tomcat uses , from the
basic pool to the JDBC pool, with these actions-
1. under <resource> tag in xml configuration
[conf/catalina/localhost/Appname.xml] I specified the factory name, as you
can see below-

name="jdbc/com/vstechnology/appname
scope="Shareable"
type="javax.sql.Datasource"
url="jdbc:jtds:sqlserver://SQLServerName:1433/DBname;useCursors=false;sendStringParametersAsUnicode=false"
factory="org.apache.tomcat.jdbc.pool.DataSourceFactory"
maxActive="200"
minIdle="0"
maxIdle="10"
maxWait="10000"
initialSize="20"
driverClassName="net.sourceforge.jtds.jdbc.Driver"

[no need to mention user and password, since I use windows authentication -
for those of you who remember my thread a couple of weeks ago]

2. put the tomcat-jdbc.jar file in lib folder of tomcat, not lib folder
under webapps/appname/WEB-INF. correct me if it needs to be there as well
(it works without it so far).


Since then, we experience disconnections of client to app server, that occur
becuase of app servers-DB disconnections.
These errors appear in the logs (not together, i've collected them)-

* ERROR, hibernate.transaction.JDBCTransaction JDBC begin failed
javasql.SQLException: Invalid state, the Connection object is closed.

* org.hibernate.util.JDBCExceptionReporter , Timeout: Pool empty. Unable to
fetch a connection in 10 seconds, none available[0 in use]

* WARN, hibernate.util.JDBCExceptionReporter SQL Error: 0, SQLState: 08S01
ERROR, hibernate.util.JDBCExceptionReporter I/O Error: DB server closed
connection.
ERROR,  error processing request:   exception.*appname*Error:
.hibernate.exception.JDBCConnectionException: Cannot open connection


Our DBA guys looked at the SQL server logs and monitoring system, and
haven't found any issues
Network also looked at it and says that everything is ok on their side,
which leads me to believe that there's a problem with the JDBC pool, or
something else regarding the connection to DB.

It happens mainly under load, but not just under load.

do you know these errors I got in logs? does somebody have any idea how to
solve it and stop the disconnections?

Thanks
Hila

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message