Put connection check statement in cache
When the connection check level is set to a value greater than 1, a statement is created and executed at each getConnection() call what might be quite time consuming; An improvement consists in relying on a prepared statement rather than a statement if cache is enabled. This the prepared statement is compiled only once.