anuengineer commented on a change in pull request #521: HDDS-2592 Add Datanode
command to allow the datanode to persist its admin state
URL: https://github.com/apache/hadoop-ozone/pull/521#discussion_r374856136
##########
File path:
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/common/helpers/DatanodeIdYaml.java
##########
@@ -105,6 +112,8 @@ public static DatanodeDetails readDatanodeIdFile(File path)
private String ipAddress;
private String hostName;
private String certSerialId;
+ private String persistedOpState;
+ private long persistedOpStateExpiryEpochSec = 0;
Review comment:
Since zero is the default value for the long, would it make sense to enforce
time; that is for each set command we need an explicit time. In that case, we
can define a constant called INFINITY and set it to something like -1; but in
the source, it will be very explicit when someone reads code, and in the
command handler we can enforce the requirement (or perhaps better on the SCM
side). So commands like decommission will have an infinite value explicitly set
by SCM and it would be more obvious and explicit.
----------------------------------------------------------------
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
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]