Class ActorSystemBootstrapTools
- java.lang.Object
-
- org.apache.flink.runtime.rpc.pekko.ActorSystemBootstrapTools
-
public class ActorSystemBootstrapTools extends Object
Tools for starting the Actor Systems used to run the JobManager and TaskManager actors.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static RpcSystem.ForkJoinExecutorConfiguration
getForkJoinExecutorConfiguration(Configuration configuration)
static RpcSystem.ForkJoinExecutorConfiguration
getRemoteForkJoinExecutorConfiguration(Configuration configuration)
static org.apache.pekko.actor.ActorSystem
startLocalActorSystem(Configuration configuration, String actorSystemName, org.slf4j.Logger logger, com.typesafe.config.Config actorSystemExecutorConfiguration, com.typesafe.config.Config customConfig)
Starts a local Actor System.static org.apache.pekko.actor.ActorSystem
startRemoteActorSystem(Configuration configuration, String actorSystemName, String externalAddress, String externalPortRange, String bindAddress, Optional<Integer> bindPort, org.slf4j.Logger logger, com.typesafe.config.Config actorSystemExecutorConfiguration, com.typesafe.config.Config customConfig)
Starts a remote ActorSystem at given address and specific port range.static org.apache.pekko.actor.ActorSystem
startRemoteActorSystem(Configuration configuration, String externalAddress, String externalPortRange, org.slf4j.Logger logger)
Starts a remote ActorSystem at given address and specific port range.
-
-
-
Method Detail
-
startRemoteActorSystem
@VisibleForTesting public static org.apache.pekko.actor.ActorSystem startRemoteActorSystem(Configuration configuration, String externalAddress, String externalPortRange, org.slf4j.Logger logger) throws Exception
Starts a remote ActorSystem at given address and specific port range.- Parameters:
configuration
- The Flink configurationexternalAddress
- The external address to access the ActorSystem.externalPortRange
- The choosing range of the external port to access the ActorSystem.logger
- The logger to output log information.- Returns:
- The ActorSystem which has been started
- Throws:
Exception
- Thrown when actor system cannot be started in specified port range
-
startRemoteActorSystem
public static org.apache.pekko.actor.ActorSystem startRemoteActorSystem(Configuration configuration, String actorSystemName, String externalAddress, String externalPortRange, String bindAddress, Optional<Integer> bindPort, org.slf4j.Logger logger, com.typesafe.config.Config actorSystemExecutorConfiguration, com.typesafe.config.Config customConfig) throws Exception
Starts a remote ActorSystem at given address and specific port range.- Parameters:
configuration
- The Flink configurationactorSystemName
- Name of the startedActorSystem
externalAddress
- The external address to access the ActorSystem.externalPortRange
- The choosing range of the external port to access the ActorSystem.bindAddress
- The local address to bind to.bindPort
- The local port to bind to. If not present, then the external port will be used.logger
- The logger to output log information.actorSystemExecutorConfiguration
- configuration for the ActorSystem's underlying executorcustomConfig
- Custom Pekko config to be combined with the config derived from Flink configuration.- Returns:
- The ActorSystem which has been started
- Throws:
Exception
- Thrown when actor system cannot be started in specified port range
-
startLocalActorSystem
public static org.apache.pekko.actor.ActorSystem startLocalActorSystem(Configuration configuration, String actorSystemName, org.slf4j.Logger logger, com.typesafe.config.Config actorSystemExecutorConfiguration, com.typesafe.config.Config customConfig) throws Exception
Starts a local Actor System.- Parameters:
configuration
- The Flink configuration.actorSystemName
- Name of the started ActorSystem.logger
- The logger to output log information.actorSystemExecutorConfiguration
- Configuration for the ActorSystem's underlying executor.customConfig
- Custom Pekko config to be combined with the config derived from Flink configuration.- Returns:
- The ActorSystem which has been started.
- Throws:
Exception
-
getForkJoinExecutorConfiguration
public static RpcSystem.ForkJoinExecutorConfiguration getForkJoinExecutorConfiguration(Configuration configuration)
-
getRemoteForkJoinExecutorConfiguration
public static RpcSystem.ForkJoinExecutorConfiguration getRemoteForkJoinExecutorConfiguration(Configuration configuration)
-
-