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

core: Use SyncContext for InProcessTransport listener callbacks to avoid deadlocks #9319

Merged
merged 1 commit into from Jun 30, 2022

Conversation

larry-safran
Copy link
Contributor

@larry-safran larry-safran commented Jun 28, 2022

Fixes deadlocks caused by client and server listeners being called in a synchronized block

Also support unary calls returning null values

Fixes #3084

@ejona86
Copy link
Member

ejona86 commented Jun 28, 2022

The "Fixes bug #3084" is normally just included in the commit/PR description, not the title. And we use "Fixes #3084" syntax so github auto-links the PR to the issue. See #9300 for an example.

@larry-safran larry-safran changed the title [core] Use SyncContext for InProcessTransport listener callbacks to avoid deadlocks (Fixes bug #3084) core: Use SyncContext for InProcessTransport listener callbacks to avoid deadlocks (Fixes bug #3084) Jun 28, 2022
@larry-safran larry-safran changed the title core: Use SyncContext for InProcessTransport listener callbacks to avoid deadlocks (Fixes bug #3084) core: Use SyncContext for InProcessTransport listener callbacks to avoid deadlocks Jun 28, 2022
…void deadlocks

Fixes grpc#3084
Also support unary calls returning null values
@ejona86 ejona86 merged commit 74137b0 into grpc:master Jun 30, 2022
@ejona86 ejona86 added the TODO:backport PR needs to be backported. Removed after backport complete label Jun 30, 2022
@larry-safran larry-safran deleted the fix-3084 branch July 7, 2022 17:44
@YifeiZhuang
Copy link
Contributor

Hi @larry-safran @ejona86 do we still want to back port this change?

@larry-safran larry-safran removed the TODO:backport PR needs to be backported. Removed after backport complete label Jul 11, 2022
@larry-safran
Copy link
Contributor Author

larry-safran commented Jul 11, 2022 via email

copybara-service bot pushed a commit to bazelbuild/bazel that referenced this pull request Sep 20, 2022
These tests verify corner cases in the bidirectional BES protocol and had
been relying on the in-process gRPC transport with direct execution to
correctly use concurrency primitives. Since the inprocess gRPC transport
was changed in grpc/grpc-java#9319 these tests
are no longer correct and need to be carefully updated to match the new
inprocess gRPC threading model. Updating the tests will take long enough
that temporarily ignoring the tests will meaningfully reduce CI flakes.

PiperOrigin-RevId: 475617300
Change-Id: Ibf27e10b433030ede29fe0587315fbad1a76dbe0
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Potential deadlock due to calling callbacks while holding a lock
3 participants