You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As suggested in this thread, there might be room for improvements in the locking scheme implemented in #15:
Since the modification of the directory resource happens atomically when actually adding/removing a child, it might be worth trying to only get a shared read lock on a directory when adding or removing children. This is more of a eventual consistency model. I.e. a concurrent directory listing will be undefined.
When creating, deleting or moving a directory, we still need an exclusive write lock on that directory. During that time no read lock can be obtained, thus modifications to ancestors will not be possible.
Todo
profile application while adding a single large directory (deeply nested)
decide whether lock contention can be reduced on directory locks
(optionally) only "read-lock" directories when adding or removing children
The text was updated successfully, but these errors were encountered:
I added a directory a/b/c/d/e containing 500 4-byte-files. The work was done by 5 FUSE threads, all behaving similar. We see that the actual locking isn't taking much time, but the recursion does:
overheadhunter
changed the title
Reduce lock contention during bulk operations
Speed up lock manager during bulk operations
Mar 26, 2019
As suggested in this thread, there might be room for improvements in the locking scheme implemented in #15:
Since the modification of the directory resource happens atomically when actually adding/removing a child, it might be worth trying to only get a shared read lock on a directory when adding or removing children. This is more of a eventual consistency model. I.e. a concurrent directory listing will be undefined.
When creating, deleting or moving a directory, we still need an exclusive write lock on that directory. During that time no read lock can be obtained, thus modifications to ancestors will not be possible.
Todo
(optionally) only "read-lock" directories when adding or removing childrenThe text was updated successfully, but these errors were encountered: