Pool will use only endpoints available at the call moment.
If there are no available endpoints then a pool will not be created.
We need to rework this two moments:
Some endpoints may gone forever from a client point of view. We could avoid it and try to reconnect to unavailable endpoints in a background (as it already done if an endpoint became available).
We could create/use (with an error) an empty pool since we have Add and Remove methods. So from the API point of view it would be nice to have an ability to create a pool object and add instances later.
The current
pool.Connect
logic:We need to rework this two moments:
Add
andRemove
methods. So from the API point of view it would be nice to have an ability to create a pool object and add instances later.