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

Further improve lock contention #3397

Merged
merged 4 commits into from
Nov 8, 2022

Conversation

aduffeck
Copy link
Contributor

@aduffeck aduffeck commented Oct 26, 2022

This PR reduces lock contention by adding a xattr write-through cache for nodes.

The cache functions as a request-level xattr cache and reduces the number of *xattr syscalls being made.

@aduffeck aduffeck force-pushed the improve-lock-contention2 branch 4 times, most recently from db18fb5 to bf4a13e Compare October 28, 2022 09:35
@aduffeck aduffeck force-pushed the improve-lock-contention2 branch 7 times, most recently from 2e5e45f to 5a6a954 Compare November 7, 2022 08:21
The cache functions as a request-level xattr cache and reduces the
number of *xattr syscalls being made.
@aduffeck aduffeck changed the title [tests-only] WIP: Improve lock contention Further improve lock contention Nov 7, 2022
@aduffeck aduffeck marked this pull request as ready for review November 7, 2022 09:22
Copy link
Contributor

@kobergj kobergj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice 👍 Just some clarification needed

pkg/storage/utils/decomposedfs/node/xattrs.go Show resolved Hide resolved
pkg/storage/utils/decomposedfs/node/node.go Outdated Show resolved Hide resolved
pkg/storage/utils/filelocks/filelocks.go Show resolved Hide resolved
Comment on lines -985 to -987
if xattrs.IsAttrUnset(err) {
return nil
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This attrunset check is also removed. Not sure if this is critical

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This error is only logged further up the stack, and it shouldn't occur in the first place.

@aduffeck aduffeck merged commit 819c40f into cs3org:edge Nov 8, 2022
@aduffeck aduffeck deleted the improve-lock-contention2 branch November 8, 2022 09:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants