-
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-26122: Implement an optional maximum size for Gets, after which a partial result is returned #3565
Conversation
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
941bbfc
to
4adafe7
Compare
🎊 +1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
4adafe7
to
3fd01e6
Compare
🎊 +1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
3fd01e6
to
2b20954
Compare
🎊 +1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
Want to make this same as the branch-2 pushed PR @bbeaudreault and then I'll commit (I couldn't forward port the branch-2 PR w/o conflict. |
… a partial result is returned
2b20954
to
ed5d846
Compare
@saintstack I updated the PR to include the change from branch-2. Also see #3576, with an addendum for branch-2 |
💔 -1 overall
This message was automatically generated. |
💔 -1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
🎊 +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.
This PR seems to be doing the suggestion I made of not making a scanner context unless 'needed' (But you found out that we make a scanner context always so my suggestion was of no use). This PR needs updating @bbeaudreault ? Thanks.
Hey @saintstack, sorry I've been distracted by internal stuff the last few work days. But will be getting back to this this week. Yes, this PR needs to be updated based on our convo in the other PR. |
Do we really need to add such complexity to Gets? |
Thank you for your comment Anoop. The problem we face is that we have hundreds of engineers using hbase in innumerable ways, on multi-tenant clusters. People shift teams, leave, get hired, etc. When you set out to read a row from hbase, you don't always know how large that row will be. Yes I agree with you, if someone knew they were going to fetch a large row, they should do a Scan. But given the above, people often don't. This new feature acts as a guardrail against causing RegionServer pain in those cases. The way we've used this feature is we have our own TableFactory that everyone must use to get tables. The returned Table objects are wrapped. When a Get is submitted, the wrapper uses this to limit the max result size. When data is returned, we inspect the Result and throw an exception if it's a partial result. At that point the user can rewrite their query to use a Scan or add a filter, etc. We also have an escape hatch for urgent issues to allow them to go through, but that is audited. That said, I just noticed |
Given the above and the fact that changes are needed here anyway, I'm going to close this for now while we investigate setting |
This is a version of #3532 which applies against master branch. When I created the previous PR I didn't realize the convention of doing master first. That PR did not cleanly apply to master due to changes in hbase-protocol vs hbase-protocol-shaded and minor differences in HRegion.