rickyma commented on code in PR #1411:
URL: 
https://github.com/apache/incubator-uniffle/pull/1411#discussion_r1443808405


##########
client-spark/spark3/src/main/java/org/apache/spark/shuffle/DelegationRssShuffleManager.java:
##########
@@ -167,7 +168,7 @@ private boolean tryAccessCluster() {
             "Fail to access cluster {} using {} for {}",
             coordinatorClient.getDesc(),
             accessId,
-            e.getMessage());
+            ExceptionUtils.getStackTrace(e));

Review Comment:
   It will work when I remove the last `{}` in the original log message and use 
`e` which will show a full stacktrace, like below:
   ```
   LOG.warn(
               "Fail to access cluster {} using {} for ",
               coordinatorClient.getDesc(),
               accessId,
               e);
   ```
   
   If I simply change `e.getMessage()` to `e`, it will cause `e` to be treated 
as a string, which will result in the loss of the complete exception stacktrace.
   
   I use `ExceptionUtils.getStackTrace(e)` just for the sake of minimal code 
changes and simplicity. Additionally, I have seen examples in the project where 
`ExceptionUtils.getStackTrace(e)` has been used.
   
   I'll remove the curly braces and use only `e`.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to