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

Fix deadlock: Break circular lock acquisition #3393

Merged
merged 1 commit into from May 10, 2019

Conversation

@manishrjain
Copy link
Member

commented May 10, 2019

There's a deadlock potential here due to circular lock acquisition. This PR breaks that circle.


This change is Reviewable

…his PR breaks that circle.
@manishrjain manishrjain requested a review from martinmr as a code owner May 10, 2019
@manishrjain manishrjain merged commit a0d966f into master May 10, 2019
3 of 4 checks passed
3 of 4 checks passed
code-review/reviewable 2 files left (martinmr)
Details
Blockade (dgraph) TeamCity build finished
Details
CI (dgraph) TeamCity build finished
Details
license/cla Contributor License Agreement is signed.
Details
@manishrjain manishrjain deleted the mrjn/fix-deadlock branch May 10, 2019
manishrjain added a commit that referenced this pull request May 10, 2019
There's a deadlock potential here due to circular lock acquisition. This PR breaks that circle.
@mehdiym

This comment has been minimized.

Copy link

commented Jun 4, 2019

Hello,
I'm using dGraph 1.0.15 with the go client, and I still have some rare deadlocks.

It doesn't happen with a database running for a long time.

It only happens just after a deep clear of the database (by removing p, w, zw directories) during the first tens/hundreds of queries/mutations.
I can only reproduce it with my test database as I regularly reset it this way.
If I just clear the database with a dropAll alteration, I doesn't happen anymore.

dna2github added a commit to dna2fork/dgraph that referenced this pull request Jul 19, 2019
There's a deadlock potential here due to circular lock acquisition. This PR breaks that circle.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.