Fail with exception on timeout while waiting for connection pool#1342
Open
dennisschroer wants to merge 3 commits intoeclipse-vertx:masterfrom
Open
Fail with exception on timeout while waiting for connection pool#1342dennisschroer wants to merge 3 commits intoeclipse-vertx:masterfrom
dennisschroer wants to merge 3 commits intoeclipse-vertx:masterfrom
Conversation
994f719 to
64f33ae
Compare
vietj
reviewed
Jul 31, 2023
vertx-sql-client/src/main/java/io/vertx/sqlclient/impl/pool/SqlConnectionPool.java
Outdated
Show resolved
Hide resolved
Member
|
can you reproduce this case with a test ? it is not clear how it happens. I would like this behaviour to be tested and the only case it can happen is when the connection pool is too busy to respond (which shall not happen unless it is blocked) or when there is a race with the acquisition (basically cancel succeeds and returns false, it was not able to cancel because the handler got satisfied which makes the connection borrower progress). also this callback cannot fail, it is always completed with a succeeded future, unless the pool is closed |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation:
When a timeout occurs while waiting for a new connection, the future fails with a simple "Timeout" message without a stack trace. This makes it very difficult to debug where in the application the error occurs. We have a longer running process with multiple requests to the database, and having a stacktrace would help us.
Conformance:
You should have signed the Eclipse Contributor Agreement as explained in https://github.com/eclipse/vert.x/blob/master/CONTRIBUTING.md
Please also make sure you adhere to the code style guidelines: https://github.com/vert-x3/wiki/wiki/Vert.x-code-style-guidelines