bbeaudreault commented on code in PR #6066: URL: https://github.com/apache/hbase/pull/6066#discussion_r1683419563
########## hbase-server/src/main/java/org/apache/hadoop/hbase/coprocessor/RegionCoprocessorEnvironment.java: ########## @@ -26,12 +27,18 @@ import org.apache.hadoop.hbase.ServerName; import org.apache.hadoop.hbase.client.Connection; import org.apache.hadoop.hbase.client.RegionInfo; +import org.apache.hadoop.hbase.client.Scan; import org.apache.hadoop.hbase.metrics.MetricRegistry; +import org.apache.hadoop.hbase.quotas.OperationQuota; +import org.apache.hadoop.hbase.quotas.RpcQuotaManager; +import org.apache.hadoop.hbase.quotas.RpcThrottlingException; import org.apache.hadoop.hbase.regionserver.OnlineRegions; import org.apache.hadoop.hbase.regionserver.Region; import org.apache.yetus.audience.InterfaceAudience; import org.apache.yetus.audience.InterfaceStability; +import org.apache.hadoop.hbase.shaded.protobuf.generated.ClientProtos; Review Comment: According to the ref guide: > In HBase 3.0.0, the hbase-protocol module has been purged, the CPEP implementation should use the protos in hbase-protocol-shaded module, and also make use of the shaded protobuf in hbase-thirdparty. I also think I remember Andrew saying that our protos are LimitedPrivate (but cant find that in the refguid). If you look at MultiRowMutationEndpoint in branch-3, it has access to `org.apache.hadoop.hbase.shaded.protobuf.generated.ClientProtos` So it seems like it should be ok to expose it in master/branch-3. I think in branch-2 it might be more tricky. MultiRowMutationEndpoint only has access to _unshaded_ protobuf there, so it wouldn't translate into the server internals which use _shaded_. One option here would be to not expose checkBatchQuota with ClientProtos.Action as an argument. The implementation of that method on the server side actually just iterates the batch to count the reads and writes, then calls a different checkBatchQuota that takes those two ints. We could expose something like `checkBatchQuota(region, int reads, int writes)`. -- 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]
