Class RemoteRouterConfig

  • All Implemented Interfaces:
    Pool, RouterConfig, java.io.Serializable, scala.Equals, scala.Product, scala.Serializable

    public final class RemoteRouterConfig
    extends java.lang.Object
    implements Pool, scala.Product, scala.Serializable
    RouterConfig implementation for remote deployment on defined target nodes. Delegates other duties to the local Pool, which makes it possible to mix this with the built-in routers such as RoundRobinGroup or custom routers.
    See Also:
    Serialized Form
    • Constructor Detail

      • RemoteRouterConfig

        public RemoteRouterConfig​(Pool local,
                                  scala.collection.Iterable<Address> nodes)
      • RemoteRouterConfig

        public RemoteRouterConfig​(Pool local,
                                  java.lang.Iterable<Address> nodes)
      • RemoteRouterConfig

        public RemoteRouterConfig​(Pool local,
                                  Address[] nodes)
    • Method Detail

      • routingLogicController

        public static scala.Option<Props> routingLogicController​(RoutingLogic routingLogic)
      • isManagementMessage

        public static boolean isManagementMessage​(java.lang.Object msg)
      • verifyConfig

        public static void verifyConfig​(ActorPath path)
      • usePoolDispatcher

        public static boolean usePoolDispatcher()
      • enrichWithPoolDispatcher

        public static Props enrichWithPoolDispatcher​(Props routeeProps,
                                                     ActorContext context)
      • props

        public static Props props​(Props routeeProps)
      • stopRouterWhenAllRouteesRemoved

        public static boolean stopRouterWhenAllRouteesRemoved()
      • local

        public Pool local()
      • nodes

        public scala.collection.Iterable<Address> nodes()
      • createRouter

        public Router createRouter​(ActorSystem system)
        Description copied from interface: RouterConfig
        Create the actual router, responsible for routing messages to routees.

        Specified by:
        createRouter in interface RouterConfig
        Parameters:
        system - the ActorSystem this router belongs to
        Returns:
        (undocumented)
      • nrOfInstances

        public int nrOfInstances​(ActorSystem sys)
        Description copied from interface: Pool
        Initial number of routee instances
        Specified by:
        nrOfInstances in interface Pool
        Parameters:
        sys - (undocumented)
        Returns:
        (undocumented)
      • newRoutee

        public Routee newRoutee​(Props routeeProps,
                                ActorContext context)
        Description copied from interface: Pool
        INTERNAL API
        Specified by:
        newRoutee in interface Pool
        Parameters:
        routeeProps - (undocumented)
        context - (undocumented)
        Returns:
        (undocumented)
      • supervisorStrategy

        public SupervisorStrategy supervisorStrategy()
        Description copied from interface: Pool
        SupervisorStrategy for the head actor, i.e. for supervising the routees of the pool.
        Specified by:
        supervisorStrategy in interface Pool
        Returns:
        (undocumented)
      • routerDispatcher

        public java.lang.String routerDispatcher()
        Description copied from interface: RouterConfig
        Dispatcher ID to use for running the &ldquo;head&rdquo; actor, which handles supervision, death watch and router management messages
        Specified by:
        routerDispatcher in interface RouterConfig
        Returns:
        (undocumented)
      • resizer

        public scala.Option<Resizer> resizer()
        Description copied from interface: Pool
        Pool with dynamically resizable number of routees return the Resizer to use. The resizer is invoked once when the router is created, before any messages can be sent to it. Resize is also triggered when messages are sent to the routees, and the resizer is invoked asynchronously, i.e. not necessarily before the message has been sent.
        Specified by:
        resizer in interface Pool
        Returns:
        (undocumented)
      • withFallback

        public RouterConfig withFallback​(RouterConfig other)
        Description copied from interface: RouterConfig
        Overridable merge strategy, by default completely prefers this (i.e. no merge).
        Specified by:
        withFallback in interface RouterConfig
        Parameters:
        other - (undocumented)
        Returns:
        (undocumented)
      • copy$default$1

        public Pool copy$default$1()
      • copy$default$2

        public scala.collection.Iterable<Address> copy$default$2()
      • productPrefix

        public java.lang.String productPrefix()
        Specified by:
        productPrefix in interface scala.Product
      • productArity

        public int productArity()
        Specified by:
        productArity in interface scala.Product
      • productElement

        public java.lang.Object productElement​(int x$1)
        Specified by:
        productElement in interface scala.Product
      • productIterator

        public scala.collection.Iterator<java.lang.Object> productIterator()
        Specified by:
        productIterator in interface scala.Product
      • canEqual

        public boolean canEqual​(java.lang.Object x$1)
        Specified by:
        canEqual in interface scala.Equals
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object x$1)
        Specified by:
        equals in interface scala.Equals
        Overrides:
        equals in class java.lang.Object