-
Notifications
You must be signed in to change notification settings - Fork 469
feat(buffered reader default ON): Reuse read handle to optimize reader creation #4086
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
base: master
Are you sure you want to change the base?
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #4086 +/- ##
===========================================
+ Coverage 0 83.26% +83.26%
===========================================
Files 0 153 +153
Lines 0 18612 +18612
===========================================
+ Hits 0 15498 +15498
- Misses 0 2544 +2544
- Partials 0 570 +570
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
| defaultPrefetchMultiplier = 2 | ||
| ReadOp = "readOp" | ||
| readOp = "readOp" | ||
| readHandleValidity = 5 * time.Minute // source go/gcsfuse-zonal-buckets-read-design-doc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you please confirm, if this expiry time is client specific? Or server maintains a shared handle and refresh every 5 mins?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Expiry time is based on per buffered Reader instance. I couldn't find any resources apart from it's mention in the source go/gcsfuse-zonal-buckets-read-design-doc
8d3531c to
a14299c
Compare
Description
This pull request introduces a mechanism to reuse GCS read handles within the BufferedReader. By reusing the read handle, we can optimize the creation of subsequent GCS readers for the same GCS object, which is particularly beneficial for zonal buckets as it can bypass authorization and metadata checks.
Changes
Performance
Sequential Reads on RAPID
Master: upto 4.2 GB/sec
PR: upto 4.5 GB/sec
New Reader Creation
Master (AVG: 22ms):

PR (AVG: 15ms):

Link to the issue in case of a bug fix.
Testing details
Any backward incompatible change? If so, please explain.