mukul1987 commented on a change in pull request #2731:
URL: https://github.com/apache/ozone/pull/2731#discussion_r726685693
##########
File path:
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/ha/SCMRatisRequest.java
##########
@@ -139,4 +145,22 @@ public static SCMRatisRequest decode(Message message)
method.getName(), parameterTypes, args.toArray());
}
+ /**
+ * Convert StateMachineLogEntryProto to String.
+ * @param proto - {@link StateMachineLogEntryProto}
+ * @return String
+ */
+ public static String smProtoToString(StateMachineLogEntryProto proto) {
+ StringBuilder builder = new StringBuilder();
+ try {
+ builder.append(TextFormat.shortDebugString(
+ SCMRatisRequestProto.parseFrom(proto.getLogData().toByteArray())));
+ } catch (Throwable ex) {
+ LOG.info("smProtoToString failed", ex);
Review comment:
LOG.error here ?
--
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]