This is an automated email from the ASF dual-hosted git repository.

bbeaudreault pushed a commit to branch branch-2
in repository https://gitbox.apache.org/repos/asf/hbase.git


The following commit(s) were added to refs/heads/branch-2 by this push:
     new 078119a0680 HBASE-28017 Set request and response size metrics in 
NettyRpcDuplexHandler (#5473)
078119a0680 is described below

commit 078119a068041f1e4224a834f935f9da9e9210f9
Author: Ray Mattingly <rmdmattin...@gmail.com>
AuthorDate: Tue Oct 24 10:25:31 2023 -0400

    HBASE-28017 Set request and response size metrics in NettyRpcDuplexHandler 
(#5473)
    
    Co-authored-by: Ray Mattingly <rmattin...@hubspot.com>
    Signed-off-by: Duo Zhang <zhang...@apache.org>
    Signed-off-by: Bryan Beaudreault <bbeaudrea...@apache.org>
---
 .../main/java/org/apache/hadoop/hbase/ipc/NettyRpcDuplexHandler.java    | 2 ++
 1 file changed, 2 insertions(+)

diff --git 
a/hbase-client/src/main/java/org/apache/hadoop/hbase/ipc/NettyRpcDuplexHandler.java
 
b/hbase-client/src/main/java/org/apache/hadoop/hbase/ipc/NettyRpcDuplexHandler.java
index 47b0b29a5c6..ad8c51568a3 100644
--- 
a/hbase-client/src/main/java/org/apache/hadoop/hbase/ipc/NettyRpcDuplexHandler.java
+++ 
b/hbase-client/src/main/java/org/apache/hadoop/hbase/ipc/NettyRpcDuplexHandler.java
@@ -110,6 +110,7 @@ class NettyRpcDuplexHandler extends ChannelDuplexHandler {
       } else {
         ctx.write(buf, promise);
       }
+      call.callStats.setRequestSizeBytes(totalSize);
     }
   }
 
@@ -193,6 +194,7 @@ class NettyRpcDuplexHandler extends ChannelDuplexHandler {
       }
       return;
     }
+    call.callStats.setResponseSizeBytes(totalSize);
     if (remoteExc != null) {
       call.setException(remoteExc);
       return;

Reply via email to