zhuyaogai commented on code in PR #5228:
URL: https://github.com/apache/hbase/pull/5228#discussion_r1323047115


##########
hbase-client/src/main/java/org/apache/hadoop/hbase/client/ConnectionUtils.java:
##########
@@ -196,13 +196,17 @@ static boolean isEmptyStopRow(byte[] row) {
     return Bytes.equals(row, EMPTY_END_ROW);
   }
 
-  static void resetController(HBaseRpcController controller, long timeoutNs, 
int priority) {
+  static void resetController(HBaseRpcController controller, long timeoutNs, 
int priority,
+    TableName tableName) {
     controller.reset();
     if (timeoutNs >= 0) {
       controller.setCallTimeout(
         (int) Math.min(Integer.MAX_VALUE, 
TimeUnit.NANOSECONDS.toMillis(timeoutNs)));
     }
     controller.setPriority(priority);
+    if (tableName != null) {
+      controller.setTableName(tableName);

Review Comment:
   @bbeaudreault hi, thanks for your suggestion, but actually I have a 
question. Is it possible for the table name to initially not be null, but later 
become null due to controller re-used? Or in other words, can the table name 
change for the same `RpcRetryingCaller`?  And I took a quick look at the code, 
and it seems that when the table name is null, it won't hit the 
`Get/Mutate/Scan/Multi`(ClientService) switch cases in the 
`MetricsConnection#updateRpc` method. Okay, I will reset the table name in the 
controller.reset() method, and keep everything else as it is. What do you think?



-- 
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: issues-unsubscr...@hbase.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to