Skip to content

Commit 078119a

Browse files
rmdmattinglyRay Mattingly
authored andcommitted
HBASE-28017 Set request and response size metrics in NettyRpcDuplexHandler (#5473)
Co-authored-by: Ray Mattingly <rmattingly@hubspot.com> Signed-off-by: Duo Zhang <zhangduo@apache.org> Signed-off-by: Bryan Beaudreault <bbeaudreault@apache.org>
1 parent 7ed0dc9 commit 078119a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

hbase-client/src/main/java/org/apache/hadoop/hbase/ipc/NettyRpcDuplexHandler.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ private void writeRequest(ChannelHandlerContext ctx, Call call, ChannelPromise p
110110
} else {
111111
ctx.write(buf, promise);
112112
}
113+
call.callStats.setRequestSizeBytes(totalSize);
113114
}
114115
}
115116

@@ -193,6 +194,7 @@ private void readResponse(ChannelHandlerContext ctx, ByteBuf buf) throws IOExcep
193194
}
194195
return;
195196
}
197+
call.callStats.setResponseSizeBytes(totalSize);
196198
if (remoteExc != null) {
197199
call.setException(remoteExc);
198200
return;

0 commit comments

Comments
 (0)