Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Load entity data on write after having acquired an exclusive lock
The problem was that multiple threads modifying the same entity could corrupt the data. As an example consider the following case with 2 threads: - both threads load the same node record from disk (having no properties) - first thread grabs the lock first and add a property "a" with value 42 - second thread waiting on the lock - first thread release the lock - second thread add a property "a" with vale 33 to the same node since the second thread thinks there are no properties on the node it adds a new property instead modifying the one already there - there are duplicated properties in the property chain Similar problems happened for writing properties on relationships and adding same labels on nodes.
- Loading branch information
1 parent
3b57dd2
commit 26c903c
Showing
16 changed files
with
812 additions
and
610 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.