[ 
https://issues.apache.org/jira/browse/HDDS-12628?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17936621#comment-17936621
 ] 

Stephen O'Donnell commented on HDDS-12628:
------------------------------------------

This is already implemented. The under replicated queue is defined as:

{code}
underRepQueue = Queues.synchronizedQueue(new PriorityQueue<>(
        Comparator.comparing(ContainerHealthResult
            .UnderReplicatedHealthResult::getWeightedRedundancy)
        .thenComparing(ContainerHealthResult
            .UnderReplicatedHealthResult::getRequeueCount)));
{code}

And the weighted redundancy will start at 2 if there are two replicates 
remaining, or 1 if there is only 1. Under replication caused by decommissioning 
replicas are given a lower priority and will only be attempted after the 
"reduced redundancy" replicas are dealt with.

> Prioritize the most under replicated containers for re-replication
> ------------------------------------------------------------------
>
>                 Key: HDDS-12628
>                 URL: https://issues.apache.org/jira/browse/HDDS-12628
>             Project: Apache Ozone
>          Issue Type: Improvement
>            Reporter: Wei-Chiu Chuang
>            Priority: Major
>
> HDDS-6957 implemented the logic to prioritize under replicated containers. 
> However it does not further prioritize those that are minimally replicated 
> (excluding: decommissioned nodes and corrupt replicas) and thus in danger of 
> missing permanently.
> As a matter of fact, HDFS implements that logic in LowRedundancyBlocks 
> [https://github.com/apache/hadoop/blob/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/blockmanagement/LowRedundancyBlocks.java]
> The same logic could be applicable to Ozone container replication.
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to