public final class FirstSeedNodeProcess extends java.lang.Object implements Actor, ActorLogging
Used only for the first seed node. Sends InitJoin to all seed nodes (except itself). If other seed nodes are not part of the cluster yet they will reply with InitJoinNack or not respond at all and then the first seed node will join itself to initialize the new cluster. When the first seed node is restarted, and some other seed node is part of the cluster it will reply with InitJoinAck and then the first seed node will join that other seed node to join existing cluster.
Actor.emptyBehavior$, Actor.ignoringBehavior$
Constructor and Description |
---|
FirstSeedNodeProcess(scala.collection.immutable.IndexedSeq<Address> seedNodes) |
Modifier and Type | Method and Description |
---|---|
Cluster |
cluster() |
ActorContext |
context()
Stores the context for this actor, including self, and sender.
|
void |
postStop()
User overridable callback.
|
scala.PartialFunction<java.lang.Object,scala.runtime.BoxedUnit> |
receive()
This defines the initial actor behavior, it must return a partial function
with the actor logic.
|
scala.collection.immutable.Set<Address> |
remainingSeedNodes() |
Cancellable |
retryTask() |
ActorRef |
self()
The 'self' field holds the ActorRef for this actor.
|
Address |
selfAddress() |
scala.concurrent.duration.Deadline |
timeout() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
aroundPostRestart, aroundPostStop, aroundPreRestart, aroundPreStart, aroundReceive, postRestart, preRestart, preStart, sender, supervisorStrategy, unhandled
log
public FirstSeedNodeProcess(scala.collection.immutable.IndexedSeq<Address> seedNodes)
public ActorContext context()
Actor
forward
.
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 a
UntypedActorContext
, which is the Java API of the actor
context.
public final ActorRef self()
Actor
self ! message
public Cluster cluster()
public Address selfAddress()
public scala.concurrent.duration.Deadline timeout()
public scala.collection.immutable.Set<Address> remainingSeedNodes()
public Cancellable retryTask()
public void postStop()
Actor