Fail the callback in case we cannot activate a newly created connection.
This commit is contained in:
parent
43f14997d8
commit
2a749dc0ea
|
@ -106,6 +106,8 @@ public class ConnectionPool implements Closeable, Dumpable
|
|||
LOG.debug("Connection {}/{} creation succeeded {}", next, maxConnections, connection);
|
||||
if (activate(connection))
|
||||
connectionPromise.succeeded(connection);
|
||||
else
|
||||
connectionPromise.failed(new IllegalStateException("Active connection overflow"));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
Loading…
Reference in New Issue