public class GreedyPlanner extends Object implements Planner
This is done by choosing the disks with largest amount of data above and below the idealStorage and then a move is scheduled between them.
| Modifier and Type | Field and Description | 
|---|---|
| static long | GB | 
| static long | MB | 
| static long | TB | 
| Constructor and Description | 
|---|
| GreedyPlanner(double threshold,
             DiskBalancerDataNode node)Constructs a greedy planner. | 
| Modifier and Type | Method and Description | 
|---|---|
| void | balanceVolumeSet(DiskBalancerDataNode node,
                DiskBalancerVolumeSet vSet,
                NodePlan plan)Computes Steps to make a DiskBalancerVolumeSet Balanced. | 
| NodePlan | plan(DiskBalancerDataNode node)Computes a node plan for the given node. | 
public static final long MB
public static final long GB
public static final long TB
public GreedyPlanner(double threshold,
                     DiskBalancerDataNode node)
threshold - - Disk tolerance that we are ok withnode - - node on which this planner is operating uponpublic NodePlan plan(DiskBalancerDataNode node) throws Exception
public void balanceVolumeSet(DiskBalancerDataNode node, DiskBalancerVolumeSet vSet, NodePlan plan) throws Exception
node - vSet - - DiskBalancerVolumeSetplan - - NodePlanExceptionCopyright © 2008–2023 Apache Software Foundation. All rights reserved.