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

Reduce redundant stat calls when statting by resource ID #2208

Merged
merged 2 commits into from
Oct 28, 2021

Conversation

ishank011
Copy link
Contributor

@ishank011 ishank011 commented Oct 26, 2021

We were making multiple redundant stat calls, especially when looking up resources by ID.

For example, in the gateway, we'd call getPath which would stat the ID, and then after performing a few checks on the returned path, call stat again; similarly in EOS FS.

This PR brings down the number of such calls from 4 to 1 (for EOS fs) and for the other file systems, by at least a factor of half.

This is a start towards such performance improvements, I'll keep on working on these.

@labkode labkode marked this pull request as ready for review October 26, 2021 13:38
@labkode labkode self-requested a review as a code owner October 26, 2021 13:38
@ishank011 ishank011 force-pushed the reduce-redundant-stat-calls branch from 745348a to a4bd025 Compare October 26, 2021 13:39
labkode
labkode previously approved these changes Oct 26, 2021
@ishank011 ishank011 force-pushed the reduce-redundant-stat-calls branch from 65aebc8 to ec038fd Compare October 26, 2021 14:11
@labkode labkode self-requested a review October 28, 2021 14:41
@labkode labkode merged commit 4157eed into cs3org:master Oct 28, 2021
@ishank011 ishank011 deleted the reduce-redundant-stat-calls branch October 28, 2021 14:54
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