public class TestStochasticLoadBalancerHeterogeneousCost extends BalancerTestBase
BalancerTestBase.MockMapping
Modifier and Type | Field and Description |
---|---|
private static double |
ALLOWED_WINDOW |
static HBaseClassTestRule |
CLASS_RULE |
private static HBaseTestingUtility |
HTU |
private static org.slf4j.Logger |
LOG |
private static String |
RULES_FILE |
private Queue<org.apache.hadoop.hbase.ServerName> |
serverQueue |
clusterStateMocks, conf, largeCluster, loadBalancer, regionId
Constructor and Description |
---|
TestStochasticLoadBalancerHeterogeneousCost() |
Modifier and Type | Method and Description |
---|---|
static void |
beforeAllTests() |
private org.apache.hadoop.hbase.master.balancer.ServerAndLoad |
createServer(String host) |
protected Map<org.apache.hadoop.hbase.ServerName,List<org.apache.hadoop.hbase.client.RegionInfo>> |
createServerMap(int numNodes,
int numRegions,
int numRegionsPerServer,
int replication,
int numTables) |
protected TreeMap<org.apache.hadoop.hbase.ServerName,List<org.apache.hadoop.hbase.client.RegionInfo>> |
mockClusterServers(int[] mockCluster,
int numTables) |
void |
testDefault() |
void |
testFourGroups() |
private void |
testHeterogeneousWithCluster(int numNodes,
int numRegions,
int numRegionsPerServer,
List<String> rules) |
void |
testOneGroup() |
void |
testOverloaded() |
void |
testTwoGroups() |
protected void |
testWithCluster(Map<org.apache.hadoop.hbase.ServerName,List<org.apache.hadoop.hbase.client.RegionInfo>> serverMap,
org.apache.hadoop.hbase.master.RackManager rackManager,
boolean assertFullyBalanced,
boolean assertFullyBalancedForReplicas) |
assertClusterAsBalanced, assertClusterOverallAsBalanced, assertRegionReplicaPlacement, convertToList, createRegions, mockCluster, mockClusterServers, mockClusterServersWithTables, mockUniformClusterServers, printMock, printStats, randomRegions, randomRegions, randomServer, randomServers, reconcile, returnRegions, returnServer, returnServers, testWithCluster, uniformRegions, updateLoad
public static final HBaseClassTestRule CLASS_RULE
private static final org.slf4j.Logger LOG
private static final double ALLOWED_WINDOW
private static final HBaseTestingUtility HTU
private static String RULES_FILE
private Queue<org.apache.hadoop.hbase.ServerName> serverQueue
public TestStochasticLoadBalancerHeterogeneousCost()
public static void beforeAllTests() throws IOException
IOException
public void testDefault() throws IOException
IOException
public void testOneGroup() throws IOException
IOException
public void testTwoGroups() throws IOException
IOException
public void testFourGroups() throws IOException
IOException
public void testOverloaded() throws IOException
IOException
private void testHeterogeneousWithCluster(int numNodes, int numRegions, int numRegionsPerServer, List<String> rules) throws IOException
IOException
protected void testWithCluster(Map<org.apache.hadoop.hbase.ServerName,List<org.apache.hadoop.hbase.client.RegionInfo>> serverMap, org.apache.hadoop.hbase.master.RackManager rackManager, boolean assertFullyBalanced, boolean assertFullyBalancedForReplicas)
testWithCluster
in class BalancerTestBase
protected Map<org.apache.hadoop.hbase.ServerName,List<org.apache.hadoop.hbase.client.RegionInfo>> createServerMap(int numNodes, int numRegions, int numRegionsPerServer, int replication, int numTables)
createServerMap
in class BalancerTestBase
protected TreeMap<org.apache.hadoop.hbase.ServerName,List<org.apache.hadoop.hbase.client.RegionInfo>> mockClusterServers(int[] mockCluster, int numTables)
mockClusterServers
in class BalancerTestBase
private org.apache.hadoop.hbase.master.balancer.ServerAndLoad createServer(String host)
Copyright © 2007–2021 The Apache Software Foundation. All rights reserved.