avijayanhwx commented on a change in pull request #2874:
URL: https://github.com/apache/ozone/pull/2874#discussion_r763222852
##########
File path:
hadoop-ozone/recon/src/main/java/org/apache/hadoop/ozone/recon/persistence/ContainerHealthSchemaManager.java
##########
@@ -69,8 +71,14 @@ public ContainerHealthSchemaManager(
SelectQuery<Record> query = dslContext.selectQuery();
query.addFrom(UNHEALTHY_CONTAINERS);
if (state != null) {
- query.addConditions(
- UNHEALTHY_CONTAINERS.CONTAINER_STATE.eq(state.toString()));
+ if (state.equals(ALL_REPLICAS_UNHEALTHY)) {
+ query.addConditions(UNHEALTHY_CONTAINERS.CONTAINER_STATE
+ .eq(UNDER_REPLICATED.toString()));
+ query.addConditions(UNHEALTHY_CONTAINERS.ACTUAL_REPLICA_COUNT.eq(0));
Review comment:
ACTUAL_REPLICA_COUNT can be 0 / 1 / 2. All of the count as
UNDER_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: [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]