Mailing List
Home
Forum Home
MySQL General - General MySQL discussion
MaxDB - Everything about MaxDB, formerly known as SAP DB
MySQL++ - Programming with the C++ API to MySQL
MySQL on Win32 - Runing MySQL on Windows 9x/Me/NT/2000/XP
ODBC - ODBC with the MySQL Connector/ODBC driver
Java Help - Mostly related to the MySQL Connector/J driver
Perl - Perl support for MySQL with DBI and DBD::mysql
GUI - MySQL GUI Tools
Announcement
Subjects
mysql openssl Question
mysql:it 's a db not a dbms how it 's possible?!
Does the binary log enabling affect the MySQL performances?
Strange behavior, Table Level Permission
FULLTEXT query format question
Preventing Duplicate Entries
Comparing and writing out BLOBS
Executing MySQL Commands From Within C Program
Can 't access mysql after kernel upgrade
Mysql 4 0 Oracle Stored Procedure Trigger Conversion
Downgrade Mysql from 4 to 3 23
MySQL Cluster Software
mysql test 4 1 fails with the gis test
ERROR 2002: Can 't connect to local MySQL server through socket
Getting Identity after INSERT
Update one field with more fields from another table
ERROR 1045: Access denied for user: 'root@localhost ' (Using
password: NO)
mysql have same function mthod as Oracle decode()
 
Datasource JNDI and DataSourceRealm 8 hour timeout

Datasource JNDI and DataSourceRealm 8 hour timeout

2005-07-12       - By Martijn

 Back
Reply:     1     2  

Hello list,

This is something which keep on hunting me for some time now and I'm
getting somewhat frustrated here. Yes, this is related to the 8hour
timeout, and yes this has haunted this list before in some other form.
I'm using the standard Connector/J definition from
http://dev.mysql.com/doc/connector/j/en/cj-tomcat-config.html.

So with this definition the regular I/O Communication Exceptions after 8
hours of being idle don't occur anymore. I can access my web application
for days on end. Great!

But the Exception resurfaces when I try to login again through the
DataSourceRealm definition (which uses the jdbc/MySQLDB). I get the
Communication Exception once more and it seems that this single login
kills my pool completely since all connections from that point on are
'stale'. I have to reload the context to revive the system.

I have fiddled with the settings (timeout related). I also have set the
following parameters, but to no avail:

       <parameter>
               <name>removeAbandoned</name>
               <value>true</value>
       </parameter>
       <!--Use the removeAbandonedTimeout parameter / seconds.-->
       <parameter>
               <name>removeAbandonedTimeout</name>
               <value>60</value>
       </parameter>
       <parameter>
               <name>logAbandoned</name>
               <value>true</value>
       </parameter>

Again, all works out, but the DataSourceRealm blows it al.

FYI. I'm using Tomcat 5.0.28 and Connector/J 3.1.10 at the moment.
Having the same problems with the 3.0.x series.

Has anyone experienced this in the past, or can anyone provide me with
some help here? C3P0?

regards,
Martijn Smit



--
MySQL Java Mailing List
For list archives: http://lists.mysql.com/java
To unsubscribe:    http://lists.mysql.com/java?unsub=mysql@(protected)