-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Amit,

On 3/6/12 4:46 AM, amit shah wrote:
> Hello, I am using the tomcat jdbc pool independently in my
> application and frequently I faced a NullPointerException with the
> below stack trace
> 
> null at 
> org.apache.tomcat.jdbc.pool.ConnectionPool.setupConnection(ConnectionPool.java:276)

What
> 
exact version of Tomcat and/or the Tomcat pool are you using?

> The root cause of the exception is suppressed by the jdbc pool code
> by returning null from the validate() method. My point of raising
> this up is that it becomes hard to troubleshoot such errors in
> production when the actual exception is suppressed. The actual
> exception occurs while executing the initSQL query or the
> validation query.
> 
> Shouldn't an exception be thrown right at the point where the
> error occurred?

I don't see any place in setupConnection where an exception is
swallowed, do you?

http://svn.apache.org/viewvc/tomcat/trunk/modules/jdbc-pool/src/main/java/org/apache/tomcat/jdbc/pool/ConnectionPool.java?view=markup

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk9WIS4ACgkQ9CaO5/Lv0PAyFACfe/0jqpUzA1krhuxTFb/4sxJQ
46oAoJXV48dwC6IFy4f1dozhOc45Wo3R
=ZHQa
-----END PGP SIGNATURE-----

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

Reply via email to