Class PekkoRpcService
java.lang.Object
org.apache.flink.runtime.rpc.pekko.PekkoRpcService
- All Implemented Interfaces:
AutoCloseable,org.apache.flink.runtime.rpc.RpcService,org.apache.flink.util.AutoCloseableAsync
@ThreadSafe
public class PekkoRpcService
extends Object
implements org.apache.flink.runtime.rpc.RpcService
Pekko based
RpcService implementation. The RPC service starts an actor to receive RPC
invocations from a RpcGateway.-
Constructor Summary
ConstructorsConstructorDescriptionPekkoRpcService(org.apache.pekko.actor.ActorSystem actorSystem, PekkoRpcServiceConfiguration configuration) -
Method Summary
Modifier and TypeMethodDescription<F extends Serializable,C extends org.apache.flink.runtime.rpc.FencedRpcGateway<F>>
CompletableFuture<C><C extends org.apache.flink.runtime.rpc.RpcGateway>
CompletableFuture<C>org.apache.pekko.actor.ActorSystemintgetPort()org.apache.flink.util.concurrent.ScheduledExecutor<C extends org.apache.flink.runtime.rpc.RpcGateway>
CgetSelfGateway(Class<C> selfGatewayType, org.apache.flink.runtime.rpc.RpcServer rpcServer) protected int<C extends org.apache.flink.runtime.rpc.RpcEndpoint & org.apache.flink.runtime.rpc.RpcGateway>
org.apache.flink.runtime.rpc.RpcServerstartServer(C rpcEndpoint, Map<String, String> loggingContext) voidstopServer(org.apache.flink.runtime.rpc.RpcServer selfGateway) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.flink.util.AutoCloseableAsync
close
-
Constructor Details
-
PekkoRpcService
@VisibleForTesting public PekkoRpcService(org.apache.pekko.actor.ActorSystem actorSystem, PekkoRpcServiceConfiguration configuration)
-
-
Method Details
-
getActorSystem
public org.apache.pekko.actor.ActorSystem getActorSystem() -
getVersion
protected int getVersion() -
getAddress
- Specified by:
getAddressin interfaceorg.apache.flink.runtime.rpc.RpcService
-
getPort
public int getPort()- Specified by:
getPortin interfaceorg.apache.flink.runtime.rpc.RpcService
-
getSelfGateway
public <C extends org.apache.flink.runtime.rpc.RpcGateway> C getSelfGateway(Class<C> selfGatewayType, org.apache.flink.runtime.rpc.RpcServer rpcServer) - Specified by:
getSelfGatewayin interfaceorg.apache.flink.runtime.rpc.RpcService
-
connect
public <C extends org.apache.flink.runtime.rpc.RpcGateway> CompletableFuture<C> connect(String address, Class<C> clazz) - Specified by:
connectin interfaceorg.apache.flink.runtime.rpc.RpcService
-
connect
public <F extends Serializable,C extends org.apache.flink.runtime.rpc.FencedRpcGateway<F>> CompletableFuture<C> connect(String address, F fencingToken, Class<C> clazz) - Specified by:
connectin interfaceorg.apache.flink.runtime.rpc.RpcService
-
startServer
public <C extends org.apache.flink.runtime.rpc.RpcEndpoint & org.apache.flink.runtime.rpc.RpcGateway> org.apache.flink.runtime.rpc.RpcServer startServer(C rpcEndpoint, Map<String, String> loggingContext) - Specified by:
startServerin interfaceorg.apache.flink.runtime.rpc.RpcService
-
stopServer
public void stopServer(org.apache.flink.runtime.rpc.RpcServer selfGateway) - Specified by:
stopServerin interfaceorg.apache.flink.runtime.rpc.RpcService
-
closeAsync
- Specified by:
closeAsyncin interfaceorg.apache.flink.util.AutoCloseableAsync
-
getScheduledExecutor
public org.apache.flink.util.concurrent.ScheduledExecutor getScheduledExecutor()- Specified by:
getScheduledExecutorin interfaceorg.apache.flink.runtime.rpc.RpcService
-