public class FixedPartitioningTest extends FunctionServiceTest
| Modifier and Type | Field and Description |
|---|---|
String |
ALL_BUCKETS |
static String |
DATASTORE_SEQUENCE_ID |
protected static Long |
dataStoreSequenceId |
String |
PRIMARY_BUCKETS |
String |
PRIMARY_PARTITIONS |
static com.gemstone.gemfire.cache.Region |
rootRegion |
String |
SECONDARY_PARTITIONS |
ARGS_FIRST_OP, ARGS_LAST_OP, BLOCKING_FIRST_OP, BLOCKING_LAST_OP, COLLECTOR_FIRST_OP, COLLECTOR_LAST_OP, DATASET_FIRST_OP, DATASET_LAST_OP, FUNC_ALLNODES, FUNC_ASYNCH, FUNC_HA_FIRST_OP, FUNC_HA_LAST_OP, FUNC_MULTIPLEKEY, FUNC_SINGLEKEY, FUNC_SYNCH, FUNC_WITH_ARGS, FUNC_WITH_CUSTOM_COLLECTOR, FUNC_WITH_MULTIPLE_DATASET, FUNC_WITH_SINGLE_DATASET, FUNC_WITHOUT_ARGS, FUNC_WITHOUT_COLLECTOR, funcArgs, funcDataSets, funcKeys, funcResultCollectors, funcSynch, KEYS_FIRST_OP, KEYS_LAST_OPADD_NEW_KEY, bridgeRegionDescriptNames, DataStoreVmStr, DESTROY, destroyThreshold, ENTRIES_TO_PUT, FIRST_OP, GET, INVALIDATE, isBridgeClient, isBridgeConfiguration, isGatewaySenderConfiguration, KEY_LIST, keyIntervals, LAST_OP, LOCAL_DESTROY, LOCAL_INVALIDATE, LOG_INTERVAL_MILLIS, numNewKeys, operations, parRegUtilInstance, PR_TOTAL_BUCKETS, PR_TOTAL_DATASTORES, QUERY, randomValues, regionDescriptNames, sc, sleepMSAfterOps, testInstance, theCache, totalNumKeys, UPDATE_EXISTING_KEY, VmIDStr| Constructor and Description |
|---|
FixedPartitioningTest() |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
addNewKey()
Add a new key to REGION_NAME.
|
protected boolean |
addNewKeyFunction()
Add a new key to REGION_NAME.
|
void |
createCacheFromXml(String cacheXmlFile)
Create cache from the xml file
|
void |
createXmlFile(File aFile)
Method to create the xml from the cache.
|
protected boolean |
destroy()
Destroy a key in region REGION_NAME.
|
protected boolean |
destroyFunction()
Destroy key to REGION_NAME.
|
static void |
doOnRegionFireAndForgetExecutions()
Task to do onRegion() fire and forget function executions
|
void |
doOnRegionsExecutions()
Task for doing onRegions() executions
|
void |
executeFunctionPrimaryBucketsAllBuckets(com.gemstone.gemfire.internal.cache.PartitionedRegion aRegion)
Task to verify executeOnPrimaryBuckets in function execution (all buckets)
|
void |
executeFunctionPrimaryBucketsMultipleNodes(com.gemstone.gemfire.internal.cache.PartitionedRegion aRegion)
Task to verify executeOnPrimaryBuckets in function execution (multiple
nodes)
|
void |
executeFunctionPrimaryBucketsSingleNode(com.gemstone.gemfire.internal.cache.PartitionedRegion aRegion)
Task to verify executeOnPrimaryBuckets in function execution (Single node)
|
protected boolean |
get()
get the value of key in REGION_NAME.
|
protected boolean |
getFunction()
get the value of key in REGION_NAME.
|
protected List<String> |
getPartitionNames(List<com.gemstone.gemfire.internal.cache.FixedPartitionAttributesImpl> fpas)
Utility method that give list of parititon names from the list of
FixedPartitionAttributes
|
com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember |
getPrimaryOwner(ClientVmInfo crashedOrRecycledVm)
The method will give the primary member for the buckets of primary
partitions of the crashed member.
|
Set<com.gemstone.gemfire.cache.Region<?,?>> |
getTestRegions()
Utility method to get the set of regions used in the test This may include
the normal PRs and FPRs (root regions of subregions are not included
though)
|
static void |
HydraTask_doFireAndForgetExecutions()
HydraTask to do fire and forget function executions
|
static void |
HydraTask_doOps()
Hydra task to do region operations, then stop scheduling.
|
static void |
HydraTask_doRandomFuncExec()
Hydra task to execute Random region Functions
|
static void |
HydraTask_executeFunctionAllKeys()
Hydra task for executing functions on all keys
|
static void |
HydraTask_HA_accessorInitialize()
Hydra task for initializing an accessor in HA tests
|
static void |
HydraTask_HA_dataStoreInitialize()
Hydra task for initializing a data store in HA tests
|
static void |
HydraTask_loadRegions() |
static void |
HydraTask_loadRegionsWithFuncExec()
Hydra task to populate the regions using function execution
|
static void |
HydraTask_logLocalSize()
Log the local size of the PR data store
|
static void |
HydraTask_onRegionFunctionPrimaryBuckets()
Hydra task to verify whether function execution with optimizeForWrite true
executes on the right nodes in case of FPR.
|
static void |
HydraTask_p2p_accessorInitialize()
Hydra task for initializing an accessor in peer to peer configuration
|
static void |
HydraTask_p2p_dataStoreInitialize()
Hydra task for initializing a data store in peer to peer configuration
|
static void |
HydraTask_putKeySetInBB()
Task to put the PR key set in the BB so they can be used by the client vms
|
static void |
HydraTask_recycleClientAndValidateBehavior()
Hydra task to stop/start numVmsToStop at a time.
|
static void |
HydraTask_registerInterest()
Task for clients to register interest in all regions
|
static void |
HydraTask_stopStartVms()
Hydra task to stop/start numVmsToStop at a time.
|
static void |
HydraTask_updateBBWithPartitionInfo()
Task to update BB with the primary and secondary partitions/buckets for the
region on the member
|
static void |
HydraTask_verifyBucketCopies()
Hydra task to verify bucket copies.
|
static void |
HydraTask_verifyFixedPartitioning()
Task to verify the fixed partitioning
|
static void |
HydraTask_verifyFPRCoLocation() |
static void |
HydraTask_verifyOverflowToDisk()
Hydra task to verify PR overflow to disk
|
static void |
HydraTask_verifyPrimaries()
Hydra task to verify primaries
|
static void |
HydraTask_verifyPRMetaData() |
static void |
HydraTask_verifyRebalanceBehavior()
Task to verify the FPRs does not rebalance but normal PR does.
|
static void |
HydraTask_verifyRegionContents()
Hydra task to verify the contents of the region after all ops.
|
static void |
HydraTask_verifyRegionSize()
Hydra task to verify the size of the region after the load.
|
void |
initialize(String regionDescriptName)
Initialize this test instance and create region(s)
|
protected boolean |
invalidate()
Invalidate a key in region REGION_NAME.
|
protected boolean |
invalidateFunction()
To invalidate a key to REGION_NAME.
|
void |
isMemberEligibleToHostPrimary(com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember newMember,
ClientVmInfo crashedMember)
Method to verify whether the member (new member) is eligible to host
primary for the primary buckets of the crashed member.
|
protected void |
loadRegions() |
protected void |
loadRegionsWithFuncExec()
Method to load regions using function execution
|
protected boolean |
localDestroy()
Locally destroy a key in region REGION_NAME.
|
protected boolean |
localDestroyFunction()
Locally destroy key to REGION_NAME.
|
protected boolean |
localInvalidate()
Locally invalidate a key in region REGION_NAME.
|
protected boolean |
localInvalidateFunction()
To locally invalidate a key to REGION_NAME.
|
void |
printVmParitionInfo(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
Task to print the partition info on the vm
|
protected boolean |
queryFunction()
Task is doing a query on the key (executed on the same keys of get ops)
|
void |
recycleClientAndValidateBehavior()
Task to recycle data store vm one by one and validate the following 1.
|
void |
registerFunctions()
Task that registers functions
|
static void |
setDataStoreSequenceId()
Utility method that get the datastore sequence id.
|
static void |
StartTask_initialize()
Initialize the known keys for this test
|
protected void |
stopStartVms()
Stop and start ParRegPrms.numVMsToStop.
|
void |
Task_verifyRegionSize()
Hydra task to verify the size of the region after the load.
|
protected void |
updateBBWithPartitionInfo()
Update the BB with the partition and bucket info for the partitioned region
on the member
|
protected boolean |
updateExistingKey()
Update an existing key in region REGION_NAME.
|
protected boolean |
updateExistingKeyFunction()
Update existing key in REGION_NAME.
|
protected void |
verifyCoLocation()
Task to verify colocation
|
protected void |
verifyFixedPartitioning()
Method to verify the fixed partitioning of primary and secondary partitions
Also whether the partition num buckets is taken care of.
|
void |
verifyFPRsDontRebalance(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
Verify that the FPRs did not get rebalanced to the new node
|
void |
verifyNormalPRsRebalance(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
Verify that the FPRs did get rebalanced to the new node
|
protected void |
verifyOverflowToDisk(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
Hydra task to verify PR overflow to disk
|
protected void |
verifyPartitionNumBuckets(com.gemstone.gemfire.internal.cache.PartitionedRegion pr,
List<com.gemstone.gemfire.internal.cache.FixedPartitionAttributesImpl> fpas,
Map<String,Set<Integer>> partition2Buckets)
Validation method that verifies whether the partition num buckets for
partitions are satisfied.
|
protected void |
verifyPrimaryFixedPartitioning(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
Method to verify the fixed partitioning of the primary partitions
|
protected void |
verifyRebalanceBehavior()
Method to verify the FPRs does not rebalance but normal PR does.
|
void |
verifyRedundantCopiesSatisfied(ClientVmInfo crashedOrRecycledMember,
boolean isExpectedToBeSatisfied)
Method to verify whether the redundantCopies are satisfied or not for the
buckets of the crashed/recycled member..
|
protected void |
verifySecondaryFixedPartitioning(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
Method to verify the fixed partitioning of the secondary partitions
|
addNewKeyFunction, destroyFunction, doFireAndForgetMemberExecutions, doFireAndForgetRegionExecutions, doFireAndForgetServerExecutions, doFunctionExecution, doOnRegionsExecutions, doOnRegionsExecutionsHA, doOnRegionsExecutionsHA, doRandomFunctionExecutions, doRandomFunctions, executeAndReturnResults, executeFunctionAllBuckets, executeFunctionAllKeys, executeFunctionFilterWithLocalDataSet, executeFunctionMultipleNodes, getArgs, getDataSets, getFunction, getKeySet, getResultCollectors, getSomeKeys, HydraTask_doFunctionExecution_HA, HydraTask_doFunctionExecution, HydraTask_doOnRegionsExecutions, HydraTask_doOnRegionsExecutionsHA, HydraTask_doRandomFunctionExecutions, HydraTask_doRandomMemberFunctionExecutions, HydraTask_doRandomMemberFunctionExecutionsWithServerGroup, HydraTask_HA_initDataStoreAndServerGroups, HydraTask_HA_initDataStoreWithServerGroups, HydraTask_initialize, HydraTask_initRegisterFunction, HydraTask_registerFunctions, HydraTask_storeServerDsToBB, HydraTask_varifyMetaDataRefreshCount, HydraTask_verifyClientPRMetadata, invalidateFunction, localDestroyFunction, localInvalidateFunction, memberExecutionArgsCollector, memberExecutionArgsWOCollector, memberExecutionWOArgsCollector, memberExecutionWOArgsWOCollector, queryFunction, randomFunctionExecution, serverExecutionArgsCollector, serverExecutionArgsWOCollector, serverExecutionOnServerGroup, serverExecutionWOArgsCollector, serverExecutionWOArgsWOCollector, updateFunction, validateFunctionResults, validatePrFuncNoFilterNoArgsNoRC, validatePrFuncNoFilterNoArgsWithRC, validatePrFuncNoFilterWithArgsNoRC, validatePrFuncNoFilterWithArgsWithRC, validatePrFunction, validatePrFuncWithFilterNoArgsNoRC, validatePrFuncWithFilterNoArgsWithRC, validatePrFuncWithFilterWithArgsNoRC, validatePrFuncWithFilterWithArgsWithRC, validateRandomFunctions, validateRegionCheckFunction, validateRegNoFilterWithArgsNoRC, validateRegNoFilterWithArgsWithRC, validateRegWithFilterWithArgsNoRC, validateRegWithFilterWithArgsWithRC, validateResultsaddNewKey, checkContainsKey, checkContainsValueForKey, checkUpdatedValue, checkValue, createRegions, createRegionsWithXml, destroy, doOps, get, getDataStoreVms, getOp, getValueToAdd, HydraTask_disconnect, HydraTask_incPR_TOTAL_DATASTORES, HydraTask_killVms, HydraTask_verifyColocatedRegions, HydraTask_verifyCoLocation, HydraTask_verifyCustomPartitioning, HydraTask_verifyPrimaryColocation, HydraTask_verifyPRListenerInvocation, HydraTask_waitForEventsReceival, initialize, invalidate, localDestroy, localInvalidate, putKeySetInBB, recordFailedOps, updateExistingKey, verifyBucketCoLocation, verifyBucketCopies, verifyCustomPartition, verifyCustomPartitioning, verifyPrimaries, verifyPrimaryBucketCoLocation, verifyPrimaryColocation, verifyPRListenerInvocation, verifyPRListenerInvocation, verifyPRMetaData, verifyRegionContents, verifyRegionSize, verifyUniqueBucketForCustomPartioning, waitForEventsReceivalprotected static Long dataStoreSequenceId
public final String PRIMARY_PARTITIONS
public final String SECONDARY_PARTITIONS
public final String PRIMARY_BUCKETS
public final String ALL_BUCKETS
public static final String DATASTORE_SEQUENCE_ID
public static com.gemstone.gemfire.cache.Region rootRegion
public static void StartTask_initialize()
public static void HydraTask_p2p_dataStoreInitialize()
public static void HydraTask_p2p_accessorInitialize()
public static void HydraTask_HA_dataStoreInitialize()
public static void HydraTask_HA_accessorInitialize()
public static void HydraTask_loadRegions()
public static void HydraTask_updateBBWithPartitionInfo()
public static void HydraTask_loadRegionsWithFuncExec()
public static void HydraTask_registerInterest()
public static void HydraTask_stopStartVms()
public static void HydraTask_recycleClientAndValidateBehavior()
public static void HydraTask_verifyPRMetaData()
public static void HydraTask_verifyRegionSize()
public void Task_verifyRegionSize()
Task_verifyRegionSize in class ParRegColocationpublic void initialize(String regionDescriptName)
initialize in class ParRegColocationpublic void createXmlFile(File aFile)
public void createCacheFromXml(String cacheXmlFile)
public void registerFunctions()
registerFunctions in class FunctionServiceTestprotected void loadRegions()
loadRegions in class ParRegColocationprotected void loadRegionsWithFuncExec()
public static void HydraTask_putKeySetInBB()
public static void HydraTask_doFireAndForgetExecutions()
public static void doOnRegionFireAndForgetExecutions()
public static void HydraTask_doRandomFuncExec()
public static void HydraTask_doOps()
protected boolean addNewKey()
addNewKey in class ParRegColocationprotected boolean addNewKeyFunction()
addNewKeyFunction in class FunctionServiceTestprotected boolean invalidateFunction()
invalidateFunction in class FunctionServiceTestprotected boolean invalidate()
invalidate in class ParRegColocationprotected boolean localInvalidateFunction()
localInvalidateFunction in class FunctionServiceTestprotected boolean localInvalidate()
localInvalidate in class ParRegColocationprotected boolean destroyFunction()
destroyFunction in class FunctionServiceTestprotected boolean destroy()
destroy in class ParRegColocationprotected boolean localDestroyFunction()
localDestroyFunction in class FunctionServiceTestprotected boolean localDestroy()
localDestroy in class ParRegColocationprotected boolean updateExistingKeyFunction()
updateExistingKeyFunction in class FunctionServiceTestprotected boolean updateExistingKey()
updateExistingKey in class ParRegColocationprotected boolean getFunction()
getFunction in class FunctionServiceTestprotected boolean get()
get in class ParRegColocationprotected boolean queryFunction()
queryFunction in class FunctionServiceTestpublic static void HydraTask_verifyFPRCoLocation()
protected void verifyCoLocation()
public static void HydraTask_verifyRebalanceBehavior()
protected void verifyRebalanceBehavior()
public void verifyFPRsDontRebalance(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
pr - public void verifyNormalPRsRebalance(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
pr - public static void HydraTask_verifyOverflowToDisk()
protected void verifyOverflowToDisk(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
public static void HydraTask_verifyFixedPartitioning()
protected void verifyFixedPartitioning()
protected void verifyPrimaryFixedPartitioning(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
pr - protected void verifySecondaryFixedPartitioning(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
pr - protected List<String> getPartitionNames(List<com.gemstone.gemfire.internal.cache.FixedPartitionAttributesImpl> fpas)
fpas - list of FixedPartitionAttributesprotected void verifyPartitionNumBuckets(com.gemstone.gemfire.internal.cache.PartitionedRegion pr,
List<com.gemstone.gemfire.internal.cache.FixedPartitionAttributesImpl> fpas,
Map<String,Set<Integer>> partition2Buckets)
pr - Partitioned Regionfpas - List of FixedPartitionAttributespartition2Buckets - Map of partition to bucketsprotected void updateBBWithPartitionInfo()
protected void stopStartVms()
stopStartVms in class ParRegColocationpublic void recycleClientAndValidateBehavior()
public com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember getPrimaryOwner(ClientVmInfo crashedOrRecycledVm)
crashedOrRecycledVm - -
ClientVMInfo of the crashed/recycled Memberpublic void verifyRedundantCopiesSatisfied(ClientVmInfo crashedOrRecycledMember, boolean isExpectedToBeSatisfied)
crashedOrRecycledMember - -
ClientVmInfo of the member recycled.isExpectedToBeSatisfied - -
Is the test expecting redundantCopies to be satisfied or
not.public void isMemberEligibleToHostPrimary(com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember newMember,
ClientVmInfo crashedMember)
newMember - crashedMember - public static void setDataStoreSequenceId()
public void printVmParitionInfo(com.gemstone.gemfire.internal.cache.PartitionedRegion pr)
pr - public static void HydraTask_logLocalSize()
public static void HydraTask_verifyPrimaries()
public static void HydraTask_verifyBucketCopies()
public static void HydraTask_verifyRegionContents()
public static void HydraTask_onRegionFunctionPrimaryBuckets()
public static void HydraTask_executeFunctionAllKeys()
public void executeFunctionPrimaryBucketsAllBuckets(com.gemstone.gemfire.internal.cache.PartitionedRegion aRegion)
public void executeFunctionPrimaryBucketsMultipleNodes(com.gemstone.gemfire.internal.cache.PartitionedRegion aRegion)
public void executeFunctionPrimaryBucketsSingleNode(com.gemstone.gemfire.internal.cache.PartitionedRegion aRegion)
public void doOnRegionsExecutions()
doOnRegionsExecutions in class FunctionServiceTestpublic Set<com.gemstone.gemfire.cache.Region<?,?>> getTestRegions()
Copyright © 2010-2015 Pivotal Software, Inc. All rights reserved.