You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "mladjan-gadzic (via GitHub)" <gi...@apache.org> on 2023/04/20 13:36:03 UTC
[GitHub] [ozone] mladjan-gadzic opened a new pull request, #4598: HDDS-8017. Add check in ClosingContainerHandler for RM to handle Missing Containers
mladjan-gadzic opened a new pull request, #4598:
URL: https://github.com/apache/ozone/pull/4598
## What changes were proposed in this pull request?
Containers in `CLOSING` state are added to `MISSING`, `UNDER_REPLICATED` and `MIS_REPLICATED` state as well.
## What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-8017
## How was this patch tested?
- unit tests
- manual tests
Steps for manual tests:
- Set property `hdds.scm.replication.enable.legacy` to `false`
- Start ozone dev cluster with 3DNs
- Generate keys via `ozone freon rk --numOfKeys=10 --numOfBuckets=10 --type=RATIS --replication=ONE` command
- Check there are 3 containers in `OPEN` state using `ozone admin container report`
- Stop two DNs
- Check there is 1 container in `OPEN` state, 2 in `CLOSING`, 2 in `MIS_REPLICATED`, 2 in `MISSING` and 2 in `UNDER_REPLICATED` state using `ozone admin container report`.
--
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: issues-unsubscribe@ozone.apache.org
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
[GitHub] [ozone] sodonnel commented on a diff in pull request #4598: HDDS-8017. Add check in ClosingContainerHandler for RM to handle Missing Containers
Posted by "sodonnel (via GitHub)" <gi...@apache.org>.
sodonnel commented on code in PR #4598:
URL: https://github.com/apache/ozone/pull/4598#discussion_r1172752404
##########
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/replication/ReplicationManager.java:
##########
@@ -922,6 +923,27 @@ protected void processContainer(ContainerInfo containerInfo,
}
}
+ /**
+ * Increments and samples health states for container when there are no
+ * replicas.
+ * @param replicas The replicas for which size is checked.
+ * @param containerInfo The container info used to retrieve container id.
+ * @param report The report which is incremented and sampled
+ */
+ public void setHealthStateForClosing(Set<ContainerReplica> replicas,
Review Comment:
I don't think we really need this method in the RM class - its fine to just to this inline in the closing handler.
--
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: issues-unsubscribe@ozone.apache.org
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
[GitHub] [ozone] sodonnel commented on a diff in pull request #4598: HDDS-8017. Add check in ClosingContainerHandler for RM to handle Missing Containers
Posted by "sodonnel (via GitHub)" <gi...@apache.org>.
sodonnel commented on code in PR #4598:
URL: https://github.com/apache/ozone/pull/4598#discussion_r1172746780
##########
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/replication/ReplicationManager.java:
##########
@@ -922,6 +923,27 @@ protected void processContainer(ContainerInfo containerInfo,
}
}
+ /**
+ * Increments and samples health states for container when there are no
+ * replicas.
+ * @param replicas The replicas for which size is checked.
+ * @param containerInfo The container info used to retrieve container id.
+ * @param report The report which is incremented and sampled
+ */
+ public void setHealthStateForClosing(Set<ContainerReplica> replicas,
+ ContainerInfo containerInfo,
+ ReplicationManagerReport report) {
+ if (replicas.size() != 0) {
+ return;
+ }
+
+ report.incrementAndSample(HealthState.MISSING, containerInfo.containerID());
+ report.incrementAndSample(HealthState.UNDER_REPLICATED,
Review Comment:
In the "new" RM, we are keeping to having a single state for a container to be in, so in this case, the container would be MISSING only, and we don't increment under or mis-replicated.
--
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: issues-unsubscribe@ozone.apache.org
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
[GitHub] [ozone] sodonnel merged pull request #4598: HDDS-8017. Add check in ClosingContainerHandler for RM to handle Missing Containers
Posted by "sodonnel (via GitHub)" <gi...@apache.org>.
sodonnel merged PR #4598:
URL: https://github.com/apache/ozone/pull/4598
--
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: issues-unsubscribe@ozone.apache.org
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
[GitHub] [ozone] mladjan-gadzic commented on pull request #4598: HDDS-8017. Add check in ClosingContainerHandler for RM to handle Missing Containers
Posted by "mladjan-gadzic (via GitHub)" <gi...@apache.org>.
mladjan-gadzic commented on PR #4598:
URL: https://github.com/apache/ozone/pull/4598#issuecomment-1517025021
@sodonnel Thanks for the review! I adressed all the comments.
--
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: issues-unsubscribe@ozone.apache.org
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