sodonnel opened a new pull request, #4144:
URL: https://github.com/apache/ozone/pull/4144
## What changes were proposed in this pull request?
MisReplicationHandler#filterSources gets a Set of replicas that can be used
to fix mis replication. It selects CLOSED replicas:
```
private Set<ContainerReplica> filterSources(Set<ContainerReplica>
replicas) {
return replicas.stream().filter(r -> r
.getState() == StorageContainerDatanodeProtocolProtos
.ContainerReplicaProto.State.CLOSED)
.filter(r -> ReplicationManager
.getNodeStatus(r.getDatanodeDetails(), nodeManager)
.isHealthy())
.filter(r -> r.getDatanodeDetails().getPersistedOpState()
== HddsProtos.NodeOperationalState.IN_SERVICE)
.collect(Collectors.toSet());
}
```
When thinking about Ratis Containers, QUASI_CLOSED replicas can also be mis
replicated. They're also allowed to be replicated to datanodes so we should
allow them as sources too.
## What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-7696
## How was this patch tested?
New unit test added
--
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]