Search in sources :

Example 1 with ChangeRaftGroupMembershipOp

use of com.hazelcast.cp.internal.operation.ChangeRaftGroupMembershipOp in project hazelcast by hazelcast.

the class RaftInvocationManager method changeMembership.

<T> InternalCompletableFuture<T> changeMembership(CPGroupId groupId, long membersCommitIndex, RaftEndpoint member, MembershipChangeMode membershipChangeMode) {
    InternalCompletableFuture<T> completedFuture = completeExceptionallyIfCPSubsystemNotAvailable();
    if (completedFuture != null) {
        return completedFuture;
    }
    Operation operation = new ChangeRaftGroupMembershipOp(groupId, membersCommitIndex, member, membershipChangeMode);
    Invocation invocation = new RaftInvocation(operationService.getInvocationContext(), raftInvocationContext, groupId, operation, invocationMaxRetryCount, invocationRetryPauseMillis, operationCallTimeout);
    return invocation.invoke();
}
Also used : RaftInvocation(com.hazelcast.spi.impl.operationservice.impl.RaftInvocation) ChangeRaftGroupMembershipOp(com.hazelcast.cp.internal.operation.ChangeRaftGroupMembershipOp) DEFAULT_DESERIALIZE_RESULT(com.hazelcast.spi.impl.operationservice.InvocationBuilder.DEFAULT_DESERIALIZE_RESULT) Invocation(com.hazelcast.spi.impl.operationservice.impl.Invocation) RaftInvocation(com.hazelcast.spi.impl.operationservice.impl.RaftInvocation) Operation(com.hazelcast.spi.impl.operationservice.Operation)

Aggregations

ChangeRaftGroupMembershipOp (com.hazelcast.cp.internal.operation.ChangeRaftGroupMembershipOp)1 DEFAULT_DESERIALIZE_RESULT (com.hazelcast.spi.impl.operationservice.InvocationBuilder.DEFAULT_DESERIALIZE_RESULT)1 Operation (com.hazelcast.spi.impl.operationservice.Operation)1 Invocation (com.hazelcast.spi.impl.operationservice.impl.Invocation)1 RaftInvocation (com.hazelcast.spi.impl.operationservice.impl.RaftInvocation)1