Skip to content
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

Batch.execute() Serializes Statement Execution #15

Merged
merged 3 commits into from
Apr 13, 2021

Conversation

Michael-A-McMahon
Copy link
Member

Fix for Issue #5
It is now required to fully-consume each Result emitted by Oracle R2DBC's Batch.execute() Publisher. The Publisher does not emit the next Result until the update count or row data of a previous Result has been consumed.
This ensures that a Statement will never be executed while the row data of a Result is being consumed concurrently. Concurrent database operations lead to blocked threads, which may lead to a deadlock, as described in Issue #5.

Copy link
Member

@jeandelavarene jeandelavarene left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

src/main/java/oracle/r2dbc/impl/OracleStatementImpl.java Outdated Show resolved Hide resolved
src/main/java/oracle/r2dbc/impl/OracleStatementImpl.java Outdated Show resolved Hide resolved
Michael-A-McMahon and others added 2 commits March 17, 2021 17:05
Fix typo

Co-authored-by: Jean de Lavarene <jean.de.lavarene@oracle.com>
Fix typo

Co-authored-by: Jean de Lavarene <jean.de.lavarene@oracle.com>
@jeandelavarene jeandelavarene merged commit 3f9a3f9 into main Apr 13, 2021
@jeandelavarene jeandelavarene deleted the 5-serialized-batch-results branch April 13, 2021 09:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deadlock results from Batch.execute()
3 participants