GlenGeng commented on a change in pull request #1981:
URL: https://github.com/apache/ozone/pull/1981#discussion_r588065406
##########
File path:
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/server/StorageContainerManager.java
##########
@@ -454,10 +454,11 @@ private void initializeSystemManagers(OzoneConfiguration
conf,
if (configurator.getScmContext() != null) {
scmContext = configurator.getScmContext();
} else {
+ long term = SCMHAUtils.isSCMHAEnabled(conf) ? 0 :
SCMContext.INVALID_TERM;
Review comment:
Good !
Better add a comment here.
```
// When term equals SCMContext.INVALID_TERM, the isLeader() check and
getTermOfLeader() will always pass.
```
----------------------------------------------------------------
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]