pull/347/head
Nitin 10 years ago
parent 8fd73d2501
commit 7bb009be24

@ -239,7 +239,7 @@ public class HikariPool implements HikariPoolMXBean, IBagStateListener
try {
poolState = POOL_SHUTDOWN;
LOGGER.info("{} - is closing down.", poolName);
LOGGER.info("{} - is shutting down.", poolName);
logPoolState("Before closing ");
connectionBag.close();
@ -483,7 +483,7 @@ public class HikariPool implements HikariPoolMXBean, IBagStateListener
// Speculative increment of totalConnections with expectation of success
if (totalConnections.incrementAndGet() > config.getMaximumPoolSize()) {
totalConnections.decrementAndGet(); // Pool is maxed out, so undo speculative increment of totalConnections
lastConnectionFailure.set(new SQLException(poolName +" - is at maximum capacity"));
lastConnectionFailure.set(new SQLException(poolName + " - is at maximum capacity"));
return true;
}
@ -505,7 +505,7 @@ public class HikariPool implements HikariPoolMXBean, IBagStateListener
totalConnections.decrementAndGet(); // We failed, so undo speculative increment of totalConnections
lastConnectionFailure.set(e);
if (poolState == POOL_NORMAL) {
LOGGER.debug("{} - Cannot acquire connection from data source", poolName, e);
LOGGER.debug("{} - Cannot acquire connection from data source", poolName, e);
}
poolElf.quietlyCloseConnection(connection, "(exception during connection creation)");
return false;

@ -113,7 +113,7 @@ public final class PoolElf
return field.getInt(null);
}
catch (Exception e) {
throw new IllegalArgumentException(poolName + " - Invalid transaction isolation value: " + transactionIsolationName);
throw new IllegalArgumentException("Invalid transaction isolation value: " + transactionIsolationName);
}
}
@ -161,7 +161,7 @@ public final class PoolElf
void setupConnection(final Connection connection, final long connectionTimeout) throws SQLException
{
if (isUseJdbc4Validation && !isJdbc4ValidationSupported(connection)) {
throw new SQLException("Connection.isValid() is not supported, connection test query must be configured");
throw new SQLException("Connection.isValid() method is not supported, connection test query must be configured");
}
networkTimeout = getAndSetNetworkTimeout(connection, connectionTimeout);

Loading…
Cancel
Save