Class DistributedPubSubSettings
TBD
Implements
Inherited Members
Namespace: Akka.Cluster.Tools.PublishSubscribe
Assembly: Akka.Cluster.Tools.dll
Syntax
public sealed class DistributedPubSubSettings : INoSerializationVerificationNeeded
Constructors
| Improve this Doc View SourceDistributedPubSubSettings(String, RoutingLogic, TimeSpan, TimeSpan, Int32, Boolean)
Creates a new instance of the DistributedPubSubSettings.
Declaration
public DistributedPubSubSettings(string role, RoutingLogic routingLogic, TimeSpan gossipInterval, TimeSpan removedTimeToLive, int maxDeltaElements, bool sendToDeadLettersWhenNoSubscribers)
Parameters
Type | Name | Description |
---|---|---|
String | role | The role that will host DistributedPubSubMediator instances. |
RoutingLogic | routingLogic | Optional. The routing logic used for distributing messages for topic groups. |
TimeSpan | gossipInterval | The gossip interval for propagating topic/subscriber data to other mediators. |
TimeSpan | removedTimeToLive | The amount of time it takes to prune a deactivated subscriber from the network. |
Int32 | maxDeltaElements | The maximum number of delta elements that can be propagated in a single gossip tick. |
Boolean | sendToDeadLettersWhenNoSubscribers | When a message is published to a topic with no subscribers send it to the dead letters. |
Exceptions
Type | Condition |
---|---|
ArgumentException | Thrown if a user tries to use a ConsistentHashingRoutingLogic with routingLogic. |
Properties
| Improve this Doc View SourceGossipInterval
How often the DistributedPubSubMediator should send out gossip information
Declaration
public TimeSpan GossipInterval { get; }
Property Value
Type | Description |
---|---|
TimeSpan |
MaxDeltaElements
Maximum number of elements to transfer in one message when synchronizing the registries. Next chunk will be transferred in next round of gossip.
Declaration
public int MaxDeltaElements { get; }
Property Value
Type | Description |
---|---|
Int32 |
RemovedTimeToLive
Removed entries are pruned after this duration.
Declaration
public TimeSpan RemovedTimeToLive { get; }
Property Value
Type | Description |
---|---|
TimeSpan |
Role
The mediator starts on members tagged with this role. Uses all if undefined.
Declaration
public string Role { get; }
Property Value
Type | Description |
---|---|
String |
RoutingLogic
The routing logic to use for DistributedPubSubMediator.
Declaration
public RoutingLogic RoutingLogic { get; }
Property Value
Type | Description |
---|---|
RoutingLogic |
SendToDeadLettersWhenNoSubscribers
When a message is published to a topic with no subscribers send it to the dead letters.
Declaration
public bool SendToDeadLettersWhenNoSubscribers { get; }
Property Value
Type | Description |
---|---|
Boolean |
Methods
| Improve this Doc View SourceCreate(ActorSystem)
Creates cluster publish/subscribe settings from the default configuration akka.cluster.pub-sub
.
Declaration
public static DistributedPubSubSettings Create(ActorSystem system)
Parameters
Type | Name | Description |
---|---|---|
ActorSystem | system | TBD |
Returns
Type | Description |
---|---|
DistributedPubSubSettings | TBD |
Exceptions
Type | Condition |
---|---|
ArgumentException | TBD |
Create(Config)
Creates cluster publish subscribe settings from provided configuration with the same layout as akka.cluster.pub-sub
.
Declaration
public static DistributedPubSubSettings Create(Config config)
Parameters
Type | Name | Description |
---|---|---|
Config | config | TBD |
Returns
Type | Description |
---|---|
DistributedPubSubSettings | TBD |
Exceptions
Type | Condition |
---|---|
ArgumentException | TBD |
WithGossipInterval(TimeSpan)
TBD
Declaration
public DistributedPubSubSettings WithGossipInterval(TimeSpan gossipInterval)
Parameters
Type | Name | Description |
---|---|---|
TimeSpan | gossipInterval | TBD |
Returns
Type | Description |
---|---|
DistributedPubSubSettings | TBD |
WithMaxDeltaElements(Int32)
TBD
Declaration
public DistributedPubSubSettings WithMaxDeltaElements(int maxDeltaElements)
Parameters
Type | Name | Description |
---|---|---|
Int32 | maxDeltaElements | TBD |
Returns
Type | Description |
---|---|
DistributedPubSubSettings | TBD |
WithRemovedTimeToLive(TimeSpan)
TBD
Declaration
public DistributedPubSubSettings WithRemovedTimeToLive(TimeSpan removedTtl)
Parameters
Type | Name | Description |
---|---|---|
TimeSpan | removedTtl | TBD |
Returns
Type | Description |
---|---|
DistributedPubSubSettings | TBD |
WithRole(String)
TBD
Declaration
public DistributedPubSubSettings WithRole(string role)
Parameters
Type | Name | Description |
---|---|---|
String | role | TBD |
Returns
Type | Description |
---|---|
DistributedPubSubSettings | TBD |
WithRoutingLogic(RoutingLogic)
TBD
Declaration
public DistributedPubSubSettings WithRoutingLogic(RoutingLogic routingLogic)
Parameters
Type | Name | Description |
---|---|---|
RoutingLogic | routingLogic | TBD |
Returns
Type | Description |
---|---|
DistributedPubSubSettings | TBD |
WithSendToDeadLettersWhenNoSubscribers(Boolean)
TBD
Declaration
public DistributedPubSubSettings WithSendToDeadLettersWhenNoSubscribers(bool sendToDeadLetterWhenNoSubscribers)
Parameters
Type | Name | Description |
---|---|---|
Boolean | sendToDeadLetterWhenNoSubscribers | TBD |
Returns
Type | Description |
---|---|
DistributedPubSubSettings |