bbeaudreault commented on code in PR #5654:
URL: https://github.com/apache/hbase/pull/5654#discussion_r1476808209


##########
hbase-server/src/main/java/org/apache/hadoop/hbase/quotas/DefaultOperationQuota.java:
##########
@@ -139,9 +156,16 @@ public void addMutation(final Mutation mutation) {
    * @param numScans  the number of scan requests
    */
   protected void updateEstimateConsumeQuota(int numWrites, int numReads, int 
numScans) {
-    writeConsumed = estimateConsume(OperationType.MUTATE, numWrites, 100);
-    readConsumed = estimateConsume(OperationType.GET, numReads, 100);
-    readConsumed += estimateConsume(OperationType.SCAN, numScans, 1000);
+    if (useBlockBytesScanned) {
+      writeConsumed = estimateConsume(OperationType.MUTATE, numWrites, 100);

Review Comment:
   this is a nit, but can you move the writeConsumed out of the if blocks so we 
don't duplicate?



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to