private void checkQuota(long numWrites, long numReads, boolean isAtomic)
    throws RpcThrottlingException {
    if (isAtomic) {
      // Remember this flag for later use in close()
      this.isAtomic = true;
    }
    readAvailable = Long.MAX_VALUE;
    for (final QuotaLimiter limiter : limiters) {
      if (limiter.isBypass()) {
        continue;
      }

      long maxRequestsToEstimate = limiter.getRequestNumLimit();
      long maxReadsToEstimate = Math.min(maxRequestsToEstimate, limiter.getReadNumLimit());
      long maxWritesToEstimate = Math.min(maxRequestsToEstimate, limiter.getWriteNumLimit());
      long maxReadSizeToEstimate = Math.min(readConsumed, limiter.getReadLimit());
      long maxWriteSizeToEstimate = Math.min(writeConsumed, limiter.getWriteLimit());

      limiter.checkQuota(Math.min(maxWritesToEstimate, numWrites),
        Math.min(maxWriteSizeToEstimate, writeConsumed), Math.min(maxReadsToEstimate, numReads),
        Math.min(maxReadSizeToEstimate, readConsumed), writeCapacityUnitConsumed,
        readCapacityUnitConsumed, isAtomic, handlerUsageTimeConsumed);
      readAvailable = Math.min(readAvailable, limiter.getReadAvailable());
    }

    for (final QuotaLimiter limiter : limiters) {
      limiter.grabQuota(numWrites, writeConsumed, numReads, readConsumed, writeCapacityUnitConsumed,
        readCapacityUnitConsumed, isAtomic, handlerUsageTimeConsumed);
    }
  }
NOTE: The order matters. It should be something like [user, table, namespace, global]
hbase-server/src/main/java/org/apache/hadoop/hbase/quotas/DefaultOperationQuota.java