Class ClusterSingletonProxy
The ClusterSingletonProxy works together with the ClusterSingletonManager to provide a distributed proxy to the singleton actor.
The proxy can be started on every node where the singleton needs to be reached and used as if it were the singleton itself. It will then act as a router to the currently running singleton instance. If the singleton is not currently available, e.g., during hand off or startup, the proxy will buffer the messages sent to the singleton and then deliver them when the singleton is finally available. The size of the buffer is configurable and it can be disabled by using a buffer size of 0. When the buffer is full old messages will be dropped when new messages are sent via the proxy.
The proxy works by keeping track of the oldest cluster member. When a new oldest member is identified, e.g. because the older one left the cluster, or at startup, the proxy will try to identify the singleton on the oldest member by periodically sending an Identify message until the singleton responds with its ActorIdentity.
Inherited Members
Namespace: Akka.Cluster.Tools.Singleton
Assembly: Akka.Cluster.Tools.dll
Syntax
public sealed class ClusterSingletonProxy : ReceiveActor, IInternalActor, IInitializableActor, IWithTimers
Constructors
| Improve this Doc View SourceClusterSingletonProxy(String, ClusterSingletonProxySettings)
TBD
Declaration
public ClusterSingletonProxy(string singletonManagerPath, ClusterSingletonProxySettings settings)
Parameters
Type | Name | Description |
---|---|---|
String | singletonManagerPath | TBD |
ClusterSingletonProxySettings | settings | TBD |
Properties
| Improve this Doc View SourceTimers
Declaration
public ITimerScheduler Timers { get; set; }
Property Value
Type | Description |
---|---|
ITimerScheduler |
Methods
| Improve this Doc View SourceDefaultConfig()
Returns default HOCON configuration for the cluster singleton.
Declaration
public static Config DefaultConfig()
Returns
Type | Description |
---|---|
Config | TBD |
PostStop()
TBD
Declaration
protected override void PostStop()
Overrides
| Improve this Doc View SourcePreStart()
TBD
Declaration
protected override void PreStart()
Overrides
| Improve this Doc View SourceProps(String, ClusterSingletonProxySettings)
Factory method for ClusterSingletonProxy Props.
Declaration
public static Props Props(string singletonManagerPath, ClusterSingletonProxySettings settings)
Parameters
Type | Name | Description |
---|---|---|
String | singletonManagerPath | The logical path of the singleton manager, e.g. |
ClusterSingletonProxySettings | settings | Cluster singleton proxy settings. |
Returns
Type | Description |
---|---|
Props | TBD |