Class ActorSystemBootstrapTools


  • public class ActorSystemBootstrapTools
    extends Object
    Tools for starting the Actor Systems used to run the JobManager and TaskManager actors.
    • 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 configuration
        externalAddress - 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 configuration
        actorSystemName - Name of the started ActorSystem
        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 executor
        customConfig - 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