Plannerpublic class GreedyPlanner extends java.lang.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 | Description |
|---|---|---|
static long |
GB |
|
static long |
MB |
|
static long |
TB |
| Constructor | Description |
|---|---|
GreedyPlanner(double threshold,
DiskBalancerDataNode node) |
Constructs a greedy planner.
|
| Modifier and Type | Method | 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 java.lang.Exception
public void balanceVolumeSet(DiskBalancerDataNode node, DiskBalancerVolumeSet vSet, NodePlan plan) throws java.lang.Exception
node - vSet - - DiskBalancerVolumeSetplan - - NodePlanjava.lang.ExceptionCopyright © 2008–2025 Apache Software Foundation. All rights reserved.