You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by GitBox <gi...@apache.org> on 2021/05/10 12:19:56 UTC

[GitHub] [ozone] GlenGeng commented on a change in pull request #2227: HDDS-5200. Fix scm roles command if one of the host is unresolvable.

GlenGeng commented on a change in pull request #2227:
URL: https://github.com/apache/ozone/pull/2227#discussion_r629311256



##########
File path: hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/protocol/ScmBlockLocationProtocolServerSideTranslatorPB.java
##########
@@ -104,7 +104,7 @@ public ScmBlockLocationProtocolServerSideTranslatorPB(
   @Override
   public SCMBlockLocationResponse send(RpcController controller,
       SCMBlockLocationRequest request) throws ServiceException {
-    if (!scm.getScmContext().isLeader()) {
+    if (!scm.checkLeader()) {

Review comment:
       How about move the `StorageContainerManager#checkLeader` into `SCMContext`? The latter is used to hold all kinds of global state of SCM. We can handle this in a new jira.




-- 
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org