szetszwo commented on code in PR #5226:
URL: https://github.com/apache/ozone/pull/5226#discussion_r1309271116
##########
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/IncrementalContainerReportHandler.java:
##########
@@ -108,9 +108,14 @@ public void onMessage(final
IncrementalContainerReportFromDatanode report,
} catch (ContainerReplicaNotFoundException e) {
LOG.warn("Container {} replica not found!",
replicaProto.getContainerID());
- } catch (NotLeaderException nle) {
- LOG.warn("Failed to process " + replicaProto.getState()
- + " Container " + id + " due to " + nle);
+ } catch (SCMException ex) {
+ if (ex.getResult() == SCMException.ResultCodes.SCM_NOT_LEADER) {
+ LOG.warn("Failed to process {} container {}",
+ replicaProto.getState(), id, ex);
Review Comment:
@ashishkumar50 , thanks for working on this!
Please print only the exception message but not the stack trace. #4302 was
to avoid printing the stack trace.
--
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]