Search in sources :

Example 11 with BackupAwareOperation

use of com.hazelcast.spi.impl.operationservice.BackupAwareOperation in project hazelcast by hazelcast.

the class OperationBackupHandlerTest method backup_whenTooLargeAsyncBackupCount.

@Test(expected = IllegalArgumentException.class)
public void backup_whenTooLargeAsyncBackupCount() throws Exception {
    setup(BACKPRESSURE_ENABLED);
    BackupAwareOperation op = makeOperation(0, MAX_BACKUP_COUNT + 1);
    backupHandler.sendBackups0(op);
}
Also used : BackupAwareOperation(com.hazelcast.spi.impl.operationservice.BackupAwareOperation) ParallelJVMTest(com.hazelcast.test.annotation.ParallelJVMTest) QuickTest(com.hazelcast.test.annotation.QuickTest) Test(org.junit.Test)

Example 12 with BackupAwareOperation

use of com.hazelcast.spi.impl.operationservice.BackupAwareOperation in project hazelcast by hazelcast.

the class OperationBackupHandlerTest method backup_whenNegativeSyncBackupCount.

// ============================ backup =================================
@Test(expected = IllegalArgumentException.class)
public void backup_whenNegativeSyncBackupCount() throws Exception {
    setup(BACKPRESSURE_ENABLED);
    BackupAwareOperation op = makeOperation(-1, 0);
    backupHandler.sendBackups0(op);
}
Also used : BackupAwareOperation(com.hazelcast.spi.impl.operationservice.BackupAwareOperation) ParallelJVMTest(com.hazelcast.test.annotation.ParallelJVMTest) QuickTest(com.hazelcast.test.annotation.QuickTest) Test(org.junit.Test)

Example 13 with BackupAwareOperation

use of com.hazelcast.spi.impl.operationservice.BackupAwareOperation in project hazelcast by hazelcast.

the class OperationBackupHandlerTest method backup_whenTooLargeSumOfSyncAndAsync.

@Test(expected = IllegalArgumentException.class)
public void backup_whenTooLargeSumOfSyncAndAsync() throws Exception {
    setup(BACKPRESSURE_ENABLED);
    BackupAwareOperation op = makeOperation(1, MAX_BACKUP_COUNT);
    backupHandler.sendBackups0(op);
}
Also used : BackupAwareOperation(com.hazelcast.spi.impl.operationservice.BackupAwareOperation) ParallelJVMTest(com.hazelcast.test.annotation.ParallelJVMTest) QuickTest(com.hazelcast.test.annotation.QuickTest) Test(org.junit.Test)

Aggregations

BackupAwareOperation (com.hazelcast.spi.impl.operationservice.BackupAwareOperation)13 Operation (com.hazelcast.spi.impl.operationservice.Operation)6 ParallelJVMTest (com.hazelcast.test.annotation.ParallelJVMTest)6 QuickTest (com.hazelcast.test.annotation.QuickTest)6 Test (org.junit.Test)6 Backup (com.hazelcast.spi.impl.operationservice.impl.operations.Backup)3 PartitionReplica (com.hazelcast.internal.partition.PartitionReplica)2 Data (com.hazelcast.internal.serialization.Data)2 TargetAware (com.hazelcast.spi.impl.operationservice.TargetAware)2 FragmentedMigrationAwareService (com.hazelcast.internal.partition.FragmentedMigrationAwareService)1 PartitionReplicaVersionManager (com.hazelcast.internal.partition.PartitionReplicaVersionManager)1 ServiceNamespace (com.hazelcast.internal.services.ServiceNamespace)1 ServiceNamespaceAware (com.hazelcast.internal.services.ServiceNamespaceAware)1