Search in sources :

Example 1 with LeaderElectionManagementRequest

use of org.apache.ratis.protocol.LeaderElectionManagementRequest in project incubator-ratis by apache.

the class GrpcAdminProtocolService method leaderElectionManagement.

@Override
public void leaderElectionManagement(LeaderElectionManagementRequestProto proto, StreamObserver<RaftClientReplyProto> responseObserver) {
    final LeaderElectionManagementRequest request = ClientProtoUtils.toLeaderElectionManagementRequest(proto);
    GrpcUtil.asyncCall(responseObserver, () -> protocol.leaderElectionManagementAsync(request), ClientProtoUtils::toRaftClientReplyProto);
}
Also used : LeaderElectionManagementRequest(org.apache.ratis.protocol.LeaderElectionManagementRequest) ClientProtoUtils(org.apache.ratis.client.impl.ClientProtoUtils)

Aggregations

ClientProtoUtils (org.apache.ratis.client.impl.ClientProtoUtils)1 LeaderElectionManagementRequest (org.apache.ratis.protocol.LeaderElectionManagementRequest)1