tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Eggers <its_toas...@yahoo.com>
Subject Re: Login fails, then works subsequently (Tomcat 7)
Date Thu, 22 Dec 2011 19:35:19 GMT
----- Original Message -----

> From: Hassan Schroeder <hassan.schroeder@gmail.com>
> To: Tomcat Users List <users@tomcat.apache.org>
> Cc: 
> Sent: Wednesday, December 21, 2011 2:40 PM
> Subject: Re: Login fails, then works subsequently (Tomcat 7)
> 
> On Wed, Dec 21, 2011 at 2:23 PM, Jerry Malcolm <2ndgenfilms@gmail.com> 
> wrote:
>>  Here is the line from <GlobalNamingResources> in server.xml:
> 
> No "testWhileIdle" / "validationQuery" settings?
> 
> 10 to 1 you've got stale connections in your pool; first try fails, second
> one gets a fresh connection and away you go.
> 
> Just a WAG -- no idea why you'd only see this after upgrading.
>

I seem to recall an issue with using autoReconnect with pooled connections. According to the
MySQL bug database, it's recommended to not use autoReconnect (see for example http://bugs.mysql.com/bug.php?id=5020 at
the end).

I recommend the validationQuery approach and testWhileIdle Hassan mentioned above.


I have no idea as well why this would suddenly pop up in Tomcat 7.0.x as opposed to Tomcat
5.5.x.

Using pools with at least a validationQuery for authentication addresses a host of other issues
concerning authentication / authorization that arises due to the frequency / infrequency of
requests when compared to normal application database requests.

There was a long discussion concerning those issues on the mailing list some time back. Look
for "problems at thejarbar.org" - I think that was the thread.

. . . just my two cents.
/mde/ 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message