Sunday, February 1, 2015

Using Spring with Hibernate and c3p0 Connection Pool.

C3P0 is a very nice tool to manage database connections. I had hard time configuring Apache DBCP/2 so tried C3P0 and it was very easy to use.. There are many config options to set and the setting has to be done carefully so that we do not end up choking our database. Lets understand some the config options. testConnectionOnCheckin validates the connection when it is returned to the pool. testConnectionOnCheckOut would...