-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
HBASE-27795: Define RPC API for cache cleaning #5525
Conversation
b13033d
to
d4baad9
Compare
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
d4baad9
to
f721c7c
Compare
🎊 +1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
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.
What will happen if the region is moved back while we are cleaning its blocks in block cache?
And we only implement the uncache method for BucketCache? What about other types of BlockCache?
* @param server HRegionServer | ||
* @return A map of filename and number of blocks evicted. | ||
*/ | ||
default Optional<Map<String, Integer>> uncacheStaleBlocks(HRegionServer server) { |
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.
I prefer here we pass an interface, for testing whether a region is available, instead of pass a HRegionServer directly. It will be easier for testing.
And just returning a Map is enough? If we do not clean any blocks, just return an empty map?
} else { | ||
blocksEvicted = 0; | ||
} | ||
} catch (NotServingRegionException nsre) { |
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.
Is this the normal path? In the above if condition, we test isAvailable, so why here we could still get a NotServingRegionException?
@Apache9 - Thanks for the review.
Thanks, |
No description provided.