-
Notifications
You must be signed in to change notification settings - Fork 32
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
Add nested context descriptions to lock documents #1353
Conversation
Checking the item at the end of the list should be as efficient as inspecting the head of a queue.
...creating a new version
Also add a comment on how it is supposed to work.
…hen..." This reverts commit 8dfd645.
...RepositoryTransactionContext (so no unlock is attempted on a lock that was not granted)
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## 9.x #1353 +/- ##
============================================
- Coverage 64.11% 64.10% -0.01%
- Complexity 12619 12626 +7
============================================
Files 1614 1614
Lines 57269 57333 +64
Branches 5633 5637 +4
============================================
+ Hits 36717 36756 +39
- Misses 18195 18233 +38
+ Partials 2357 2344 -13 ☔ View full report in Codecov by Sentry. |
...anticipation of ImportRequest taking a lock with the same description before the first commit takes place
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.
RSLGTM! with a note
...m.b2international.snowowl.core/src/com/b2international/snowowl/core/locks/OperationLock.java
Show resolved
Hide resolved
...ational.snowowl.core/src/com/b2international/snowowl/core/locks/DatastoreLockIndexEntry.java
Show resolved
Hide resolved
...from older indices if for any reason a lock entry gets stuck
@JsonSetter | ||
Builder parentDescription(final String parentDescription) { | ||
// lock documents with a parentDescription value should propagate their values to contexts | ||
addContext(parentDescription); |
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.
parentDescription
goes first in the list, so a contexts.add(0, parentDescription)
equivalent could be used here. Although whether this is required or not will also depend on the order of the two setter calls.
This is required to track re-entrant locks that go more than two levels deep.