-
Notifications
You must be signed in to change notification settings - Fork 439
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
Warn on md-prefetch enabled w/o md-cache #1944
base: master
Are you sure you want to change the base?
Warn on md-prefetch enabled w/o md-cache #1944
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1944 +/- ##
==========================================
+ Coverage 60.76% 60.78% +0.01%
==========================================
Files 130 130
Lines 12397 12415 +18
==========================================
+ Hits 7533 7546 +13
- Misses 4526 4531 +5
Partials 338 338
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
1b785ca
to
e7bbd0a
Compare
} | ||
|
||
func isTypeCacheEnabled(metadataCacheTTL time.Duration, typeCacheMaxSizeMB int) bool { | ||
if metadataCacheTTL <= 0 || typeCacheMaxSizeMB == 0 || typeCacheMaxSizeMB < -1 { |
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.
check if typeCacheMaxSizeMB < -1
is required or not. if not why and if yes why.
return true | ||
} | ||
|
||
func isStatCacheEnabled(metadataCacheTTL time.Duration, statCacheMaxSizeMB uint64) bool { |
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.
should we add these helper methods and their test cases somewhere apt inside internal
directory ? trying to keep main.go clean.
Description
Warn on md-prefetch enabled w/o md-cache
In other words, log warnings if user has enabled metadata-prefetch through
metadata-prefetch-on-mount
flag but has either the type-cache or the stat-cache disabled through their ttl or size.This is on top of #1930
Link to the issue in case of a bug fix.
NA
Testing details