Class JoinSeedNodeProcess
- java.lang.Object
-
- akka.cluster.JoinSeedNodeProcess
-
- All Implemented Interfaces:
Actor
public final class JoinSeedNodeProcess extends java.lang.Object implements Actor
INTERNAL API.Sends InitJoin to all seed nodes (except itself) and expect InitJoinAck reply back. The seed node that replied first will be used, joined to. InitJoinAck replies received after the first one are ignored.
Retries if no InitJoinAck replies are received within the SeedNodeTimeout. When at least one reply has been received it stops itself after an idle SeedNodeTimeout.
The seed nodes can be started in any order, but they will not be "active", until they have been able to join another seed node (seed1). They will retry the join procedure. So one possible startup scenario is: 1. seed2 started, but doesn't get any ack from seed1 or seed3 2. seed3 started, doesn't get any ack from seed1 or seed3 (seed2 doesn't reply) 3. seed1 is started and joins itself 4. seed2 retries the join procedure and gets an ack from seed1, and then joins to seed1 5. seed3 retries the join procedure and gets acks from seed2 first, and then joins to seed2
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface akka.actor.Actor
Actor.emptyBehavior$, Actor.ignoringBehavior$
-
-
Constructor Summary
Constructors Constructor Description JoinSeedNodeProcess(scala.collection.immutable.IndexedSeq<Address> seedNodes, JoinConfigCompatChecker joinConfigCompatChecker)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
akka$actor$Actor$_setter_$context_$eq(ActorContext x$1)
protected void
akka$actor$Actor$_setter_$self_$eq(ActorRef x$1)
The 'self' field holds the ActorRef for this actor.int
attempt()
void
attempt_$eq(int x$1)
Cluster
cluster()
ActorContext
context()
Scala API: Stores the context for this actor, including self, and sender.scala.PartialFunction<java.lang.Object,scala.runtime.BoxedUnit>
done()
void
onReceiveTimeout(scala.collection.immutable.IndexedSeq<Address> seedNodes, int attempt)
scala.collection.immutable.Set<Address>
otherSeedNodes()
void
preStart()
User overridable callback.scala.PartialFunction<java.lang.Object,scala.runtime.BoxedUnit>
receive()
Scala API: This defines the initial actor behavior, it must return a partial function with the actor logic.ActorRef
self()
The 'self' field holds the ActorRef for this actor.Address
selfAddress()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface akka.actor.Actor
aroundPostRestart, aroundPostStop, aroundPreRestart, aroundPreStart, aroundReceive, postRestart, postStop, preRestart, sender, supervisorStrategy, unhandled
-
-
-
-
Constructor Detail
-
JoinSeedNodeProcess
public JoinSeedNodeProcess(scala.collection.immutable.IndexedSeq<Address> seedNodes, JoinConfigCompatChecker joinConfigCompatChecker)
-
-
Method Detail
-
akka$actor$Actor$_setter_$context_$eq
protected void akka$actor$Actor$_setter_$context_$eq(ActorContext x$1)
- Specified by:
akka$actor$Actor$_setter_$context_$eq
in interfaceActor
-
akka$actor$Actor$_setter_$self_$eq
protected final void akka$actor$Actor$_setter_$self_$eq(ActorRef x$1)
Description copied from interface:Actor
The 'self' field holds the ActorRef for this actor. Can be used to send messages to itself:self ! message
- Specified by:
akka$actor$Actor$_setter_$self_$eq
in interfaceActor
- Parameters:
x$1
- (undocumented)
-
attempt
public int attempt()
-
attempt_$eq
public void attempt_$eq(int x$1)
-
cluster
public Cluster cluster()
-
context
public ActorContext context()
Description copied from interface:Actor
Scala API: Stores the context for this actor, including self, and sender. It is implicit to support operations such asforward
.WARNING: Only valid within the Actor itself, so do not close over it and publish it to other threads!
ActorContext
is the Scala API.getContext
returns aAbstractActor.ActorContext
, which is the Java API of the actor context.
-
done
public scala.PartialFunction<java.lang.Object,scala.runtime.BoxedUnit> done()
-
onReceiveTimeout
public void onReceiveTimeout(scala.collection.immutable.IndexedSeq<Address> seedNodes, int attempt)
-
otherSeedNodes
public scala.collection.immutable.Set<Address> otherSeedNodes()
-
preStart
public void preStart()
Description copied from interface:Actor
User overridable callback. Is called when an Actor is started. Actors are automatically started asynchronously when created. Empty default implementation.
-
receive
public scala.PartialFunction<java.lang.Object,scala.runtime.BoxedUnit> receive()
Description copied from interface:Actor
Scala API: This defines the initial actor behavior, it must return a partial function with the actor logic.
-
self
public final ActorRef self()
Description copied from interface:Actor
The 'self' field holds the ActorRef for this actor. Can be used to send messages to itself:self ! message
-
selfAddress
public Address selfAddress()
-
-