Class XceiverServerGrpc
java.lang.Object
org.apache.hadoop.ozone.container.common.transport.server.XceiverServerGrpc
- All Implemented Interfaces:
XceiverServerSpi
Creates a Grpc server endpoint that acts as the communication layer for
Ozone containers.
-
Constructor Summary
ConstructorsConstructorDescriptionXceiverServerGrpc(org.apache.hadoop.hdds.protocol.DatanodeDetails datanodeDetails, org.apache.hadoop.hdds.conf.ConfigurationSource conf, ContainerDispatcher dispatcher, org.apache.hadoop.hdds.security.x509.certificate.client.CertificateClient caClient) Constructs a Grpc server class. -
Method Summary
Modifier and TypeMethodDescriptionintGet server IPC port.List<org.apache.hadoop.hdds.protocol.proto.StorageContainerDatanodeProtocolProtos.PipelineReport> Get pipeline report for the XceiverServer instance.org.apache.hadoop.hdds.protocol.proto.HddsProtos.ReplicationTypeReturns the Replication type supported by this end-point.booleanisExist(org.apache.hadoop.hdds.protocol.proto.HddsProtos.PipelineID pipelineId) Returns true if the given pipeline exist.voidstart()Starts the server.voidstop()Stops a running server.voidsubmitRequest(org.apache.hadoop.hdds.protocol.datanode.proto.ContainerProtos.ContainerCommandRequestProto request, org.apache.hadoop.hdds.protocol.proto.HddsProtos.PipelineID pipelineID) submits a containerRequest to be performed by the replication pipeline.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.hadoop.ozone.container.common.transport.server.XceiverServerSpi
addGroup, addGroup, getStorageReport, removeGroup
-
Constructor Details
-
XceiverServerGrpc
public XceiverServerGrpc(org.apache.hadoop.hdds.protocol.DatanodeDetails datanodeDetails, org.apache.hadoop.hdds.conf.ConfigurationSource conf, ContainerDispatcher dispatcher, org.apache.hadoop.hdds.security.x509.certificate.client.CertificateClient caClient) Constructs a Grpc server class.- Parameters:
conf- - Configuration
-
-
Method Details
-
getIPCPort
public int getIPCPort()Description copied from interface:XceiverServerSpiGet server IPC port.- Specified by:
getIPCPortin interfaceXceiverServerSpi
-
getServerType
public org.apache.hadoop.hdds.protocol.proto.HddsProtos.ReplicationType getServerType()Returns the Replication type supported by this end-point.- Specified by:
getServerTypein interfaceXceiverServerSpi- Returns:
- enum -- {Stand_Alone, Ratis, Grpc, Chained}
-
start
Description copied from interface:XceiverServerSpiStarts the server.- Specified by:
startin interfaceXceiverServerSpi- Throws:
IOException
-
stop
public void stop()Description copied from interface:XceiverServerSpiStops a running server.- Specified by:
stopin interfaceXceiverServerSpi
-
submitRequest
public void submitRequest(org.apache.hadoop.hdds.protocol.datanode.proto.ContainerProtos.ContainerCommandRequestProto request, org.apache.hadoop.hdds.protocol.proto.HddsProtos.PipelineID pipelineID) throws IOException Description copied from interface:XceiverServerSpisubmits a containerRequest to be performed by the replication pipeline.- Specified by:
submitRequestin interfaceXceiverServerSpi- Parameters:
request- ContainerCommandRequest- Throws:
IOException
-
isExist
public boolean isExist(org.apache.hadoop.hdds.protocol.proto.HddsProtos.PipelineID pipelineId) Description copied from interface:XceiverServerSpiReturns true if the given pipeline exist.- Specified by:
isExistin interfaceXceiverServerSpi- Returns:
- true if pipeline present, else false
-
getPipelineReport
public List<org.apache.hadoop.hdds.protocol.proto.StorageContainerDatanodeProtocolProtos.PipelineReport> getPipelineReport()Description copied from interface:XceiverServerSpiGet pipeline report for the XceiverServer instance.- Specified by:
getPipelineReportin interfaceXceiverServerSpi- Returns:
- list of report for each pipeline.
-