public class CapacityTest extends Object
| Modifier and Type | Field and Description |
|---|---|
protected com.gemstone.gemfire.cache.Region |
aRegion |
protected static String |
bucketMapKey |
protected static String |
primaryMapKey |
static CapacityTest |
testInstance |
| Constructor and Description |
|---|
CapacityTest() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addCapacity()
Bring a new vm into the ds and rebalance to create new capacity.
|
protected Map<Integer,Integer> |
getIdealLocalSizeMap()
Return a Map containing the ideal number of entries for a given
vm's local max memory and the total number of keys currently in
aRegion.
|
protected static int |
getLocalMaxMemory()
Return a value for localMaxMemory for this vm.
|
protected Map<Integer,Integer> |
getLocalMaxMemoryMap()
Return a Map where the key is a vmId, and the value is that vm's
localMaxMemory setting
|
protected Map<Integer,Long> |
getLocalSizeMap()
Return a Map where the key is a vmId, and the value is that vm's
number of entries (its local size).
|
static void |
HydraTask_addCapacity()
Add a new vm (adds capacity) to the ds and rebalance with verification.
|
static void |
HydraTask_initAccessor()
Creates and initializes the singleton instance of ParRegTest in this VM.
|
static void |
HydraTask_initBridge()
Creates and initializes the singleton instance of ParRegTest in this VM.
|
static void |
HydraTask_initDataStore()
Creates and initializes the singleton instance of ParRegTest in this VM.
|
static void |
HydraTask_initEdge()
Creates and initializes the singleton instance of ParRegTest in this VM.
|
static void |
HydraTask_loadUntilFull()
Put into the PR until all data store vms exceed local max memory.
|
static void |
HydraTask_loadUntilNumKeys()
Put into the PR until RebalancePrms-numKeys has been reached.
|
static void |
HydraTask_rebalance()
Rebalance the PR.
|
static void |
HydraTask_recordLocalSize()
Record the local size of this VM's PR (this is the number of entries
in this vm's PR, not the number of entries in the entire pr).
|
static void |
HydraTask_replaceDataStore()
For replacement test, create the PR, rebalance and verify that this
vm hosts the equivalent capacity that it held before being stopped.
|
static void |
HydraTask_stopStart()
Stop a vm, write the current PR state to the bb before stopping.
|
static void |
HydraTask_verifyRegionSize()
Verify all keys/values are present
|
static void |
HydraTask_verifyVariedLMM()
Verify that a vm with localMaxMemory N has half the data as a vm with
localMaxMemory 2N.
|
void |
initializeInstance()
Initialize this test instance
|
void |
initializeRegion(String regDescriptName,
int localMaxMemory)
Create a region with the given region description name.
|
protected void |
loadUntilFull()
Put into the PR until local max memory is exceeded in all vms.
|
protected void |
loadUntilNumKeys()
Put into the PR until RebalancePrm.numKeys has been reached.
|
protected void |
stopStart()
Write the current state of buckets to the blackboard, then do
a stop/start.
|
protected void |
verifyLmmBasedOnIdealSize()
Verify the actual number of entries in each vm is close to the expected
ideal number of entries.
|
protected void |
verifyLmmBasedOnRelativeSize()
Verify the relative sizes of the data and local max memory in each vm relative
to every other vm.
|
protected void |
verifyRegionSize()
Verify the region size.
|
protected void |
verifyReplacedCapacity()
Verify that this restarted vm roughly replaced the capacity it had before.
|
public static CapacityTest testInstance
protected com.gemstone.gemfire.cache.Region aRegion
protected static final String primaryMapKey
protected static final String bucketMapKey
public static void HydraTask_initAccessor()
public static void HydraTask_initDataStore()
public static void HydraTask_initEdge()
public static void HydraTask_initBridge()
public static void HydraTask_replaceDataStore()
public void initializeRegion(String regDescriptName, int localMaxMemory)
regDescriptName - The name of a region description.localMaxMemory - The localMaxMemory to use for this region.public void initializeInstance()
protected static int getLocalMaxMemory()
public static void HydraTask_loadUntilFull()
public static void HydraTask_loadUntilNumKeys()
public static void HydraTask_addCapacity()
public static void HydraTask_verifyRegionSize()
public static void HydraTask_stopStart()
public static void HydraTask_rebalance()
public static void HydraTask_verifyVariedLMM()
public static void HydraTask_recordLocalSize()
protected void loadUntilFull()
protected void loadUntilNumKeys()
protected void addCapacity()
protected void verifyRegionSize()
protected void stopStart()
protected void verifyReplacedCapacity()
protected Map<Integer,Integer> getLocalMaxMemoryMap()
protected Map<Integer,Long> getLocalSizeMap()
protected void verifyLmmBasedOnRelativeSize()
protected void verifyLmmBasedOnIdealSize()
protected Map<Integer,Integer> getIdealLocalSizeMap()
Copyright © 2010-2015 Pivotal Software, Inc. All rights reserved.