public class PutAllDUnitTest extends DistributedTestCase
DistributedTestCase.ExpectedException, DistributedTestCase.WaitCriterion, DistributedTestCase.WaitCriterion2| Modifier and Type | Field and Description |
|---|---|
protected static com.gemstone.gemfire.internal.cache.EventID |
eventId
EventId *
|
protected static Object |
lockObject
Object to wait on till create is received
|
static int |
PORT1
port of server1
|
static int |
PORT2
port of server2
|
protected static String |
PUTALL_KEY1 |
protected static String |
PUTALL_KEY2 |
protected static String |
PUTALL_KEY3 |
protected static String |
PUTALL_KEY4 |
protected static String |
PUTALL_KEY5 |
protected static com.gemstone.gemfire.internal.cache.EventID |
putAlleventId1 |
protected static com.gemstone.gemfire.internal.cache.EventID |
putAlleventId2 |
protected static com.gemstone.gemfire.internal.cache.EventID |
putAlleventId3 |
protected static com.gemstone.gemfire.internal.cache.EventID |
putAlleventId4 |
protected static com.gemstone.gemfire.internal.cache.EventID |
putAlleventId5 |
protected static boolean |
receivedOperation
boolean to signify receipt of create
|
logPerTest, reconnect, system, testName| Constructor and Description |
|---|
PutAllDUnitTest(String name)
test constructor
|
| Modifier and Type | Method and Description |
|---|---|
static void |
assertGotAllValues() |
static Object |
assertThreadIdToSequenceIdMapHasEntryId()
function to assert that the ThreadIdtoSequence id Map is not Null and has only one entry
|
static Object[] |
assertThreadIdToSequenceIdMapHasEntryIds()
function to assert that the ThreadIdtoSequence id Map is not Null and has only one entry
|
static void |
assertThreadIdToSequenceIdMapisNotNullButEmpty()
function to assert that the ThreadIdtoSequence id Map is not Null but is empty
|
static void |
closeCache()
function to close cache
|
static void |
createClientCache1(String host,
Integer port1)
function to create client cache
|
static void |
createClientCache2(String host,
Integer port1)
function to create client cache with HAEventIdPropagationListenerForClient1 as the listener
|
static Integer |
createServerCache()
create the server
|
static Object[] |
putAll()
does an update and return the eventid generated.
|
static void |
setReceivedOperationToFalse() |
void |
setUp()
get the hosts and the VMs
|
void |
tearDown2()
close the caches
|
void |
testPutAll()
This test:
1) creates a client server configuration
2) asserts that the ThreadIdToSequenceIdMap is not null but is empty (on the client)
3) does a put on the server
4) Wait till put is received by the server (and also records the eventId in a variable) and returns the eventId generated on the server
5) asserts that the ThreadIdToSequenceIdMap is not null and has one entry (on the client side) and returns the eventId stored in the map
6) verifies the equality of the two event ids
|
static void |
waitTillOperationReceived()
wait till create is received.
|
addExpectedException, addExpectedException, addHydraProperties, attachDebugger, checkBBFlag, cleanupAllVms, clearBBFlag, crashDistributedSystem, crashDistributedSystem, createLogWriter, disconnectAllFromDS, disconnectFromDS, dumpAllStacks, dumpMyThreads, dumpStack, dumpStack, dumpStack, dumpStackTrace, fail, getAllDistributedSystemProperties, getDistributedSystemProperties, getDUnitLocatorAddress, getDUnitLocatorPort, getDUnitLocatorString, getDUnitLogLevel, getIPLiteral, getLogWriter, getLonerSystem, getMcastSystem, getMcastSystem, getRepeatTimeoutMs, getServerHostName, getSystem, getSystem, getTestClass, getTestName, getUniqueName, getVMCount, incBBFlag, invokeInEveryVM, invokeInEveryVM, invokeInEveryVM, invokeInEveryVM, invokeInEveryVMRepeatingIfNecessary, invokeInLocator, invokeRepeatingIfNecessary, isConnectedToDS, join, noteTiming, pause, pause, perVMSetUp, realTearDown, setDiskStoreForGateway, setSystem, setTestName, staticPause, tearDown, unregisterAllDataSerializersFromAllVms, unregisterDataSerializerInThisVM, unregisterInstantiatorsInThisVM, waitForBBFlag, waitForCriterion, waitMutexassertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, countTestCases, createResult, fail, fail, failNotEquals, failNotSame, failSame, format, getName, run, run, runBare, runTest, setName, toStringpublic static int PORT1
public static int PORT2
protected static com.gemstone.gemfire.internal.cache.EventID eventId
protected static volatile com.gemstone.gemfire.internal.cache.EventID putAlleventId1
protected static volatile com.gemstone.gemfire.internal.cache.EventID putAlleventId2
protected static volatile com.gemstone.gemfire.internal.cache.EventID putAlleventId3
protected static volatile com.gemstone.gemfire.internal.cache.EventID putAlleventId4
protected static volatile com.gemstone.gemfire.internal.cache.EventID putAlleventId5
protected static final String PUTALL_KEY1
protected static final String PUTALL_KEY2
protected static final String PUTALL_KEY3
protected static final String PUTALL_KEY4
protected static final String PUTALL_KEY5
protected static Object lockObject
protected static volatile boolean receivedOperation
public PutAllDUnitTest(String name)
public void setUp()
throws Exception
setUp in class DistributedTestCaseExceptionpublic void tearDown2()
throws Exception
tearDown2 in class DistributedTestCaseExceptionpublic static Integer createServerCache() throws Exception
Exceptionpublic static void createClientCache2(String host, Integer port1) throws Exception
Exceptionpublic static void createClientCache1(String host, Integer port1) throws Exception
Exceptionpublic static void closeCache()
public static void assertThreadIdToSequenceIdMapisNotNullButEmpty()
public static Object assertThreadIdToSequenceIdMapHasEntryId()
public static Object[] assertThreadIdToSequenceIdMapHasEntryIds()
public void testPutAll()
throws Exception
Exceptionpublic static void setReceivedOperationToFalse()
public static void assertGotAllValues()
public static Object[] putAll()
public static void waitTillOperationReceived()
Copyright © 2010-2015 Pivotal Software, Inc. All rights reserved.