bharathv commented on a change in pull request #754: HBASE-22978 : Online slow
response log
URL: https://github.com/apache/hbase/pull/754#discussion_r382237148
##########
File path:
hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/RpcServer.java
##########
@@ -403,13 +419,14 @@ public void setSecretManager(SecretManager<? extends
TokenIdentifier> secretMana
boolean tooSlow = (processingTime > warnResponseTime && warnResponseTime
> -1);
boolean tooLarge = (responseSize > warnResponseSize && warnResponseSize
> -1);
if (tooSlow || tooLarge) {
+ final String userName =
call.getRequestUserName().orElse(StringUtils.EMPTY);
// when tagging, we let TooLarge trump TooSmall to keep output simple
// note that large responses will often also be slow.
logResponse(param,
Review comment:
Can you refactor all of this? Most content can be inferred from the "param"
and "call".. So the signature should be something like logResponses(param,
call)... Too much clutter and too many variables being passed around.. If
possible also move the metrics updation and trace logging into this method.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services