-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
4.0.0: JDBC connections sharing task-queue, leading to client-side deadlock #203
Comments
From my understanding, the usage of |
Can you provide a reproducer ?
…On Fri, Feb 5, 2021 at 2:34 AM Gattag ***@***.***> wrote:
From my understanding, the usage of TaskQueue was placed behind
DuplicatedContext, now when you call ContextInternal::duplicate a new
DuplicatedContext is returned with its own TaskQueue for blocking tasks,
but it is otherwise near identical to the parent Context. I think the
problem may lie in the fact that I do not see the DuplicatedContext per
connection being created anywhere, thus they all end up sharing the same
TaskQueue.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#203 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABXDCUDEENQCGEFBQTOLKTS5NDK7ANCNFSM4WJHAMIA>
.
|
Version
4.0.0
Context
Application code which worked without issue on 3.9.x leads to a (non-database) deadlock on 4.0.0.
This is the scenario:
Each database action is handled within vertx as a blocking operation (
JDBCConnectionImpl.schedule
), so after the add to table1 completes, the add from the second request is executed. Since the table is locked by the transaction from the first request, which still has work to do, the second add will never return. Additional debugging shows the instances ofJDBCConnectionImpl
are operating over the same context (an EventLoopContext), so they shared the same ordered task queue.In 3.9.x, each
JDBCConnectionImpl
had it's ownTaskQueue
, so operations from different connections were never interleaved.Do you have a reproducer?
It will occur every time with my application code, but I don't have a shareable minimal case.
The text was updated successfully, but these errors were encountered: