mymeiyi commented on a change in pull request #3127:
URL: https://github.com/apache/hbase/pull/3127#discussion_r613965808
##########
File path:
hbase-server/src/main/java/org/apache/hadoop/hbase/quotas/DefaultOperationQuota.java
##########
@@ -122,6 +126,9 @@ public void close() {
@Override
public long getReadAvailable() {
+ if (readAvailable == Long.MAX_VALUE && readCapacityUnitAvailable !=
Long.MAX_VALUE) {
Review comment:
Scan use this value to limit the result size:
` long maxQuotaResultSize = Math.min(maxScannerResultSize,
quota.getReadAvailable());
long maxResultSize;
if (scanner.getMaxResultSize() > 0) {
maxResultSize = Math.min(scanner.getMaxResultSize(),
maxQuotaResultSize);
} else {
maxResultSize = maxQuotaResultSize;
}`
Now it only considers the 'read size' type quota, and if it is not set, the
scan can not be limited. The 'read capacity unit' is also a type of size quota,
we can use it to calculate the available read size.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]