Class ClusterReceptionist
ClusterClient connects to this actor to retrieve. The ClusterReceptionist is supposed to be started on all nodes, or all nodes with specified role, in the cluster. The receptionist can be started with the Get(ActorSystem) or as an ordinary actor (use the factory method Props(IActorRef, ClusterReceptionistSettings)).
The receptionist forwards messages from the client to the associated DistributedPubSubMediator, i.e. the client can send messages to any actor in the cluster that is registered in the DistributedPubSubMediator. Messages from the client are wrapped in Send, SendToAll or Publish with the semantics described in distributed publish/subscribe.
Response messages from the destination actor are tunneled via the receptionist to avoid inbound connections from other cluster nodes to the client, i.e. the Sender, as seen by the destination actor, is not the client itself. The Sender of the response messages, as seen by the client, is preserved as the original sender, so the client can choose to send subsequent messages directly to the actor in the cluster.
Implements
Inherited Members
Namespace: Akka.Cluster.Tools.Client
Assembly: Akka.Cluster.Tools.dll
Syntax
public sealed class ClusterReceptionist : ActorBase, IInternalActor
Constructors
| Edit this page View SourceClusterReceptionist(IActorRef, ClusterReceptionistSettings)
TBD
Declaration
public ClusterReceptionist(IActorRef pubSubMediator, ClusterReceptionistSettings settings)
Parameters
Type | Name | Description |
---|---|---|
IActorRef | pubSubMediator | TBD |
ClusterReceptionistSettings | settings | TBD |
Exceptions
Type | Condition |
---|---|
ArgumentException | TBD |
Methods
| Edit this page View SourcePostStop()
User overridable callback.
Is called asynchronously after 'actor.stop()' is invoked. Empty default implementation.Declaration
protected override void PostStop()
Overrides
| Edit this page View SourcePreStart()
User overridable callback.
Is called when an Actor is started. Actors are automatically started asynchronously when created. Empty default implementation.Declaration
protected override void PreStart()
Overrides
| Edit this page View SourceProps(IActorRef, ClusterReceptionistSettings)
Factory method for ClusterReceptionist Props.
Declaration
public static Props Props(IActorRef pubSubMediator, ClusterReceptionistSettings settings)
Parameters
Type | Name | Description |
---|---|---|
IActorRef | pubSubMediator | TBD |
ClusterReceptionistSettings | settings | TBD |
Returns
Type | Description |
---|---|
Props | TBD |
Receive(object)
TBD
Declaration
protected override bool Receive(object message)
Parameters
Type | Name | Description |
---|---|---|
object | message | TBD |
Returns
Type | Description |
---|---|
bool | TBD |