Skip Connection::setNetworkTimeout if PoolBase::shutdownNetworkTimeoutExecutor is called (#2147)

Fix GH-2130
pull/2241/head
Yanming Zhou 4 months ago committed by GitHub
parent 4f6b295e14
commit 82c82adfda
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -73,7 +73,7 @@ abstract class PoolBase
private static final int MINIMUM_LOGIN_TIMEOUT = Integer.getInteger("com.zaxxer.hikari.minimumLoginTimeoutSecs", 1);
private int networkTimeout;
private int isNetworkTimeoutSupported;
private volatile int isNetworkTimeoutSupported;
private int isQueryTimeoutSupported;
private int defaultTransactionIsolation;
private int transactionIsolation;
@ -244,6 +244,7 @@ abstract class PoolBase
void shutdownNetworkTimeoutExecutor()
{
isNetworkTimeoutSupported = UNINITIALIZED;
if (netTimeoutExecutor instanceof ThreadPoolExecutor) {
((ThreadPoolExecutor) netTimeoutExecutor).shutdownNow();
}

Loading…
Cancel
Save