[#3881] FixedChannelPool creates 1 more channel than maxConnections
Motivation: FixedChannelPool should enforce a number of maximal used channels, but due a bug we fail to correctly enforce this. Modifications: Change check to correctly only acquire channel if we not hit the limit yet. Result: Correct limiting.
This commit is contained in:
parent
f5fd34e4ba
commit
8925fe4228
@ -264,7 +264,7 @@ public final class FixedChannelPool extends SimpleChannelPool {
|
||||
}
|
||||
|
||||
private void runTaskQueue() {
|
||||
while (acquiredChannelCount <= maxConnections) {
|
||||
while (acquiredChannelCount < maxConnections) {
|
||||
AcquireTask task = pendingAcquireQueue.poll();
|
||||
if (task == null) {
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user