public final class BlockMasterWorkerServiceHandler extends BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
Constructor and Description |
---|
BlockMasterWorkerServiceHandler(BlockMaster blockMaster)
Creates a new instance of
BlockMasterWorkerServiceHandler . |
Modifier and Type | Method and Description |
---|---|
void |
blockHeartbeat(BlockHeartbeatPRequest request,
io.grpc.stub.StreamObserver<BlockHeartbeatPResponse> responseObserver)
Periodic block worker heartbeat returns an optional command for the block worker to execute.
|
void |
commitBlock(CommitBlockPRequest request,
io.grpc.stub.StreamObserver<CommitBlockPResponse> responseObserver)
Marks the given block as committed.
|
void |
commitBlockInUfs(CommitBlockInUfsPRequest request,
io.grpc.stub.StreamObserver<CommitBlockInUfsPResponse> responseObserver)
Marks the given block as committed which resides in UFS.
|
void |
getWorkerId(GetWorkerIdPRequest request,
io.grpc.stub.StreamObserver<GetWorkerIdPResponse> responseObserver)
Returns a worker id for the given network address.
|
void |
notifyWorkerId(NotifyWorkerIdPRequest request,
io.grpc.stub.StreamObserver<NotifyWorkerIdPResponse> responseObserver)
Notify all masters about the worker ID.
|
void |
registerWorker(RegisterWorkerPRequest request,
io.grpc.stub.StreamObserver<RegisterWorkerPResponse> responseObserver)
Registers a worker.
|
io.grpc.stub.StreamObserver<RegisterWorkerPRequest> |
registerWorkerStream(io.grpc.stub.StreamObserver<RegisterWorkerPResponse> responseObserver)
Registers a worker in a streaming way
|
void |
requestRegisterLease(GetRegisterLeasePRequest request,
io.grpc.stub.StreamObserver<GetRegisterLeasePResponse> responseObserver)
Requests a lease for registration
|
bindService
public BlockMasterWorkerServiceHandler(BlockMaster blockMaster)
BlockMasterWorkerServiceHandler
.blockMaster
- the BlockMaster
the handler uses internallypublic void blockHeartbeat(BlockHeartbeatPRequest request, io.grpc.stub.StreamObserver<BlockHeartbeatPResponse> responseObserver)
BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
Periodic block worker heartbeat returns an optional command for the block worker to execute.
blockHeartbeat
in class BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
public void commitBlock(CommitBlockPRequest request, io.grpc.stub.StreamObserver<CommitBlockPResponse> responseObserver)
BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
Marks the given block as committed.
commitBlock
in class BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
public void commitBlockInUfs(CommitBlockInUfsPRequest request, io.grpc.stub.StreamObserver<CommitBlockInUfsPResponse> responseObserver)
BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
Marks the given block as committed which resides in UFS.
commitBlockInUfs
in class BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
public void getWorkerId(GetWorkerIdPRequest request, io.grpc.stub.StreamObserver<GetWorkerIdPResponse> responseObserver)
BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
Returns a worker id for the given network address.
getWorkerId
in class BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
public void requestRegisterLease(GetRegisterLeasePRequest request, io.grpc.stub.StreamObserver<GetRegisterLeasePResponse> responseObserver)
BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
Requests a lease for registration
requestRegisterLease
in class BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
public void registerWorker(RegisterWorkerPRequest request, io.grpc.stub.StreamObserver<RegisterWorkerPResponse> responseObserver)
BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
Registers a worker.
registerWorker
in class BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
public io.grpc.stub.StreamObserver<RegisterWorkerPRequest> registerWorkerStream(io.grpc.stub.StreamObserver<RegisterWorkerPResponse> responseObserver)
BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
Registers a worker in a streaming way
registerWorkerStream
in class BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
public void notifyWorkerId(NotifyWorkerIdPRequest request, io.grpc.stub.StreamObserver<NotifyWorkerIdPResponse> responseObserver)
BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
Notify all masters about the worker ID.
notifyWorkerId
in class BlockMasterWorkerServiceGrpc.BlockMasterWorkerServiceImplBase
Copyright © 2023. All Rights Reserved.