You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks for raising the issue. It's indeed an issue that creation completion cannot be awaited. I think we should introduce a new factory method (BoundedAsyncPool.create(…)) that returns a CompletableFuture so pre-warming can be properly synchronized. We also need to reflect this behavior in the documentation.
BoundedAsyncPool now exposes a create(…) method that returns a CompletionStage that emits the pool once it has finished creation and initialization. The documentation on previously available creation methods reflects that initialization isn't awaited.
BoundedAsyncPool now exposes a create(…) method that returns a CompletionStage that emits the pool once it has finished creation and initialization. The documentation on previously available creation methods reflects that initialization isn't awaited.
Feature Request
Is your feature request related to a problem? Please describe
BoundedAsyncPool
is ready to be manipulated with even though there is no connection available yet. This causes errors like:Describe the solution you'd like
Either wait for a connection (
min-idle
) to be ready upon object pool creation or provide a way to check, whether there are any available connections.Documentation of the
BoundedAsyncPool
says:I would probably rephrase this sentence to make it clear that it actually requests the idle objects to be created only.
Describe alternatives you've considered
Currently I have to sleep for a fixed amount of ms to work-around this behavior. Which is pretty ugly.
Question
What is the proper way to
work-around
this behavior?Thank you.
The text was updated successfully, but these errors were encountered: