-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
dont set n.ops map entries to nil. Instead just delete them #5551
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The change looks good but can we please add a test for this? I understand we don't have any tests for it currently but without tests it's very hard to determine if we've fixed the issue or not.
Reviewable status: 0 of 1 files reviewed, all discussions resolved (waiting on @manishrjain and @vvbalaji-dgraph)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r1.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @manishrjain, @parasssh, and @vvbalaji-dgraph)
worker/draft.go, line 140 at r1 (raw file):
return nil, errors.Errorf("another restore operation is already running") } // remove from map and signal the closer to cancel the operation.
minor: uppercase
worker/draft.go, line 147 at r1 (raw file):
for otherId, otherCloser := range n.ops { if otherId == opRollup { // remove from map and signal the closer to cancel the operation.
minor: uppercase
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @manishrjain, @parasssh, and @vvbalaji-dgraph)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had a chat with @parasssh and we concluded that adding test isn't straight forward.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @manishrjain, @parasssh, and @vvbalaji-dgraph)
dont set n.ops map entries to nil. Instead just delete them (#5551) A panic was caused because n.ops map entry was set to nil in some cases. Fix is to not set n.ops map entries to nil. Instead, just delete them. Fixed DGRAPH-1573
…einc#5551) A panic was caused because n.ops map entry was set to nil in some cases. Fix is to not set n.ops map entries to nil. Instead, just delete them. Fixed DGRAPH-1573
A panic was caused because n.ops map entry was set to nil in some cases.
Fix is to not set n.ops map entries to nil. Instead, just delete them.
Fixed DGRAPH-1573
This change is