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

fix: add VolumeStats cache to avoid massive statfs calls #1438

Merged
merged 1 commit into from
Sep 13, 2023

Conversation

andyzhangx
Copy link
Member

@andyzhangx andyzhangx commented Sep 9, 2023

What type of PR is this?
/kind bug

What this PR does / why we need it:
fix: add VolumeStats cache to avoid massive statfs calls

This PR adds a 10min cache for VolumeStats per volumeID, that could avoid massive statfs calls

Which issue(s) this PR fixes:

Fixes #

Requirements:

Special notes for your reviewer:

Release note:

fix: add VolumeStats cache to avoid massive statfs calls

@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. kind/bug Categorizes issue or PR as related to a bug. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Sep 9, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: andyzhangx

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 9, 2023
@andyzhangx andyzhangx removed the request for review from cvvz September 9, 2023 09:41
@andyzhangx
Copy link
Member Author

/retest

@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Sep 11, 2023
@andyzhangx
Copy link
Member Author

/retest

@andyzhangx andyzhangx changed the title [WIP] fix: add VolumeStats cache to avoid massive statfs calls fix: add VolumeStats cache to avoid massive statfs calls Sep 12, 2023
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Sep 12, 2023
@andyzhangx
Copy link
Member Author

/retest

3 similar comments
@andyzhangx
Copy link
Member Author

/retest

@andyzhangx
Copy link
Member Author

/retest

@andyzhangx
Copy link
Member Author

/retest

chore: change log level

add flag

fix: avoid GetVolumeStats twice when only subPath differs

fix log level

revert
@andyzhangx
Copy link
Member Author

/retest

1 similar comment
@andyzhangx
Copy link
Member Author

/retest

@andyzhangx andyzhangx merged commit 34e07f3 into master Sep 13, 2023
16 checks passed
@andyzhangx
Copy link
Member Author

/cherrypick release-1.28

@k8s-infra-cherrypick-robot

@andyzhangx: new pull request created: #1439

In response to this:

/cherrypick release-1.28

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@andyzhangx
Copy link
Member Author

/cherrypick release-1.27

@k8s-infra-cherrypick-robot

@andyzhangx: #1438 failed to apply on top of branch "release-1.27":

Applying: fix: add VolumeStats cache to avoid massive statfs calls
Using index info to reconstruct a base tree...
M	pkg/azurefile/azurefile.go
M	pkg/azurefile/nodeserver.go
M	pkg/azurefileplugin/main.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/azurefileplugin/main.go
Auto-merging pkg/azurefile/nodeserver.go
CONFLICT (content): Merge conflict in pkg/azurefile/nodeserver.go
Auto-merging pkg/azurefile/azurefile.go
CONFLICT (content): Merge conflict in pkg/azurefile/azurefile.go
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0001 fix: add VolumeStats cache to avoid massive statfs calls
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".

In response to this:

/cherrypick release-1.27

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/bug Categorizes issue or PR as related to a bug. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants