You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by kl...@apache.org on 2016/02/02 21:21:51 UTC
[44/44] incubator-geode git commit: Refactor dunit
Refactor dunit
Project: http://git-wip-us.apache.org/repos/asf/incubator-geode/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-geode/commit/76e324b5
Tree: http://git-wip-us.apache.org/repos/asf/incubator-geode/tree/76e324b5
Diff: http://git-wip-us.apache.org/repos/asf/incubator-geode/diff/76e324b5
Branch: refs/heads/feature/GEODE-773-2
Commit: 76e324b52c8a2f0f5af67d8d43b91d709e3ddd83
Parents: 18401aa
Author: Kirk Lund <kl...@pivotal.io>
Authored: Tue Feb 2 12:20:28 2016 -0800
Committer: Kirk Lund <kl...@pivotal.io>
Committed: Tue Feb 2 12:20:28 2016 -0800
----------------------------------------------------------------------
.../gemfire/internal/util/DebuggerSupport.java | 17 +-
.../com/gemstone/gemfire/TXExpiryJUnitTest.java | 10 +-
.../cache/CacheRegionClearStatsDUnitTest.java | 5 +-
.../cache/ClientServerTimeSyncDUnitTest.java | 26 +-
.../cache/ConnectionPoolAndLoaderDUnitTest.java | 9 +-
.../ClientServerRegisterInterestsDUnitTest.java | 2 +-
.../internal/AutoConnectionSourceDUnitTest.java | 46 +-
.../CacheServerSSLConnectionDUnitTest.java | 6 +-
.../internal/LocatorLoadBalancingDUnitTest.java | 51 +-
.../cache/client/internal/LocatorTestBase.java | 11 +-
.../pooling/ConnectionManagerJUnitTest.java | 11 +-
.../management/MemoryThresholdsDUnitTest.java | 54 +-
.../MemoryThresholdsOffHeapDUnitTest.java | 52 +-
.../mapInterface/PutAllGlobalLockJUnitTest.java | 4 +-
.../PartitionRegionHelperDUnitTest.java | 11 +-
.../query/cq/dunit/CqQueryTestListener.java | 26 +-
.../query/dunit/CompactRangeIndexDUnitTest.java | 9 +-
.../cache/query/dunit/CqTimeTestListener.java | 14 +-
.../cache/query/dunit/HashIndexDUnitTest.java | 6 +-
.../cache/query/dunit/HelperTestCase.java | 3 +-
.../query/dunit/PdxStringQueryDUnitTest.java | 207 ++---
.../dunit/QueryDataInconsistencyDUnitTest.java | 43 +-
.../dunit/QueryIndexUsingXMLDUnitTest.java | 55 +-
.../QueryParamsAuthorizationDUnitTest.java | 3 +-
.../QueryUsingFunctionContextDUnitTest.java | 31 +-
.../query/dunit/QueryUsingPoolDUnitTest.java | 146 ++--
.../cache/query/dunit/RemoteQueryDUnitTest.java | 54 +-
...esourceManagerWithQueryMonitorDUnitTest.java | 24 +-
.../query/dunit/SelectStarQueryDUnitTest.java | 48 +-
.../IndexCreationDeadLockJUnitTest.java | 6 +-
.../IndexMaintenanceAsynchJUnitTest.java | 6 +-
.../functional/LikePredicateJUnitTest.java | 4 +-
.../internal/ExecutionContextJUnitTest.java | 4 +-
.../index/AsynchIndexMaintenanceJUnitTest.java | 17 +-
...rrentIndexInitOnOverflowRegionDUnitTest.java | 39 +-
...ndexOperationsOnOverflowRegionDUnitTest.java | 60 +-
...pdateWithInplaceObjectModFalseDUnitTest.java | 37 +-
...ConcurrentIndexUpdateWithoutWLDUnitTest.java | 41 +-
.../index/CopyOnReadIndexDUnitTest.java | 54 +-
.../index/IndexCreationInternalsJUnitTest.java | 6 +-
.../index/IndexMaintainceJUnitTest.java | 4 +-
.../IndexTrackingQueryObserverDUnitTest.java | 7 +-
...itializeIndexEntryDestroyQueryDUnitTest.java | 26 +-
.../index/MultiIndexCreationDUnitTest.java | 23 +-
.../index/PutAllWithIndexPerfDUnitTest.java | 6 +-
.../PRBasicIndexCreationDUnitTest.java | 103 +--
.../PRBasicIndexCreationDeadlockDUnitTest.java | 17 +-
.../PRBasicMultiIndexCreationDUnitTest.java | 85 +-
.../partitioned/PRBasicQueryDUnitTest.java | 33 +-
.../PRBasicRemoveIndexDUnitTest.java | 7 +-
.../PRColocatedEquiJoinDUnitTest.java | 304 +++----
.../partitioned/PRInvalidQueryDUnitTest.java | 17 +-
.../partitioned/PRQueryCacheCloseDUnitTest.java | 70 +-
.../PRQueryCacheClosedJUnitTest.java | 6 +-
.../query/partitioned/PRQueryDUnitHelper.java | 144 ++--
.../query/partitioned/PRQueryDUnitTest.java | 157 ++--
.../query/partitioned/PRQueryPerfDUnitTest.java | 10 +-
.../PRQueryRegionCloseDUnitTest.java | 36 +-
.../PRQueryRegionDestroyedDUnitTest.java | 38 +-
.../PRQueryRegionDestroyedJUnitTest.java | 6 +-
.../PRQueryRemoteNodeExceptionDUnitTest.java | 139 +--
.../snapshot/SnapshotByteArrayDUnitTest.java | 7 +-
.../snapshot/SnapshotPerformanceDUnitTest.java | 17 +-
.../gemfire/cache30/Bug35214DUnitTest.java | 11 +-
.../gemfire/cache30/Bug38741DUnitTest.java | 12 +-
.../gemfire/cache30/CacheListenerTestCase.java | 5 +-
.../gemfire/cache30/CacheLoaderTestCase.java | 5 +-
.../gemfire/cache30/CacheMapTxnDUnitTest.java | 6 +-
...cheRegionsReliablityStatsCheckDUnitTest.java | 3 +-
.../cache30/CacheStatisticsDUnitTest.java | 15 +-
.../gemstone/gemfire/cache30/CacheTestCase.java | 16 +-
.../gemfire/cache30/CacheXml30DUnitTest.java | 23 +-
.../gemfire/cache30/CacheXml41DUnitTest.java | 6 +-
.../gemfire/cache30/CacheXml57DUnitTest.java | 17 +-
.../gemfire/cache30/CacheXml60DUnitTest.java | 6 +-
.../gemfire/cache30/CacheXml65DUnitTest.java | 2 +-
.../gemfire/cache30/CacheXml66DUnitTest.java | 2 +-
.../gemfire/cache30/CacheXml81DUnitTest.java | 2 +-
.../gemfire/cache30/CacheXml90DUnitTest.java | 6 +-
.../cache30/CertifiableTestCacheListener.java | 12 +-
.../cache30/ClearMultiVmCallBkDUnitTest.java | 13 +-
.../gemfire/cache30/ClearMultiVmDUnitTest.java | 11 +-
.../cache30/ClientMembershipDUnitTest.java | 149 ++--
.../ClientRegisterInterestDUnitTest.java | 53 +-
.../cache30/ClientServerCCEDUnitTest.java | 50 +-
.../gemfire/cache30/ClientServerTestCase.java | 7 +-
.../ConcurrentLeaveDuringGIIDUnitTest.java | 13 +-
.../gemfire/cache30/DiskRegionDUnitTest.java | 24 +-
.../cache30/DistAckMapMethodsDUnitTest.java | 8 +-
...tedAckOverflowRegionCCEOffHeapDUnitTest.java | 3 +-
...tributedAckPersistentRegionCCEDUnitTest.java | 1 -
...dAckPersistentRegionCCEOffHeapDUnitTest.java | 3 +-
.../DistributedAckRegionCCEDUnitTest.java | 8 +-
...DistributedAckRegionCCEOffHeapDUnitTest.java | 3 +-
.../cache30/DistributedAckRegionDUnitTest.java | 3 +-
.../DistributedAckRegionOffHeapDUnitTest.java | 3 +-
.../DistributedMulticastRegionDUnitTest.java | 3 +-
.../DistributedNoAckRegionCCEDUnitTest.java | 16 +-
...stributedNoAckRegionCCEOffHeapDUnitTest.java | 3 +-
.../DistributedNoAckRegionDUnitTest.java | 39 +-
.../DistributedNoAckRegionOffHeapDUnitTest.java | 3 +-
.../gemfire/cache30/DynamicRegionDUnitTest.java | 15 +-
.../gemfire/cache30/GlobalLockingDUnitTest.java | 7 +-
.../GlobalRegionCCEOffHeapDUnitTest.java | 3 +-
.../gemfire/cache30/GlobalRegionDUnitTest.java | 13 +-
.../cache30/GlobalRegionOffHeapDUnitTest.java | 3 +-
.../cache30/LRUEvictionControllerDUnitTest.java | 3 +-
.../gemfire/cache30/MultiVMRegionTestCase.java | 265 +++---
.../OffHeapLRUEvictionControllerDUnitTest.java | 3 +-
.../PRBucketSynchronizationDUnitTest.java | 26 +-
.../cache30/PartitionedRegionDUnitTest.java | 2 +-
.../PartitionedRegionOffHeapDUnitTest.java | 3 +-
.../cache30/PutAllCallBkRemoteVMDUnitTest.java | 27 +-
.../cache30/PutAllCallBkSingleVMDUnitTest.java | 19 +-
.../gemfire/cache30/PutAllMultiVmDUnitTest.java | 3 +-
.../gemfire/cache30/QueueMsgDUnitTest.java | 5 +-
.../cache30/RRSynchronizationDUnitTest.java | 24 +-
.../gemfire/cache30/ReconnectDUnitTest.java | 140 +--
.../cache30/RegionExpirationDUnitTest.java | 14 +-
.../RegionMembershipListenerDUnitTest.java | 20 +-
.../cache30/RegionReliabilityTestCase.java | 13 +-
.../gemfire/cache30/RegionTestCase.java | 93 +-
.../cache30/RemoveAllMultiVmDUnitTest.java | 3 +-
.../gemfire/cache30/RequiredRolesDUnitTest.java | 19 +-
.../cache30/RolePerformanceDUnitTest.java | 5 +-
.../gemfire/cache30/SearchAndLoadDUnitTest.java | 18 +-
.../gemfire/cache30/SlowRecDUnitTest.java | 127 +--
.../gemfire/cache30/TXDistributedDUnitTest.java | 42 +-
.../gemfire/cache30/TXOrderDUnitTest.java | 5 +-
.../cache30/TXRestrictionsDUnitTest.java | 3 +-
.../gemfire/cache30/TestCacheCallback.java | 6 +-
.../distributed/DistributedSystemDUnitTest.java | 12 +-
.../gemfire/distributed/LocatorDUnitTest.java | 164 ++--
.../gemfire/distributed/LocatorJUnitTest.java | 1 -
.../distributed/SystemAdminDUnitTest.java | 8 +-
.../distributed/internal/Bug40751DUnitTest.java | 3 +-
.../ConsoleDistributionManagerDUnitTest.java | 22 +-
.../internal/DistributionAdvisorDUnitTest.java | 3 +-
.../internal/DistributionManagerDUnitTest.java | 29 +-
.../GemFireDeadlockDetectorDUnitTest.java | 8 +-
.../internal/locks/CollaborationJUnitTest.java | 53 +-
.../membership/gms/MembershipManagerHelper.java | 6 +-
.../TcpServerBackwardCompatDUnitTest.java | 9 +-
.../gemfire/disttx/DistTXDebugDUnitTest.java | 112 +--
.../disttx/DistTXPersistentDebugDUnitTest.java | 14 +-
.../disttx/DistributedTransactionDUnitTest.java | 20 +-
.../ClassNotFoundExceptionDUnitTest.java | 5 +-
.../gemfire/internal/JSSESocketJUnitTest.java | 4 +-
.../internal/PdxDeleteFieldDUnitTest.java | 3 +-
.../gemfire/internal/PdxRenameDUnitTest.java | 3 +-
.../gemfire/internal/SocketCloserJUnitTest.java | 12 +-
.../gemfire/internal/cache/BackupDUnitTest.java | 54 +-
.../internal/cache/Bug33359DUnitTest.java | 7 +-
.../internal/cache/Bug37241DUnitTest.java | 9 +-
.../internal/cache/Bug37377DUnitTest.java | 8 +-
.../internal/cache/Bug39079DUnitTest.java | 3 +-
.../internal/cache/Bug40299DUnitTest.java | 2 +-
.../internal/cache/Bug41091DUnitTest.java | 10 +-
.../internal/cache/Bug41957DUnitTest.java | 6 +-
.../internal/cache/Bug45164DUnitTest.java | 3 +-
.../internal/cache/Bug47667DUnitTest.java | 3 +-
.../internal/cache/CacheAdvisorDUnitTest.java | 7 +-
.../internal/cache/ClearDAckDUnitTest.java | 26 +-
.../internal/cache/ClearGlobalDUnitTest.java | 10 +-
.../cache/ClientServerGetAllDUnitTest.java | 24 +-
...ServerInvalidAndDestroyedEntryDUnitTest.java | 23 +-
.../ClientServerTransactionCCEDUnitTest.java | 11 +-
.../cache/ClientServerTransactionDUnitTest.java | 76 +-
.../cache/ConcurrentMapOpsDUnitTest.java | 24 +-
.../ConcurrentRegionOperationsJUnitTest.java | 18 +-
...rentRollingAndRegionOperationsJUnitTest.java | 4 +-
.../cache/ConnectDisconnectDUnitTest.java | 9 +-
.../cache/DeltaPropagationDUnitTest.java | 10 +-
.../cache/DeltaPropagationStatsDUnitTest.java | 13 +-
.../internal/cache/DeltaSizingDUnitTest.java | 5 +-
.../cache/DiskRegByteArrayDUnitTest.java | 3 +-
.../cache/DiskRegionClearJUnitTest.java | 4 +-
.../internal/cache/DiskRegionJUnitTest.java | 43 +-
...DistrbutedRegionProfileOffHeapDUnitTest.java | 5 +-
.../cache/DistributedCacheTestCase.java | 11 +-
.../internal/cache/EventTrackerDUnitTest.java | 10 +-
.../internal/cache/EvictionDUnitTest.java | 9 +-
.../cache/EvictionObjectSizerDUnitTest.java | 17 +-
.../internal/cache/EvictionStatsDUnitTest.java | 17 +-
.../internal/cache/EvictionTestBase.java | 24 +-
.../cache/FixedPRSinglehopDUnitTest.java | 26 +-
.../internal/cache/GIIDeltaDUnitTest.java | 51 +-
.../internal/cache/GIIFlowControlDUnitTest.java | 23 +-
.../internal/cache/GridAdvisorDUnitTest.java | 24 +-
.../internal/cache/HABug36773DUnitTest.java | 8 +-
.../HAOverflowMemObjectSizerDUnitTest.java | 5 +-
.../cache/IncrementalBackupDUnitTest.java | 12 +-
.../cache/InterruptClientServerDUnitTest.java | 5 +-
.../internal/cache/InterruptsDUnitTest.java | 3 +-
.../internal/cache/MapClearGIIDUnitTest.java | 19 +-
.../internal/cache/MapInterface2JUnitTest.java | 6 +-
.../cache/NetSearchMessagingDUnitTest.java | 13 +-
.../cache/OffHeapEvictionDUnitTest.java | 17 +-
.../cache/OffHeapEvictionStatsDUnitTest.java | 12 +-
.../gemfire/internal/cache/OplogJUnitTest.java | 25 +-
.../cache/PartitionedRegionAPIDUnitTest.java | 23 +-
...gionBucketCreationDistributionDUnitTest.java | 90 +-
.../PartitionedRegionCacheCloseDUnitTest.java | 14 +-
.../PartitionedRegionCreationDUnitTest.java | 53 +-
.../cache/PartitionedRegionDUnitTestCase.java | 7 +-
...rtitionedRegionDelayedRecoveryDUnitTest.java | 3 +-
.../PartitionedRegionDestroyDUnitTest.java | 20 +-
.../PartitionedRegionEvictionDUnitTest.java | 7 +-
.../cache/PartitionedRegionHADUnitTest.java | 17 +-
...onedRegionHAFailureAndRecoveryDUnitTest.java | 44 +-
...artitionedRegionLocalMaxMemoryDUnitTest.java | 5 +-
...nedRegionLocalMaxMemoryOffHeapDUnitTest.java | 3 +-
.../PartitionedRegionMultipleDUnitTest.java | 57 +-
...rtitionedRegionOffHeapEvictionDUnitTest.java | 3 +-
.../cache/PartitionedRegionPRIDDUnitTest.java | 17 +-
.../cache/PartitionedRegionQueryDUnitTest.java | 10 +-
...tionedRegionSerializableObjectJUnitTest.java | 4 +-
.../PartitionedRegionSingleHopDUnitTest.java | 144 ++--
...RegionSingleHopWithServerGroupDUnitTest.java | 115 +--
.../cache/PartitionedRegionSizeDUnitTest.java | 17 +-
.../cache/PartitionedRegionStatsDUnitTest.java | 4 +-
.../PartitionedRegionTestUtilsDUnitTest.java | 9 +-
.../PartitionedRegionWithSameNameDUnitTest.java | 43 +-
.../internal/cache/PutAllDAckDUnitTest.java | 5 +-
.../internal/cache/PutAllGlobalDUnitTest.java | 29 +-
.../cache/RemoteTransactionDUnitTest.java | 34 +-
.../internal/cache/RemoveAllDAckDUnitTest.java | 5 +-
.../internal/cache/RemoveDAckDUnitTest.java | 3 +-
.../internal/cache/RemoveGlobalDUnitTest.java | 8 +-
.../cache/SimpleDiskRegionJUnitTest.java | 12 +-
.../internal/cache/SingleHopStatsDUnitTest.java | 29 +-
.../internal/cache/SystemFailureDUnitTest.java | 20 +-
.../cache/TXReservationMgrJUnitTest.java | 4 +-
.../cache/TransactionsWithDeltaDUnitTest.java | 11 +-
.../control/RebalanceOperationDUnitTest.java | 30 +-
...egionOverflowAsyncRollingOpLogJUnitTest.java | 6 +-
...RegionOverflowSyncRollingOpLogJUnitTest.java | 6 +-
...ltiThreadedOplogPerJUnitPerformanceTest.java | 4 +-
.../cache/execute/Bug51193DUnitTest.java | 3 +-
.../ClientServerFunctionExecutionDUnitTest.java | 79 +-
.../execute/ColocationFailoverDUnitTest.java | 20 +-
...ributedRegionFunctionExecutionDUnitTest.java | 60 +-
.../execute/FunctionServiceStatsDUnitTest.java | 31 +-
.../cache/execute/LocalDataSetDUnitTest.java | 9 +-
.../LocalFunctionExecutionDUnitTest.java | 8 +-
.../MemberFunctionExecutionDUnitTest.java | 21 +-
.../MultiRegionFunctionExecutionDUnitTest.java | 3 +-
.../OnGroupsFunctionExecutionDUnitTest.java | 68 +-
...ntServerFunctionExecutionNoAckDUnitTest.java | 35 +-
...tServerRegionFunctionExecutionDUnitTest.java | 52 +-
...egionFunctionExecutionFailoverDUnitTest.java | 55 +-
...onFunctionExecutionNoSingleHopDUnitTest.java | 51 +-
...onExecutionSelectorNoSingleHopDUnitTest.java | 67 +-
...gionFunctionExecutionSingleHopDUnitTest.java | 59 +-
.../cache/execute/PRClientServerTestBase.java | 38 +-
.../cache/execute/PRColocationDUnitTest.java | 101 +--
.../execute/PRCustomPartitioningDUnitTest.java | 5 +-
.../execute/PRFunctionExecutionDUnitTest.java | 31 +-
.../PRFunctionExecutionTimeOutDUnitTest.java | 4 +-
...ctionExecutionWithResultSenderDUnitTest.java | 3 +-
.../execute/PRPerformanceTestDUnitTest.java | 9 +-
.../cache/execute/PRTransactionDUnitTest.java | 32 +-
.../execute/SingleHopGetAllPutAllDUnitTest.java | 15 +-
.../functions/DistributedRegionFunction.java | 6 +-
.../internal/cache/functions/TestFunction.java | 8 +-
.../ha/BlockingHARQAddOperationJUnitTest.java | 9 +-
.../cache/ha/BlockingHARegionJUnitTest.java | 55 +-
.../cache/ha/Bug36853EventsExpiryDUnitTest.java | 20 +-
.../internal/cache/ha/Bug48571DUnitTest.java | 9 +-
.../cache/ha/EventIdOptimizationDUnitTest.java | 16 +-
.../internal/cache/ha/FailoverDUnitTest.java | 11 +-
.../internal/cache/ha/HABugInPutDUnitTest.java | 5 +-
.../internal/cache/ha/HAClearDUnitTest.java | 16 +-
.../cache/ha/HAConflationDUnitTest.java | 8 +-
.../internal/cache/ha/HADuplicateDUnitTest.java | 7 +-
.../cache/ha/HAEventIdPropagationDUnitTest.java | 18 +-
.../internal/cache/ha/HAExpiryDUnitTest.java | 11 +-
.../internal/cache/ha/HAGIIBugDUnitTest.java | 21 +-
.../internal/cache/ha/HAGIIDUnitTest.java | 26 +-
.../cache/ha/HARQAddOperationJUnitTest.java | 24 +-
.../cache/ha/HARQueueNewImplDUnitTest.java | 91 +-
.../cache/ha/HARegionQueueDUnitTest.java | 17 +-
.../cache/ha/HARegionQueueJUnitTest.java | 26 +-
.../cache/ha/HASlowReceiverDUnitTest.java | 11 +-
.../ha/OperationsPropagationDUnitTest.java | 25 +-
.../internal/cache/ha/PutAllDUnitTest.java | 10 +-
.../internal/cache/ha/StatsBugDUnitTest.java | 21 +-
.../cache/locks/TXLockServiceDUnitTest.java | 43 +-
.../cache/partitioned/Bug39356DUnitTest.java | 5 +-
.../cache/partitioned/Bug43684DUnitTest.java | 5 +-
.../cache/partitioned/Bug47388DUnitTest.java | 6 +-
.../cache/partitioned/Bug51400DUnitTest.java | 6 +-
...rtitionedRegionMetaDataCleanupDUnitTest.java | 13 +-
.../partitioned/PersistPRKRFDUnitTest.java | 22 +-
...tentColocatedPartitionedRegionDUnitTest.java | 26 +-
.../PersistentPartitionedRegionDUnitTest.java | 60 +-
.../PersistentPartitionedRegionTestBase.java | 20 +-
...rtitionedRegionWithTransactionDUnitTest.java | 12 +-
.../cache/partitioned/ShutdownAllDUnitTest.java | 14 +-
.../fixed/FixedPartitioningDUnitTest.java | 31 +-
.../fixed/FixedPartitioningTestBase.java | 54 +-
...ngWithColocationAndPersistenceDUnitTest.java | 31 +-
.../PersistentRVVRecoveryDUnitTest.java | 24 +-
.../PersistentRecoveryOrderDUnitTest.java | 111 +--
.../PersistentReplicatedTestBase.java | 7 +-
.../internal/cache/tier/Bug40396DUnitTest.java | 3 +-
...mpatibilityHigherVersionClientDUnitTest.java | 3 +-
.../cache/tier/sockets/Bug36269DUnitTest.java | 11 +-
.../cache/tier/sockets/Bug36457DUnitTest.java | 8 +-
.../cache/tier/sockets/Bug36805DUnitTest.java | 9 +-
.../cache/tier/sockets/Bug36829DUnitTest.java | 3 +-
.../cache/tier/sockets/Bug36995DUnitTest.java | 13 +-
.../cache/tier/sockets/Bug37210DUnitTest.java | 16 +-
.../cache/tier/sockets/Bug37805DUnitTest.java | 3 +-
.../CacheServerMaxConnectionsJUnitTest.java | 8 +-
.../cache/tier/sockets/CacheServerTestUtil.java | 24 +-
.../CacheServerTransactionsDUnitTest.java | 104 +--
.../tier/sockets/ClearPropagationDUnitTest.java | 12 +-
.../tier/sockets/ClientConflationDUnitTest.java | 18 +-
.../sockets/ClientHealthMonitorJUnitTest.java | 8 +-
.../sockets/ClientInterestNotifyDUnitTest.java | 16 +-
.../tier/sockets/ClientServerMiscDUnitTest.java | 77 +-
.../cache/tier/sockets/ConflationDUnitTest.java | 44 +-
.../tier/sockets/ConnectionProxyJUnitTest.java | 14 +-
.../DataSerializerPropogationDUnitTest.java | 81 +-
.../DestroyEntryPropagationDUnitTest.java | 22 +-
.../sockets/DurableClientBug39997DUnitTest.java | 7 +-
.../DurableClientQueueSizeDUnitTest.java | 7 +-
.../DurableClientReconnectAutoDUnitTest.java | 4 +-
.../DurableClientReconnectDUnitTest.java | 74 +-
.../sockets/DurableClientStatsDUnitTest.java | 38 +-
.../sockets/DurableRegistrationDUnitTest.java | 48 +-
.../sockets/DurableResponseMatrixDUnitTest.java | 9 +-
.../sockets/EventIDVerificationDUnitTest.java | 3 +-
.../ForceInvalidateEvictionDUnitTest.java | 9 +-
...ForceInvalidateOffHeapEvictionDUnitTest.java | 3 +-
.../cache/tier/sockets/HABug36738DUnitTest.java | 10 +-
.../tier/sockets/HAInterestPart1DUnitTest.java | 21 +-
.../tier/sockets/HAInterestPart2DUnitTest.java | 30 +-
.../cache/tier/sockets/HAInterestTestCase.java | 48 +-
.../sockets/HAStartupAndFailoverDUnitTest.java | 37 +-
.../InstantiatorPropagationDUnitTest.java | 74 +-
.../tier/sockets/InterestListDUnitTest.java | 77 +-
.../sockets/InterestListEndpointDUnitTest.java | 18 +-
.../sockets/InterestListFailoverDUnitTest.java | 9 +-
.../sockets/InterestListRecoveryDUnitTest.java | 25 +-
.../sockets/InterestRegrListenerDUnitTest.java | 51 +-
.../sockets/InterestResultPolicyDUnitTest.java | 14 +-
.../sockets/NewRegionAttributesDUnitTest.java | 3 +-
.../sockets/RedundancyLevelPart1DUnitTest.java | 33 +-
.../sockets/RedundancyLevelPart2DUnitTest.java | 33 +-
.../sockets/RedundancyLevelPart3DUnitTest.java | 7 +-
.../tier/sockets/RedundancyLevelTestBase.java | 31 +-
.../tier/sockets/RegionCloseDUnitTest.java | 13 +-
...erInterestBeforeRegionCreationDUnitTest.java | 9 +-
.../sockets/RegisterInterestKeysDUnitTest.java | 11 +-
.../sockets/ReliableMessagingDUnitTest.java | 26 +-
.../sockets/UnregisterInterestDUnitTest.java | 7 +-
.../sockets/UpdatePropagationDUnitTest.java | 33 +-
...UpdatesFromNonInterestEndPointDUnitTest.java | 8 +-
.../versions/RegionVersionVectorJUnitTest.java | 4 +-
.../cache/wan/AsyncEventQueueTestBase.java | 80 +-
.../asyncqueue/AsyncEventListenerDUnitTest.java | 76 +-
.../AsyncEventQueueStatsDUnitTest.java | 15 +-
.../CommonParallelAsyncEventQueueDUnitTest.java | 2 +-
.../CompressionCacheConfigDUnitTest.java | 11 +-
...ompressionCacheListenerOffHeapDUnitTest.java | 3 +-
.../CompressionRegionConfigDUnitTest.java | 17 +-
...ressionRegionOperationsOffHeapDUnitTest.java | 3 +-
.../internal/jta/dunit/ExceptionsDUnitTest.java | 11 +-
.../jta/dunit/IdleTimeOutDUnitTest.java | 48 +-
.../jta/dunit/LoginTimeOutDUnitTest.java | 12 +-
.../jta/dunit/MaxPoolSizeDUnitTest.java | 34 +-
.../jta/dunit/TransactionTimeOutDUnitTest.java | 12 +-
.../dunit/TxnManagerMultiThreadDUnitTest.java | 68 +-
.../internal/jta/dunit/TxnTimeOutDUnitTest.java | 24 +-
.../DistributedSystemLogFileJUnitTest.java | 18 +-
.../logging/LocatorLogFileJUnitTest.java | 6 +-
.../logging/MergeLogFilesJUnitTest.java | 4 +-
.../internal/offheap/OffHeapRegionBase.java | 4 +-
.../offheap/OutOfOffHeapMemoryDUnitTest.java | 15 +-
.../statistics/StatisticsDUnitTest.java | 15 +-
.../statistics/ValueMonitorJUnitTest.java | 6 +-
.../management/CacheManagementDUnitTest.java | 22 +-
.../management/ClientHealthStatsDUnitTest.java | 20 +-
.../management/CompositeTypeTestDUnitTest.java | 4 +-
.../management/DLockManagementDUnitTest.java | 19 +-
.../management/DiskManagementDUnitTest.java | 32 +-
.../management/DistributedSystemDUnitTest.java | 37 +-
.../management/LocatorManagementDUnitTest.java | 17 +-
.../gemstone/gemfire/management/MBeanUtil.java | 26 +-
.../gemfire/management/ManagementTestBase.java | 25 +-
.../MemberMBeanAttributesDUnitTest.java | 3 +-
.../management/OffHeapManagementDUnitTest.java | 4 +-
.../gemfire/management/QueryDataDUnitTest.java | 23 +-
.../management/RegionManagementDUnitTest.java | 49 +-
...ersalMembershipListenerAdapterDUnitTest.java | 148 ++--
.../internal/cli/CliUtilDUnitTest.java | 30 +-
.../cli/commands/CliCommandTestBase.java | 9 +-
.../cli/commands/ConfigCommandsDUnitTest.java | 35 +-
...eateAlterDestroyRegionCommandsDUnitTest.java | 56 +-
.../cli/commands/DeployCommandsDUnitTest.java | 7 +-
.../commands/DiskStoreCommandsDUnitTest.java | 32 +-
.../cli/commands/FunctionCommandsDUnitTest.java | 56 +-
.../commands/GemfireDataCommandsDUnitTest.java | 180 ++--
...WithCacheLoaderDuringCacheMissDUnitTest.java | 8 +-
.../cli/commands/IndexCommandsDUnitTest.java | 12 +-
...stAndDescribeDiskStoreCommandsDUnitTest.java | 7 +-
.../ListAndDescribeRegionDUnitTest.java | 29 +-
.../cli/commands/ListIndexCommandDUnitTest.java | 15 +-
.../cli/commands/MemberCommandsDUnitTest.java | 12 +-
.../MiscellaneousCommandsDUnitTest.java | 36 +-
...laneousCommandsExportLogsPart1DUnitTest.java | 9 +-
...laneousCommandsExportLogsPart2DUnitTest.java | 9 +-
...laneousCommandsExportLogsPart3DUnitTest.java | 9 +-
...laneousCommandsExportLogsPart4DUnitTest.java | 9 +-
.../cli/commands/QueueCommandsDUnitTest.java | 10 +-
.../SharedConfigurationCommandsDUnitTest.java | 24 +-
.../cli/commands/ShellCommandsDUnitTest.java | 16 +-
.../cli/commands/ShowDeadlockDUnitTest.java | 8 +-
.../cli/commands/ShowMetricsDUnitTest.java | 37 +-
.../cli/commands/ShowStackTraceDUnitTest.java | 21 +-
.../SharedConfigurationDUnitTest.java | 15 +-
.../internal/pulse/TestClientIdsDUnitTest.java | 15 +-
.../internal/pulse/TestFunctionsDUnitTest.java | 7 +-
.../internal/pulse/TestHeapDUnitTest.java | 7 +-
.../internal/pulse/TestLocatorsDUnitTest.java | 7 +-
.../pulse/TestSubscriptionsDUnitTest.java | 12 +-
.../ClientsWithVersioningRetryDUnitTest.java | 24 +-
.../pdx/DistributedSystemIdDUnitTest.java | 2 +-
.../pdx/JSONPdxClientServerDUnitTest.java | 5 +-
.../gemfire/pdx/PdxClientServerDUnitTest.java | 16 +-
.../pdx/PdxDeserializationDUnitTest.java | 4 +-
.../gemfire/pdx/PdxTypeExportDUnitTest.java | 3 +-
.../gemfire/pdx/VersionClassLoader.java | 10 +-
.../gemfire/redis/RedisDistDUnitTest.java | 10 +-
.../web/controllers/RestAPITestBase.java | 3 +-
.../security/ClientAuthenticationDUnitTest.java | 94 +-
.../security/ClientAuthorizationDUnitTest.java | 57 +-
.../security/ClientAuthorizationTestBase.java | 25 +-
.../security/ClientMultiUserAuthzDUnitTest.java | 35 +-
.../DeltaClientAuthorizationDUnitTest.java | 35 +-
.../DeltaClientPostAuthorizationDUnitTest.java | 21 +-
.../security/P2PAuthenticationDUnitTest.java | 43 +-
.../gemfire/security/SecurityTestUtil.java | 190 +++--
.../com/gemstone/gemfire/test/dunit/Assert.java | 3 +-
.../gemfire/test/dunit/AsyncInvocation.java | 6 +-
.../gemfire/test/dunit/DebuggerSupport.java | 28 +
.../test/dunit/DistributedSystemSupport.java | 82 ++
.../gemfire/test/dunit/DistributedTestCase.java | 855 +------------------
.../test/dunit/DistributedTestSupport.java | 106 +++
.../gemfire/test/dunit/IgnoredException.java | 36 +-
.../com/gemstone/gemfire/test/dunit/Invoke.java | 110 ++-
.../gemfire/test/dunit/LogWriterSupport.java | 72 ++
.../gemfire/test/dunit/NetworkSupport.java | 43 +
.../test/dunit/StoppableWaitCriterion.java | 16 +
.../gemstone/gemfire/test/dunit/Threads.java | 128 +++
.../com/gemstone/gemfire/test/dunit/VM.java | 10 +
.../com/gemstone/gemfire/test/dunit/Wait.java | 192 +++++
.../gemfire/test/dunit/WaitCriterion.java | 16 +
.../dunit/rules/DistributedDisconnectRule.java | 121 +++
.../rules/DistributedExternalResource.java | 58 ++
.../DistributedRestoreSystemProperties.java | 74 ++
.../gemfire/test/dunit/rules/RemoteInvoker.java | 39 +
.../test/examples/AssertJExampleJUnitTest.java | 135 +++
.../CatchExceptionExampleJUnitTest.java | 115 +++
.../examples/JUnitParamsExampleJUnitTest.java | 52 ++
.../cache/query/cq/dunit/CqDataDUnitTest.java | 90 +-
.../dunit/CqDataOptimizedExecuteDUnitTest.java | 8 +-
.../cq/dunit/CqDataUsingPoolDUnitTest.java | 99 ++-
...qDataUsingPoolOptimizedExecuteDUnitTest.java | 10 +-
.../cache/query/cq/dunit/CqPerfDUnitTest.java | 79 +-
.../cq/dunit/CqPerfUsingPoolDUnitTest.java | 77 +-
.../cache/query/cq/dunit/CqQueryDUnitTest.java | 327 +++----
.../dunit/CqQueryOptimizedExecuteDUnitTest.java | 22 +-
.../cq/dunit/CqQueryUsingPoolDUnitTest.java | 328 +++----
...QueryUsingPoolOptimizedExecuteDUnitTest.java | 5 +-
.../cq/dunit/CqResultSetUsingPoolDUnitTest.java | 77 +-
...ltSetUsingPoolOptimizedExecuteDUnitTest.java | 27 +-
.../cache/query/cq/dunit/CqStateDUnitTest.java | 17 +-
.../cache/query/cq/dunit/CqStatsDUnitTest.java | 34 +-
.../dunit/CqStatsOptimizedExecuteDUnitTest.java | 5 +-
.../cq/dunit/CqStatsUsingPoolDUnitTest.java | 34 +-
...StatsUsingPoolOptimizedExecuteDUnitTest.java | 5 +-
.../query/cq/dunit/CqTimeTestListener.java | 14 +-
.../PartitionedRegionCqQueryDUnitTest.java | 72 +-
...dRegionCqQueryOptimizedExecuteDUnitTest.java | 15 +-
.../query/cq/dunit/PrCqUsingPoolDUnitTest.java | 62 +-
.../PrCqUsingPoolOptimizedExecuteDUnitTest.java | 5 +-
.../cache/query/dunit/PdxQueryCQDUnitTest.java | 46 +-
.../cache/query/dunit/PdxQueryCQTestBase.java | 29 +-
.../dunit/QueryIndexUpdateRIDUnitTest.java | 72 +-
.../query/dunit/QueryMonitorDUnitTest.java | 45 +-
.../cache/snapshot/ClientSnapshotDUnitTest.java | 6 +-
.../cache/PRDeltaPropagationDUnitTest.java | 12 +-
.../internal/cache/PutAllCSDUnitTest.java | 401 ++++-----
.../cache/RemoteCQTransactionDUnitTest.java | 10 +-
.../internal/cache/ha/CQListGIIDUnitTest.java | 49 +-
.../cache/ha/HADispatcherDUnitTest.java | 18 +-
.../sockets/ClientToServerDeltaDUnitTest.java | 23 +-
.../DeltaPropagationWithCQDUnitTest.java | 15 +-
...ToRegionRelationCQRegistrationDUnitTest.java | 27 +-
.../sockets/DurableClientSimpleDUnitTest.java | 69 +-
.../tier/sockets/DurableClientTestCase.java | 84 +-
.../CacheServerManagementDUnitTest.java | 40 +-
.../cli/commands/ClientCommandsDUnitTest.java | 27 +-
.../DurableClientCommandsDUnitTest.java | 9 +-
.../internal/pulse/TestCQDUnitTest.java | 12 +-
.../internal/pulse/TestClientsDUnitTest.java | 10 +-
.../internal/pulse/TestServerDUnitTest.java | 7 +-
.../ClientAuthorizationTwoDUnitTest.java | 11 +-
.../security/ClientAuthzObjectModDUnitTest.java | 9 +-
.../ClientCQPostAuthorizationDUnitTest.java | 35 +-
.../ClientPostAuthorizationDUnitTest.java | 15 +-
.../gemfire/security/MultiuserAPIDUnitTest.java | 16 +-
.../MultiuserDurableCQAuthzDUnitTest.java | 22 +-
.../internal/cache/UpdateVersionDUnitTest.java | 41 +-
.../gemfire/internal/cache/wan/WANTestBase.java | 263 +++---
...oncurrentParallelGatewaySenderDUnitTest.java | 17 +-
...allelGatewaySenderOperation_1_DUnitTest.java | 61 +-
...allelGatewaySenderOperation_2_DUnitTest.java | 48 +-
.../ConcurrentWANPropogation_1_DUnitTest.java | 32 +-
.../ConcurrentWANPropogation_2_DUnitTest.java | 12 +-
.../cache/wan/disttx/DistTXWANDUnitTest.java | 6 +-
.../CommonParallelGatewaySenderDUnitTest.java | 30 +-
...wWANConcurrencyCheckForDestroyDUnitTest.java | 44 +-
.../cache/wan/misc/PDXNewWanDUnitTest.java | 16 +-
...dRegion_ParallelWANPersistenceDUnitTest.java | 53 +-
...dRegion_ParallelWANPropogationDUnitTest.java | 56 +-
...downAllPersistentGatewaySenderDUnitTest.java | 14 +-
.../wan/misc/WANLocatorServerDUnitTest.java | 6 +-
.../cache/wan/misc/WANSSLDUnitTest.java | 16 +-
.../wan/misc/WanAutoDiscoveryDUnitTest.java | 10 +-
.../cache/wan/misc/WanValidationsDUnitTest.java | 80 +-
...arallelGatewaySenderOperationsDUnitTest.java | 63 +-
...llelGatewaySenderQueueOverflowDUnitTest.java | 31 +-
.../ParallelWANConflationDUnitTest.java | 3 +-
...ersistenceEnabledGatewaySenderDUnitTest.java | 185 ++--
...lelWANPropagationConcurrentOpsDUnitTest.java | 7 +-
.../ParallelWANPropagationDUnitTest.java | 35 +-
...ParallelWANPropagationLoopBackDUnitTest.java | 7 +-
.../wan/parallel/ParallelWANStatsDUnitTest.java | 16 +-
...tewaySenderDistributedDeadlockDUnitTest.java | 13 +-
...rialGatewaySenderEventListenerDUnitTest.java | 7 +-
.../SerialGatewaySenderOperationsDUnitTest.java | 26 +-
.../SerialGatewaySenderQueueDUnitTest.java | 24 +-
...ersistenceEnabledGatewaySenderDUnitTest.java | 70 +-
.../SerialWANPropagationLoopBackDUnitTest.java | 11 +-
.../serial/SerialWANPropogationDUnitTest.java | 101 +--
...NPropogation_PartitionedRegionDUnitTest.java | 13 +-
.../wan/serial/SerialWANStatsDUnitTest.java | 28 +-
.../wan/wancommand/WANCommandTestBase.java | 10 +-
.../WanCommandCreateGatewaySenderDUnitTest.java | 5 +-
...WanCommandGatewayReceiverStartDUnitTest.java | 9 +-
.../WanCommandGatewayReceiverStopDUnitTest.java | 9 +-
.../WanCommandGatewaySenderStartDUnitTest.java | 14 +-
.../WanCommandGatewaySenderStopDUnitTest.java | 12 +-
.../wan/wancommand/WanCommandListDUnitTest.java | 11 +-
.../WanCommandPauseResumeDUnitTest.java | 17 +-
.../wancommand/WanCommandStatusDUnitTest.java | 25 +-
.../management/WANManagementDUnitTest.java | 3 +-
.../ClusterConfigurationDUnitTest.java | 20 +-
.../pulse/TestRemoteClusterDUnitTest.java | 7 +-
563 files changed, 9833 insertions(+), 8139 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/main/java/com/gemstone/gemfire/internal/util/DebuggerSupport.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/main/java/com/gemstone/gemfire/internal/util/DebuggerSupport.java b/gemfire-core/src/main/java/com/gemstone/gemfire/internal/util/DebuggerSupport.java
index 49ce32e..3df61ec 100644
--- a/gemfire-core/src/main/java/com/gemstone/gemfire/internal/util/DebuggerSupport.java
+++ b/gemfire-core/src/main/java/com/gemstone/gemfire/internal/util/DebuggerSupport.java
@@ -14,11 +14,13 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-
package com.gemstone.gemfire.internal.util;
-import com.gemstone.gemfire.i18n.LogWriterI18n;
+import org.apache.logging.log4j.Logger;
+
import com.gemstone.gemfire.internal.i18n.LocalizedStrings;
+import com.gemstone.gemfire.internal.logging.LogService;
+import com.gemstone.gemfire.internal.logging.log4j.LocalizedMessage;
/**
*
@@ -26,23 +28,24 @@ import com.gemstone.gemfire.internal.i18n.LocalizedStrings;
*
*/
public abstract class DebuggerSupport {
+ private static final Logger logger = LogService.getLogger();
/** Creates a new instance of DebuggerSupport */
private DebuggerSupport() {
}
/** Debugger support */
- public static void waitForJavaDebugger(LogWriterI18n logger) {
- waitForJavaDebugger(logger, null);
+ public static void waitForJavaDebugger() {
+ waitForJavaDebugger(null);
}
@edu.umd.cs.findbugs.annotations.SuppressWarnings(value="IL_INFINITE_LOOP", justification="Endless loop is for debugging purposes.")
- public static void waitForJavaDebugger(LogWriterI18n logger, String extraLogMsg) {
+ public static void waitForJavaDebugger(String extraLogMsg) {
boolean cont = false;
String msg = ":";
if (extraLogMsg != null)
msg += extraLogMsg;
- logger.severe(LocalizedStrings.DebuggerSupport_WAITING_FOR_DEBUGGER_TO_ATTACH_0, msg);
+ logger.fatal(LocalizedMessage.create(LocalizedStrings.DebuggerSupport_WAITING_FOR_DEBUGGER_TO_ATTACH_0, msg));
boolean interrupted = false;
while (!cont) { // set cont to true in debugger when ready to continue
try {
@@ -57,6 +60,6 @@ public abstract class DebuggerSupport {
if (interrupted) {
Thread.currentThread().interrupt();
}
- logger.info(LocalizedStrings.DebuggerSupport_DEBUGGER_CONTINUING);
+ logger.info(LocalizedMessage.create(LocalizedStrings.DebuggerSupport_DEBUGGER_CONTINUING));
}
}
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/test/java/com/gemstone/gemfire/TXExpiryJUnitTest.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/test/java/com/gemstone/gemfire/TXExpiryJUnitTest.java b/gemfire-core/src/test/java/com/gemstone/gemfire/TXExpiryJUnitTest.java
index 674f0c9..d396877 100644
--- a/gemfire-core/src/test/java/com/gemstone/gemfire/TXExpiryJUnitTest.java
+++ b/gemfire-core/src/test/java/com/gemstone/gemfire/TXExpiryJUnitTest.java
@@ -51,8 +51,8 @@ import com.gemstone.gemfire.internal.cache.GemFireCacheImpl;
import com.gemstone.gemfire.internal.cache.LocalRegion;
import com.gemstone.gemfire.internal.cache.TXManagerImpl;
import com.gemstone.gemfire.internal.cache.TXStateProxy;
-import com.gemstone.gemfire.test.dunit.DistributedTestCase;
-import com.gemstone.gemfire.test.dunit.DistributedTestCase.WaitCriterion;
+import com.gemstone.gemfire.test.dunit.Wait;
+import com.gemstone.gemfire.test.dunit.WaitCriterion;
import com.gemstone.gemfire.test.junit.categories.IntegrationTest;
/**
@@ -247,7 +247,7 @@ public class TXExpiryJUnitTest {
return "never saw entry destroy of " + key;
}
};
- DistributedTestCase.waitForCriterion(waitForExpire, 3000, 10, true);
+ Wait.waitForCriterion(waitForExpire, 3000, 10, true);
}
public static void waitForEntryExpiration(LocalRegion lr, String key) {
@@ -257,7 +257,7 @@ public class TXExpiryJUnitTest {
detector = new ExpirationDetector(lr.getEntryExpiryTask(key));
ExpiryTask.expiryTaskListener = detector;
ExpiryTask.permitExpiration();
- DistributedTestCase.waitForCriterion(detector, 3000, 2, true);
+ Wait.waitForCriterion(detector, 3000, 2, true);
} while (!detector.hasExpired() && detector.wasRescheduled());
} finally {
ExpiryTask.expiryTaskListener = null;
@@ -270,7 +270,7 @@ public class TXExpiryJUnitTest {
detector = new ExpirationDetector(ttl ? lr.getRegionTTLExpiryTask() : lr.getRegionIdleExpiryTask());
ExpiryTask.expiryTaskListener = detector;
ExpiryTask.permitExpiration();
- DistributedTestCase.waitForCriterion(detector, 3000, 2, true);
+ Wait.waitForCriterion(detector, 3000, 2, true);
} while (!detector.hasExpired() && detector.wasRescheduled());
} finally {
ExpiryTask.expiryTaskListener = null;
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/test/java/com/gemstone/gemfire/cache/CacheRegionClearStatsDUnitTest.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/CacheRegionClearStatsDUnitTest.java b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/CacheRegionClearStatsDUnitTest.java
index ea58055..a1af48c 100755
--- a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/CacheRegionClearStatsDUnitTest.java
+++ b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/CacheRegionClearStatsDUnitTest.java
@@ -28,6 +28,7 @@ import com.gemstone.gemfire.internal.cache.GemFireCacheImpl;
import com.gemstone.gemfire.test.dunit.Assert;
import com.gemstone.gemfire.test.dunit.DistributedTestCase;
import com.gemstone.gemfire.test.dunit.Host;
+import com.gemstone.gemfire.test.dunit.NetworkSupport;
import com.gemstone.gemfire.test.dunit.VM;
/**
* verifies the count of clear operation
@@ -152,7 +153,7 @@ public class CacheRegionClearStatsDUnitTest extends DistributedTestCase {
client1.invoke(CacheRegionClearStatsDUnitTest.class,
"createClientCache", new Object[] {
- getServerHostName(server1.getHost()), port1 });
+ NetworkSupport.getServerHostName(server1.getHost()), port1 });
client1.invoke(CacheRegionClearStatsDUnitTest.class, "put");
try{
@@ -177,7 +178,7 @@ public class CacheRegionClearStatsDUnitTest extends DistributedTestCase {
client1.invoke(CacheRegionClearStatsDUnitTest.class,
"createClientCacheDisk", new Object[] {
- getServerHostName(server1.getHost()), port1 });
+ NetworkSupport.getServerHostName(server1.getHost()), port1 });
client1.invoke(CacheRegionClearStatsDUnitTest.class, "put");
try{
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/test/java/com/gemstone/gemfire/cache/ClientServerTimeSyncDUnitTest.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/ClientServerTimeSyncDUnitTest.java b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/ClientServerTimeSyncDUnitTest.java
index eb74d0d..7e21875 100755
--- a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/ClientServerTimeSyncDUnitTest.java
+++ b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/ClientServerTimeSyncDUnitTest.java
@@ -31,8 +31,12 @@ import com.gemstone.gemfire.internal.AvailablePortHelper;
import com.gemstone.gemfire.internal.cache.GemFireCacheImpl;
import com.gemstone.gemfire.test.dunit.Assert;
import com.gemstone.gemfire.test.dunit.Host;
+import com.gemstone.gemfire.test.dunit.LogWriterSupport;
+import com.gemstone.gemfire.test.dunit.NetworkSupport;
import com.gemstone.gemfire.test.dunit.SerializableCallable;
import com.gemstone.gemfire.test.dunit.VM;
+import com.gemstone.gemfire.test.dunit.Wait;
+import com.gemstone.gemfire.test.dunit.WaitCriterion;
public class ClientServerTimeSyncDUnitTest extends CacheTestCase {
@@ -59,7 +63,7 @@ public class ClientServerTimeSyncDUnitTest extends CacheTestCase {
public Object call() {
Cache cache = getCache();
cache.createRegionFactory(RegionShortcut.REPLICATE).create(regionName);
- getLogWriter().info("Done creating region, now creating CacheServer");
+ LogWriterSupport.getLogWriter().info("Done creating region, now creating CacheServer");
CacheServer server = null;
try {
server = cache.addCacheServer();
@@ -72,12 +76,12 @@ public class ClientServerTimeSyncDUnitTest extends CacheTestCase {
// now set an artificial time offset for the test
system.getClock().setCacheTimeOffset(null, TEST_OFFSET, true);
- getLogWriter().info("Done creating and starting CacheServer on port " + server.getPort());
+ LogWriterSupport.getLogWriter().info("Done creating and starting CacheServer on port " + server.getPort());
return server.getPort();
}
});
- final String hostName = getServerHostName(vm0.getHost());
+ final String hostName = NetworkSupport.getServerHostName(vm0.getHost());
// Start client with proxy region and register interest
@@ -99,14 +103,14 @@ public class ClientServerTimeSyncDUnitTest extends CacheTestCase {
WaitCriterion wc = new WaitCriterion() {
public boolean done() {
long clientTimeOffset = clock.getCacheTimeOffset();
- getLogWriter().info("Client node's new time offset is: " + clientTimeOffset);
+ LogWriterSupport.getLogWriter().info("Client node's new time offset is: " + clientTimeOffset);
return clientTimeOffset >= TEST_OFFSET;
}
public String description() {
return "Waiting for cacheTimeOffset to be non-zero. PingOp should have set it to something";
}
};
- waitForCriterion(wc, 60000, 1000, true);
+ Wait.waitForCriterion(wc, 60000, 1000, true);
} finally {
cache.close();
vm1.invoke(CacheTestCase.class, "disconnectFromDS");
@@ -136,7 +140,7 @@ public class ClientServerTimeSyncDUnitTest extends CacheTestCase {
public Object call() {
Cache cache = getCache();
cache.createRegionFactory(RegionShortcut.REPLICATE).create(regionName);
- getLogWriter().info("Done creating region, now creating CacheServer");
+ LogWriterSupport.getLogWriter().info("Done creating region, now creating CacheServer");
CacheServer server = null;
try {
server = cache.addCacheServer();
@@ -149,14 +153,14 @@ public class ClientServerTimeSyncDUnitTest extends CacheTestCase {
// now set an artificial time offset for the test
system.getClock().setCacheTimeOffset(null, -TEST_OFFSET, true);
- getLogWriter().info("Done creating and starting CacheServer on port " + server.getPort());
+ LogWriterSupport.getLogWriter().info("Done creating and starting CacheServer on port " + server.getPort());
return server.getPort();
}
});
- pause((int)TEST_OFFSET); // let cacheTimeMillis consume the time offset
+ Wait.pause((int)TEST_OFFSET); // let cacheTimeMillis consume the time offset
- final String hostName = getServerHostName(vm0.getHost());
+ final String hostName = NetworkSupport.getServerHostName(vm0.getHost());
// Start client with proxy region and register interest
@@ -178,7 +182,7 @@ public class ClientServerTimeSyncDUnitTest extends CacheTestCase {
WaitCriterion wc = new WaitCriterion() {
public boolean done() {
long clientTimeOffset = clock.getCacheTimeOffset();
- getLogWriter().info("Client node's new time offset is: " + clientTimeOffset);
+ LogWriterSupport.getLogWriter().info("Client node's new time offset is: " + clientTimeOffset);
if (clientTimeOffset >= 0) {
return false;
}
@@ -189,7 +193,7 @@ public class ClientServerTimeSyncDUnitTest extends CacheTestCase {
return "Waiting for cacheTimeOffset to be negative and cacheTimeMillis to stabilize";
}
};
- waitForCriterion(wc, 60000, 1000, true);
+ Wait.waitForCriterion(wc, 60000, 1000, true);
} finally {
cache.close();
vm1.invoke(CacheTestCase.class, "disconnectFromDS");
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/test/java/com/gemstone/gemfire/cache/ConnectionPoolAndLoaderDUnitTest.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/ConnectionPoolAndLoaderDUnitTest.java b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/ConnectionPoolAndLoaderDUnitTest.java
index 677ab14..bec1c1e 100644
--- a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/ConnectionPoolAndLoaderDUnitTest.java
+++ b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/ConnectionPoolAndLoaderDUnitTest.java
@@ -28,6 +28,7 @@ import com.gemstone.gemfire.cache.util.CacheWriterAdapter;
import com.gemstone.gemfire.cache30.CacheTestCase;
import com.gemstone.gemfire.internal.AvailablePort;
import com.gemstone.gemfire.test.dunit.Host;
+import com.gemstone.gemfire.test.dunit.NetworkSupport;
import com.gemstone.gemfire.test.dunit.SerializableCallable;
import com.gemstone.gemfire.test.dunit.SerializableRunnable;
import com.gemstone.gemfire.test.dunit.VM;
@@ -92,7 +93,7 @@ public class ConnectionPoolAndLoaderDUnitTest extends CacheTestCase {
public Object call() {
Cache cache = getCache();
PoolFactory factory = PoolManager.createFactory();
- factory.addServer(getServerHostName(host), serverPort);
+ factory.addServer(NetworkSupport.getServerHostName(host), serverPort);
factory.create("pool1");
AttributesFactory af = new AttributesFactory();
@@ -171,7 +172,7 @@ public class ConnectionPoolAndLoaderDUnitTest extends CacheTestCase {
public Object call() {
Cache cache = getCache();
PoolFactory factory = PoolManager.createFactory();
- factory.addServer(getServerHostName(host), serverPort);
+ factory.addServer(NetworkSupport.getServerHostName(host), serverPort);
factory.create("pool1");
AttributesFactory af = new AttributesFactory();
@@ -281,7 +282,7 @@ public class ConnectionPoolAndLoaderDUnitTest extends CacheTestCase {
Cache cache = getCache();
useLocator = false;
PoolFactory factory = PoolManager.createFactory();
- factory.addServer(getServerHostName(host), serverPort);
+ factory.addServer(NetworkSupport.getServerHostName(host), serverPort);
factory.create("pool1");
AttributesFactory af = new AttributesFactory();
af.setDataPolicy(DataPolicy.NORMAL);
@@ -303,7 +304,7 @@ public class ConnectionPoolAndLoaderDUnitTest extends CacheTestCase {
Cache cache = getCache();
useLocator = false;
PoolFactory factory = PoolManager.createFactory();
- factory.addServer(getServerHostName(host), serverPort);
+ factory.addServer(NetworkSupport.getServerHostName(host), serverPort);
factory.create("pool1");
AttributesFactory af = new AttributesFactory();
af.setDataPolicy(DataPolicy.NORMAL);
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/ClientServerRegisterInterestsDUnitTest.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/ClientServerRegisterInterestsDUnitTest.java b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/ClientServerRegisterInterestsDUnitTest.java
index c24cd44..80ed952 100644
--- a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/ClientServerRegisterInterestsDUnitTest.java
+++ b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/ClientServerRegisterInterestsDUnitTest.java
@@ -69,7 +69,7 @@ public class ClientServerRegisterInterestsDUnitTest extends DistributedTestCase
super.setUp();
disconnectAllFromDS();
setupGemFireCacheServer();
- IgnoredException.addExpectedException("java.net.ConnectException");
+ IgnoredException.addIgnoredException("java.net.ConnectException");
}
@Override
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/AutoConnectionSourceDUnitTest.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/AutoConnectionSourceDUnitTest.java b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/AutoConnectionSourceDUnitTest.java
index 30b40be..374950d 100644
--- a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/AutoConnectionSourceDUnitTest.java
+++ b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/AutoConnectionSourceDUnitTest.java
@@ -38,9 +38,11 @@ import com.gemstone.gemfire.management.membership.ClientMembershipEvent;
import com.gemstone.gemfire.management.membership.ClientMembershipListenerAdapter;
import com.gemstone.gemfire.test.dunit.Host;
import com.gemstone.gemfire.test.dunit.IgnoredException;
+import com.gemstone.gemfire.test.dunit.NetworkSupport;
import com.gemstone.gemfire.test.dunit.SerializableCallable;
import com.gemstone.gemfire.test.dunit.SerializableRunnable;
import com.gemstone.gemfire.test.dunit.VM;
+import com.gemstone.gemfire.test.dunit.Wait;
/**
* Tests cases that are particular for the auto connection source
@@ -56,7 +58,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
public void setUp() throws Exception {
super.setUp();
- IgnoredException.addExpectedException("NoAvailableLocatorsException");
+ IgnoredException.addIgnoredException("NoAvailableLocatorsException");
}
public AutoConnectionSourceDUnitTest(String name) {
@@ -72,11 +74,11 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
int locatorPort = AvailablePort.getRandomAvailablePort(AvailablePort.SOCKET);
startLocatorInVM(vm0, locatorPort, "");
- String locators = getServerHostName(vm0.getHost())+ "[" + locatorPort + "]";
+ String locators = NetworkSupport.getServerHostName(vm0.getHost())+ "[" + locatorPort + "]";
startBridgeServerInVM(vm1, null, locators);
- startBridgeClientInVM(vm2, null, getServerHostName(vm0.getHost()), locatorPort);
+ startBridgeClientInVM(vm2, null, NetworkSupport.getServerHostName(vm0.getHost()), locatorPort);
putAndWaitForSuccess(vm2, REGION_NAME, "key", "value");
@@ -89,7 +91,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
VM vm0 = host.getVM(0);
try {
- startBridgeClientInVM(vm0, null, getServerHostName(vm0.getHost()), AvailablePort.getRandomAvailablePort(AvailablePort.SOCKET));
+ startBridgeClientInVM(vm0, null, NetworkSupport.getServerHostName(vm0.getHost()), AvailablePort.getRandomAvailablePort(AvailablePort.SOCKET));
putInVM(vm0, "key", "value");
fail("Client cache should not have been able to start");
} catch(Exception e) {
@@ -105,7 +107,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
int locatorPort = AvailablePort.getRandomAvailablePort(AvailablePort.SOCKET);
startLocatorInVM(vm0, locatorPort, "");
try {
- startBridgeClientInVM(vm1, null, getServerHostName(vm0.getHost()), locatorPort);
+ startBridgeClientInVM(vm1, null, NetworkSupport.getServerHostName(vm0.getHost()), locatorPort);
putInVM(vm0, "key", "value");
fail("Client cache should not have been able to start");
} catch(Exception e) {
@@ -123,11 +125,11 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
int locatorPort = AvailablePort.getRandomAvailablePort(AvailablePort.SOCKET);
startLocatorInVM(vm0, locatorPort, "");
- String locators = getServerHostName(vm0.getHost()) + "[" + locatorPort + "]";
+ String locators = NetworkSupport.getServerHostName(vm0.getHost()) + "[" + locatorPort + "]";
startBridgeServerInVM(vm1, null, locators);
- startBridgeClientInVM(vm2, null, getServerHostName(vm0.getHost()), locatorPort);
+ startBridgeClientInVM(vm2, null, NetworkSupport.getServerHostName(vm0.getHost()), locatorPort);
putAndWaitForSuccess(vm2, REGION_NAME, "key", "value");
@@ -142,7 +144,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
public void testDynamicallyFindLocators() throws Exception {
final Host host = Host.getHost(0);
- final String hostName = getServerHostName(host);
+ final String hostName = NetworkSupport.getServerHostName(host);
VM vm0 = host.getVM(0);
VM vm1 = host.getVM(1);
VM vm2 = host.getVM(2);
@@ -157,7 +159,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
startLocatorInVM(vm0, locatorPort0, locators);
startLocatorInVM(vm1, locatorPort1, locators);
- startBridgeClientInVM(vm2, null, getServerHostName(vm0.getHost()), locatorPort0);
+ startBridgeClientInVM(vm2, null, NetworkSupport.getServerHostName(vm0.getHost()), locatorPort0);
InetSocketAddress locatorToWaitFor= new InetSocketAddress(hostName, locatorPort1);
waitForLocatorDiscovery(vm2, locatorToWaitFor);
@@ -188,11 +190,11 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
int locatorPort = AvailablePort.getRandomAvailablePort(AvailablePort.SOCKET);
- String locators = getServerHostName(vm0.getHost()) + "[" + locatorPort + "]";
+ String locators = NetworkSupport.getServerHostName(vm0.getHost()) + "[" + locatorPort + "]";
startBridgeServerWithEmbeddedLocator(vm0, null, locators, new String[] {REGION_NAME}, CacheServer.DEFAULT_LOAD_PROBE);
- startBridgeClientInVM(vm2, null, getServerHostName(vm0.getHost()), locatorPort);
+ startBridgeClientInVM(vm2, null, NetworkSupport.getServerHostName(vm0.getHost()), locatorPort);
putAndWaitForSuccess(vm2, REGION_NAME, "key", "value");
@@ -224,13 +226,13 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
int locatorPort = AvailablePort.getRandomAvailablePort(AvailablePort.SOCKET);
startLocatorInVM(vm0, locatorPort, "");
- String locators = getServerHostName(vm0.getHost()) + "[" + locatorPort + "]";
+ String locators = NetworkSupport.getServerHostName(vm0.getHost()) + "[" + locatorPort + "]";
startBridgeServerInVM(vm1, new String[] {"group1", "group2"} , locators, new String[] {"A", "B"});
startBridgeServerInVM(vm2, new String[] {"group2", "group3"}, locators, new String[] {"B", "C"});
- startBridgeClientInVM(vm3, "group1", getServerHostName(vm0.getHost()), locatorPort, new String [] {"A", "B", "C"});
+ startBridgeClientInVM(vm3, "group1", NetworkSupport.getServerHostName(vm0.getHost()), locatorPort, new String [] {"A", "B", "C"});
putAndWaitForSuccess(vm3, "A", "key", "value");
Assert.assertEquals("value", getInVM(vm1, "A", "key"));
try {
@@ -240,7 +242,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
stopBridgeMemberVM(vm3);
- startBridgeClientInVM(vm3, "group3", getServerHostName(vm0.getHost()), locatorPort, new String [] {"A", "B", "C"});
+ startBridgeClientInVM(vm3, "group3", NetworkSupport.getServerHostName(vm0.getHost()), locatorPort, new String [] {"A", "B", "C"});
try {
putInVM(vm3, "A", "key3", "value");
fail("Should not have been able to find Region A on the server");
@@ -250,7 +252,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
stopBridgeMemberVM(vm3);
- startBridgeClientInVM(vm3, "group2", getServerHostName(vm0.getHost()), locatorPort, new String [] {"A", "B", "C"});
+ startBridgeClientInVM(vm3, "group2", NetworkSupport.getServerHostName(vm0.getHost()), locatorPort, new String [] {"A", "B", "C"});
putInVM(vm3, "B", "key5", "value");
Assert.assertEquals("value", getInVM(vm1, "B", "key5"));
Assert.assertEquals("value", getInVM(vm2, "B", "key5"));
@@ -276,18 +278,18 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
startLocatorInVM(vm0, locatorPort, "");
- final String locators = getServerHostName(vm0.getHost()) + "[" + locatorPort + "]";
+ final String locators = NetworkSupport.getServerHostName(vm0.getHost()) + "[" + locatorPort + "]";
final int serverPort1 =startBridgeServerInVM(vm1, new String[] {"group1"}, locators);
final int serverPort2 =addCacheServerInVM(vm1, new String[] {"group2"});
- startBridgeClientInVM(vm2, "group2", getServerHostName(vm0.getHost()), locatorPort);
+ startBridgeClientInVM(vm2, "group2", NetworkSupport.getServerHostName(vm0.getHost()), locatorPort);
checkEndpoints(vm2, new int[] {serverPort2});
stopBridgeMemberVM(vm2);
- startBridgeClientInVM(vm2, "group1", getServerHostName(vm0.getHost()), locatorPort);
+ startBridgeClientInVM(vm2, "group1", NetworkSupport.getServerHostName(vm0.getHost()), locatorPort);
checkEndpoints(vm2, new int[] {serverPort1});
}
@@ -300,7 +302,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
VM clientVM = host.getVM(3);
int locatorPort = AvailablePort.getRandomAvailablePort(AvailablePort.SOCKET);
startLocatorInVM(locatorVM, locatorPort, "");
- String locators = getServerHostName(locatorVM.getHost()) + "[" + locatorPort + "]";
+ String locators = NetworkSupport.getServerHostName(locatorVM.getHost()) + "[" + locatorPort + "]";
//start a bridge server with a listener
addBridgeListener(bridge1VM);
@@ -308,7 +310,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
//start a bridge client with a listener
addBridgeListener(clientVM);
- startBridgeClientInVM(clientVM, null, getServerHostName(locatorVM.getHost()), locatorPort);
+ startBridgeClientInVM(clientVM, null, NetworkSupport.getServerHostName(locatorVM.getHost()), locatorPort);
// wait for client to connect
checkEndpoints(clientVM, new int[] {serverPort1});
@@ -402,7 +404,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
if(remaining <= 0) {
throw e;
}
- pause(100);
+ Wait.pause(100);
remaining = endTime - System.currentTimeMillis();
}
}
@@ -451,7 +453,7 @@ public class AutoConnectionSourceDUnitTest extends LocatorTestBase {
if (expectedEndpointPorts.size() == actualEndpointPorts.size()) {
break;
} else {
- pause(100);
+ Wait.pause(100);
}
} while(retryCount-- > 0);
Assert.assertEquals(expectedEndpointPorts, actualEndpointPorts);
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/CacheServerSSLConnectionDUnitTest.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/CacheServerSSLConnectionDUnitTest.java b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/CacheServerSSLConnectionDUnitTest.java
index f7c0810..58e5620 100644
--- a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/CacheServerSSLConnectionDUnitTest.java
+++ b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/CacheServerSSLConnectionDUnitTest.java
@@ -295,8 +295,8 @@ public class CacheServerSSLConnectionDUnitTest extends DistributedTestCase {
params[3] = cacheClientSslRequireAuth;
params[4] = TRUSTED_STORE;
params[5] = TRUSTED_STORE;
- IgnoredException expect = IgnoredException.addExpectedException("javax.net.ssl.SSLException", serverVM);
- IgnoredException expect2 = IgnoredException.addExpectedException("IOException", serverVM);
+ IgnoredException expect = IgnoredException.addIgnoredException("javax.net.ssl.SSLException", serverVM);
+ IgnoredException expect2 = IgnoredException.addIgnoredException("IOException", serverVM);
try{
//getLogWriter().info("Starting client with server endpoint " + hostName + ":" + port);
clientVM.invoke(CacheServerSSLConnectionDUnitTest.class, "setUpClientVMTaskNoSubscription", params);
@@ -385,7 +385,7 @@ public class CacheServerSSLConnectionDUnitTest extends DistributedTestCase {
params[3] = cacheClientSslRequireAuth;
params[4] = TRUSTED_STORE;
params[5] = TRUSTED_STORE;
- IgnoredException expect = IgnoredException.addExpectedException("javax.net.ssl.SSLHandshakeException", serverVM);
+ IgnoredException expect = IgnoredException.addIgnoredException("javax.net.ssl.SSLHandshakeException", serverVM);
try{
//getLogWriter().info("Starting client with server endpoint " + hostName + ":" + port);
clientVM.invoke(CacheServerSSLConnectionDUnitTest.class, "setUpClientVMTask", params);
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/LocatorLoadBalancingDUnitTest.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/LocatorLoadBalancingDUnitTest.java b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/LocatorLoadBalancingDUnitTest.java
index 1c8e9eb..8ed8baf 100644
--- a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/LocatorLoadBalancingDUnitTest.java
+++ b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/LocatorLoadBalancingDUnitTest.java
@@ -47,11 +47,14 @@ import com.gemstone.gemfire.internal.cache.CacheServerImpl;
import com.gemstone.gemfire.internal.cache.PoolFactoryImpl;
import com.gemstone.gemfire.internal.logging.InternalLogWriter;
import com.gemstone.gemfire.internal.logging.LocalLogWriter;
-import com.gemstone.gemfire.test.dunit.DistributedTestCase;
import com.gemstone.gemfire.test.dunit.Host;
+import com.gemstone.gemfire.test.dunit.LogWriterSupport;
+import com.gemstone.gemfire.test.dunit.NetworkSupport;
import com.gemstone.gemfire.test.dunit.SerializableRunnable;
import com.gemstone.gemfire.test.dunit.SerializableRunnableIF;
import com.gemstone.gemfire.test.dunit.VM;
+import com.gemstone.gemfire.test.dunit.Wait;
+import com.gemstone.gemfire.test.dunit.WaitCriterion;
/**
* @author dsmith
@@ -98,7 +101,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
int serverPort = startBridgeServerInVM(vm1, new String[] {"a", "b"}, locators);
ServerLoad expectedLoad = new ServerLoad(0f, 1 / 800.0f, 0f, 1f);
- ServerLocation expectedLocation = new ServerLocation(getServerHostName(vm0
+ ServerLocation expectedLocation = new ServerLocation(NetworkSupport.getServerHostName(vm0
.getHost()), serverPort);
Map expected = new HashMap();
expected.put(expectedLocation, expectedLoad);
@@ -107,7 +110,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
int serverPort2 = startBridgeServerInVM(vm2, new String[] {"a", "b"}, locators);
- ServerLocation expectedLocation2 = new ServerLocation(getServerHostName(vm0
+ ServerLocation expectedLocation2 = new ServerLocation(NetworkSupport.getServerHostName(vm0
.getHost()), serverPort2);
expected.put(expectedLocation2, expectedLoad);
@@ -130,18 +133,18 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
int serverPort = startBridgeServerInVM(vm1, new String[] {"a", "b"}, locators);
ServerLoad expectedLoad = new ServerLoad(2/800f, 1 / 800.0f, 0f, 1f);
- ServerLocation expectedLocation = new ServerLocation(getServerHostName(host), serverPort);
+ ServerLocation expectedLocation = new ServerLocation(NetworkSupport.getServerHostName(host), serverPort);
Map expected = new HashMap();
expected.put(expectedLocation, expectedLoad);
ClientConnectionResponse response;
response = (ClientConnectionResponse) TcpClient.requestToServer(InetAddress
- .getByName(getServerHostName(host)), locatorPort,
+ .getByName(NetworkSupport.getServerHostName(host)), locatorPort,
new ClientConnectionRequest(Collections.EMPTY_SET, null), 10000);
Assert.assertEquals(expectedLocation, response.getServer());
response = (ClientConnectionResponse) TcpClient.requestToServer(InetAddress
- .getByName(getServerHostName(host)), locatorPort,
+ .getByName(NetworkSupport.getServerHostName(host)), locatorPort,
new ClientConnectionRequest(Collections.EMPTY_SET, null), 10000, true);
Assert.assertEquals(expectedLocation, response.getServer());
@@ -150,13 +153,13 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
QueueConnectionResponse response2;
response2 = (QueueConnectionResponse) TcpClient.requestToServer(InetAddress
- .getByName(getServerHostName(host)), locatorPort,
+ .getByName(NetworkSupport.getServerHostName(host)), locatorPort,
new QueueConnectionRequest(null, 2,
Collections.EMPTY_SET, null, false), 10000, true);
Assert.assertEquals(Collections.singletonList(expectedLocation), response2.getServers());
response2 = (QueueConnectionResponse) TcpClient
- .requestToServer(InetAddress.getByName(getServerHostName(host)),
+ .requestToServer(InetAddress.getByName(NetworkSupport.getServerHostName(host)),
locatorPort, new QueueConnectionRequest(null, 5, Collections.EMPTY_SET, null,
false), 10000, true);
@@ -186,13 +189,13 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
//We expect 0 load
Map expected = new HashMap();
- ServerLocation expectedLocation = new ServerLocation(getServerHostName(host), serverPort);
+ ServerLocation expectedLocation = new ServerLocation(NetworkSupport.getServerHostName(host), serverPort);
ServerLoad expectedLoad = new ServerLoad(0f, 1 / 800.0f, 0f, 1f);
expected.put(expectedLocation, expectedLoad);
checkLocatorLoad(vm0, expected);
PoolFactoryImpl pf = new PoolFactoryImpl(null);
- pf.addServer(getServerHostName(host), serverPort);
+ pf.addServer(NetworkSupport.getServerHostName(host), serverPort);
pf.setMinConnections(8);
pf.setMaxConnections(8);
pf.setSubscriptionEnabled(true);
@@ -233,7 +236,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
startBridgeServerInVM(vm2, new String[] {"a", "b"}, locators);
PoolFactoryImpl pf = new PoolFactoryImpl(null);
- pf.addLocator(getServerHostName(host), locatorPort);
+ pf.addLocator(NetworkSupport.getServerHostName(host), locatorPort);
pf.setMinConnections(80);
pf.setMaxConnections(80);
pf.setSubscriptionEnabled(false);
@@ -267,7 +270,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
return excuse;
}
};
- DistributedTestCase.waitForCriterion(wc, 5 * 60 * 1000, 1000, true);
+ Wait.waitForCriterion(wc, 5 * 60 * 1000, 1000, true);
}
};
@@ -290,7 +293,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
return "connection count never reached " + count;
}
};
- DistributedTestCase.waitForCriterion(ev, MAX_WAIT, 200, true);
+ Wait.waitForCriterion(ev, MAX_WAIT, 200, true);
}
};
if(vm == null) {
@@ -321,7 +324,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
startBridgeServerInVM(vm3, new String[] {"b"}, locators);
PoolFactoryImpl pf = new PoolFactoryImpl(null);
- pf.addLocator(getServerHostName(host), locatorPort);
+ pf.addLocator(NetworkSupport.getServerHostName(host), locatorPort);
pf.setMinConnections(12);
pf.setSubscriptionEnabled(false);
pf.setServerGroup("a");
@@ -333,7 +336,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
checkConnectionCount(vm2, 6);
checkConnectionCount(vm3, 0);
- getLogWriter().info("pool1 prefilled");
+ LogWriterSupport.getLogWriter().info("pool1 prefilled");
PoolFactoryImpl pf2 = (PoolFactoryImpl) PoolManager.createFactory();
pf2.init(pf.getPoolAttributes());
@@ -347,9 +350,9 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
checkConnectionCount(vm2, 9);
checkConnectionCount(vm3, 9);
- getLogWriter().info("pool2 prefilled");
+ LogWriterSupport.getLogWriter().info("pool2 prefilled");
- ServerLocation location1 = new ServerLocation(getServerHostName(host), serverPort1);
+ ServerLocation location1 = new ServerLocation(NetworkSupport.getServerHostName(host), serverPort1);
PoolImpl pool1 = (PoolImpl) PoolManager.getAll().get(POOL_NAME);
Assert.assertEquals("a", pool1.getServerGroup());
@@ -358,7 +361,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
pool1.acquireConnection();
}
- getLogWriter().info("aquired 15 connections in pool1");
+ LogWriterSupport.getLogWriter().info("aquired 15 connections in pool1");
//now the load should be equal
checkConnectionCount(vm1, 9);
@@ -370,7 +373,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
pool2.acquireConnection();
}
- getLogWriter().info("aquired 12 connections in pool2");
+ LogWriterSupport.getLogWriter().info("aquired 12 connections in pool2");
//interleave creating connections in both pools
for(int i = 0; i < 6; i++) {
@@ -378,7 +381,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
pool2.acquireConnection();
}
- getLogWriter().info("interleaved 6 connections from pool1 with 6 connections from pool2");
+ LogWriterSupport.getLogWriter().info("interleaved 6 connections from pool1 with 6 connections from pool2");
//The load should still be balanced
checkConnectionCount(vm1, 13);
@@ -404,8 +407,8 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
int serverPort2 = startBridgeServerInVM(vm2, null, locators, new String[] {REGION_NAME}, new MyLoadProbe(load2 ));
HashMap expected = new HashMap();
- ServerLocation l1 = new ServerLocation(getServerHostName(host), serverPort1);
- ServerLocation l2 = new ServerLocation(getServerHostName(host), serverPort2);
+ ServerLocation l1 = new ServerLocation(NetworkSupport.getServerHostName(host), serverPort1);
+ ServerLocation l2 = new ServerLocation(NetworkSupport.getServerHostName(host), serverPort2);
expected.put(l1, load1);
expected.put(l2, load2);
checkLocatorLoad(vm0, expected);
@@ -425,7 +428,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
checkLocatorLoad(vm0, expected);
PoolFactoryImpl pf = new PoolFactoryImpl(null);
- pf.addLocator(getServerHostName(host), locatorPort);
+ pf.addLocator(NetworkSupport.getServerHostName(host), locatorPort);
pf.setMinConnections(20);
pf.setSubscriptionEnabled(true);
pf.setIdleTimeout(-1);
@@ -455,7 +458,7 @@ public class LocatorLoadBalancingDUnitTest extends LocatorTestBase {
return "load map never became equal to " + expected;
}
};
- DistributedTestCase.waitForCriterion(ev, MAX_WAIT, 200, true);
+ Wait.waitForCriterion(ev, MAX_WAIT, 200, true);
}
});
}
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/LocatorTestBase.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/LocatorTestBase.java b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/LocatorTestBase.java
index 5fbac8c..fb16ce2 100644
--- a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/LocatorTestBase.java
+++ b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/LocatorTestBase.java
@@ -45,6 +45,9 @@ import com.gemstone.gemfire.internal.cache.PoolFactoryImpl;
import com.gemstone.gemfire.test.dunit.Assert;
import com.gemstone.gemfire.test.dunit.DistributedTestCase;
import com.gemstone.gemfire.test.dunit.Host;
+import com.gemstone.gemfire.test.dunit.Invoke;
+import com.gemstone.gemfire.test.dunit.LogWriterSupport;
+import com.gemstone.gemfire.test.dunit.NetworkSupport;
import com.gemstone.gemfire.test.dunit.SerializableCallable;
import com.gemstone.gemfire.test.dunit.SerializableRunnable;
import com.gemstone.gemfire.test.dunit.VM;
@@ -95,7 +98,7 @@ public abstract class LocatorTestBase extends DistributedTestCase {
};
//We seem to like leaving the DS open if we can for
//speed, but lets at least destroy our cache and locator.
- invokeInEveryVM(tearDown);
+ Invoke.invokeInEveryVM(tearDown);
tearDown.run();
super.tearDown2();
}
@@ -109,14 +112,14 @@ public abstract class LocatorTestBase extends DistributedTestCase {
Properties props = new Properties();
props.setProperty(DistributionConfig.MCAST_PORT_NAME, String.valueOf(0));
props.setProperty(DistributionConfig.LOCATORS_NAME, otherLocators);
- props.setProperty(DistributionConfig.LOG_LEVEL_NAME, getDUnitLogLevel());
+ props.setProperty(DistributionConfig.LOG_LEVEL_NAME, LogWriterSupport.getDUnitLogLevel());
props.setProperty(DistributionConfig.ENABLE_CLUSTER_CONFIGURATION_NAME, "false");
try {
File logFile = new File(testName + "-locator" + locatorPort
+ ".log");
InetAddress bindAddr = null;
try {
- bindAddr = InetAddress.getByName(getServerHostName(vm.getHost()));
+ bindAddr = InetAddress.getByName(NetworkSupport.getServerHostName(vm.getHost()));
} catch (UnknownHostException uhe) {
Assert.fail("While resolving bind address ", uhe);
}
@@ -303,7 +306,7 @@ public abstract class LocatorTestBase extends DistributedTestCase {
public String getLocatorString(Host host, int[] locatorPorts) {
StringBuffer str = new StringBuffer();
for(int i = 0; i < locatorPorts.length; i++) {
- str.append(getServerHostName(host))
+ str.append(NetworkSupport.getServerHostName(host))
.append("[")
.append(locatorPorts[i])
.append("]");
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/76e324b5/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/pooling/ConnectionManagerJUnitTest.java
----------------------------------------------------------------------
diff --git a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/pooling/ConnectionManagerJUnitTest.java b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/pooling/ConnectionManagerJUnitTest.java
index a398975..03a170c 100644
--- a/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/pooling/ConnectionManagerJUnitTest.java
+++ b/gemfire-core/src/test/java/com/gemstone/gemfire/cache/client/internal/pooling/ConnectionManagerJUnitTest.java
@@ -59,8 +59,9 @@ import com.gemstone.gemfire.internal.cache.PoolStats;
import com.gemstone.gemfire.internal.cache.tier.sockets.ServerQueueStatus;
import com.gemstone.gemfire.internal.logging.InternalLogWriter;
import com.gemstone.gemfire.internal.logging.LocalLogWriter;
-import com.gemstone.gemfire.test.dunit.DistributedTestCase;
-import com.gemstone.gemfire.test.dunit.DistributedTestCase.WaitCriterion;
+import com.gemstone.gemfire.test.dunit.Threads;
+import com.gemstone.gemfire.test.dunit.Wait;
+import com.gemstone.gemfire.test.dunit.WaitCriterion;
import com.gemstone.gemfire.test.junit.categories.IntegrationTest;
/**
@@ -159,7 +160,7 @@ public class ConnectionManagerJUnitTest {
return "waiting for manager " + descrip;
}
};
- DistributedTestCase.waitForCriterion(ev, 200, 200, true);
+ Wait.waitForCriterion(ev, 200, 200, true);
}
@Test
@@ -426,7 +427,7 @@ public class ConnectionManagerJUnitTest {
}
for(int i = 0; i < updaterCount; i++) {
- DistributedTestCase.join(updaters[i], 30 * 1000, null);
+ Threads.join(updaters[i], 30 * 1000, null);
}
if(exception.get() !=null) {
@@ -490,7 +491,7 @@ public class ConnectionManagerJUnitTest {
}
for(int i = 0; i < updaterCount; i++) {
- DistributedTestCase.join(updaters[i], 30 * 1000, null);
+ Threads.join(updaters[i], 30 * 1000, null);
}
if(exception.get() !=null) {