Package org.apache.pekko.cluster.typed
Class ClusterSingletonManagerSettings
java.lang.Object
org.apache.pekko.cluster.typed.ClusterSingletonManagerSettings
param: singletonName The actor name of the child singleton actor.
param: role Singleton among the nodes tagged with specified role.
If the role is not specified it's a singleton among all nodes in
the cluster.
param: removalMargin Margin until the singleton instance that belonged to
a downed/removed partition is created in surviving partition. The purpose of
this margin is that in case of a network partition the singleton actors
in the non-surviving partitions must be stopped before corresponding actors
are started somewhere else. This is especially important for persistent
actors.
param: handOverRetryInterval When a node is becoming oldest it sends hand-over
request to previous oldest, that might be leaving the cluster. This is
retried with this interval until the previous oldest confirms that the hand
over has started or the previous oldest member is removed from the cluster
(+
removalMargin).
param: leaseSettings LeaseSettings for acquiring before creating the singleton actor-
Constructor Summary
ConstructorsConstructorDescriptionClusterSingletonManagerSettings(String singletonName, scala.Option<String> role, scala.concurrent.duration.FiniteDuration removalMargin, scala.concurrent.duration.FiniteDuration handOverRetryInterval, scala.Option<LeaseUsageSettings> leaseSettings) -
Method Summary
Modifier and TypeMethodDescriptionapply(com.typesafe.config.Config config) Create settings from a configuration with the same layout as the default configurationpekko.cluster.singleton.apply(ActorSystem<?> system) Create settings from the default configurationpekko.cluster.singleton.create(com.typesafe.config.Config config) Java API: Create settings from a configuration with the same layout as the default configurationpekko.cluster.singleton.create(ActorSystem<?> system) Java API: Create settings from the default configurationpekko.cluster.singleton.scala.concurrent.duration.FiniteDurationscala.Option<LeaseUsageSettings>scala.concurrent.duration.FiniteDurationscala.Option<String>role()withHandOverRetryInterval(Duration retryInterval) withHandOverRetryInterval(scala.concurrent.duration.FiniteDuration retryInterval) withLeaseSettings(LeaseUsageSettings leaseSettings) withRemovalMargin(Duration removalMargin) withRemovalMargin(scala.concurrent.duration.FiniteDuration removalMargin) withSingletonName(String name)
-
Constructor Details
-
ClusterSingletonManagerSettings
public ClusterSingletonManagerSettings(String singletonName, scala.Option<String> role, scala.concurrent.duration.FiniteDuration removalMargin, scala.concurrent.duration.FiniteDuration handOverRetryInterval, scala.Option<LeaseUsageSettings> leaseSettings)
-
-
Method Details
-
apply
Create settings from the default configurationpekko.cluster.singleton. -
apply
Create settings from a configuration with the same layout as the default configurationpekko.cluster.singleton. -
create
Java API: Create settings from the default configurationpekko.cluster.singleton. -
create
Java API: Create settings from a configuration with the same layout as the default configurationpekko.cluster.singleton. -
singletonName
-
role
-
removalMargin
public scala.concurrent.duration.FiniteDuration removalMargin() -
handOverRetryInterval
public scala.concurrent.duration.FiniteDuration handOverRetryInterval() -
leaseSettings
-
withSingletonName
-
withRole
-
withRole
-
withRemovalMargin
public ClusterSingletonManagerSettings withRemovalMargin(scala.concurrent.duration.FiniteDuration removalMargin) -
withRemovalMargin
-
withHandOverRetryInterval
public ClusterSingletonManagerSettings withHandOverRetryInterval(scala.concurrent.duration.FiniteDuration retryInterval) -
withHandOverRetryInterval
-
withLeaseSettings
-