You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "michaeljmarshall (via GitHub)" <gi...@apache.org> on 2023/02/22 20:16:19 UTC

[GitHub] [pulsar] michaeljmarshall commented on a diff in pull request #19593: [improve] Print stack trace when got excpetion in ServerCnx

michaeljmarshall commented on code in PR #19593:
URL: https://github.com/apache/pulsar/pull/19593#discussion_r1114909669


##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java:
##########
@@ -397,7 +397,7 @@ public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) throws E
             // At default info level, suppress all subsequent exceptions that are thrown when the connection has already
             // failed
             if (log.isDebugEnabled()) {
-                log.debug("[{}] Got exception: {}", remoteAddress, cause);
+                log.debug("[{}] Got exception: {}", remoteAddress, cause.getMessage(), cause);

Review Comment:
   Is it worth using `ClientCnx.isKnownException(cause) ? cause : ExceptionUtils.getStackTrace(cause)` link we do on line 391?



-- 
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: commits-unsubscribe@pulsar.apache.org

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