Package org.apache.pekko.cluster.client
Class ClusterClientSettings
- java.lang.Object
-
- org.apache.pekko.cluster.client.ClusterClientSettings
-
- All Implemented Interfaces:
NoSerializationVerificationNeeded
public final class ClusterClientSettings extends java.lang.Object implements NoSerializationVerificationNeeded
Deprecated.Use Apache Pekko gRPC instead, see https://pekko.apache.org/docs/pekko/current/cluster-client.html#migration-to-pekko-grpc. Since Akka 2.6.0.param: initialContacts Actor paths of theClusterReceptionist
actors on the servers (cluster nodes) that the client will try to contact initially. It is mandatory to specify at least one initial contact. The path of the default receptionist is "pekko://system@hostname:port/system/receptionist" param: establishingGetContactsInterval Interval at which the client retries to establish contact with one of ClusterReceptionist on the servers (cluster nodes) param: refreshContactsInterval Interval at which the client will ask theClusterReceptionist
for new contact points to be used for next reconnect. param: heartbeatInterval How often failure detection heartbeat messages for detection of failed connections should be sent. param: acceptableHeartbeatPause Number of potentially lost/delayed heartbeats that will be accepted before considering it to be an anomaly. The ClusterClient is using thepekko.remote.DeadlineFailureDetector
, which will trigger if there are no heartbeats within the durationheartbeatInterval + acceptableHeartbeatPause
. param: bufferSize If connection to the receptionist is not established the client will buffer this number of messages and deliver them the connection is established. When the buffer is full old messages will be dropped when new messages are sent via the client. Use 0 to disable buffering, i.e. messages will be dropped immediately if the location of the receptionist is unavailable. param: reconnectTimeout If the connection to the receptionist is lost and cannot be re-established within this duration the cluster client will be stopped. This makes it possible to watch it from another actor and possibly acquire a new list of initialContacts from some external service registry
-
-
Constructor Summary
Constructors Constructor Description ClusterClientSettings(scala.collection.immutable.Set<ActorPath> initialContacts, scala.concurrent.duration.FiniteDuration establishingGetContactsInterval, scala.concurrent.duration.FiniteDuration refreshContactsInterval, scala.concurrent.duration.FiniteDuration heartbeatInterval, scala.concurrent.duration.FiniteDuration acceptableHeartbeatPause, int bufferSize)
Deprecated.For binary/source compatibilityClusterClientSettings(scala.collection.immutable.Set<ActorPath> initialContacts, scala.concurrent.duration.FiniteDuration establishingGetContactsInterval, scala.concurrent.duration.FiniteDuration refreshContactsInterval, scala.concurrent.duration.FiniteDuration heartbeatInterval, scala.concurrent.duration.FiniteDuration acceptableHeartbeatPause, int bufferSize, scala.Option<scala.concurrent.duration.FiniteDuration> reconnectTimeout)
Deprecated.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description scala.concurrent.duration.FiniteDuration
acceptableHeartbeatPause()
Deprecated.static ClusterClientSettings
apply(com.typesafe.config.Config config)
Deprecated.Create settings from a configuration with the same layout as the default configurationpekko.cluster.client
.static ClusterClientSettings
apply(ActorSystem system)
Deprecated.Create settings from the default configurationpekko.cluster.client
.int
bufferSize()
Deprecated.static ClusterClientSettings
create(com.typesafe.config.Config config)
Deprecated.Java API: Create settings from a configuration with the same layout as the default configurationpekko.cluster.client
.static ClusterClientSettings
create(ActorSystem system)
Deprecated.Java API: Create settings from the default configurationpekko.cluster.client
.scala.concurrent.duration.FiniteDuration
establishingGetContactsInterval()
Deprecated.scala.concurrent.duration.FiniteDuration
heartbeatInterval()
Deprecated.scala.collection.immutable.Set<ActorPath>
initialContacts()
Deprecated.scala.Option<scala.concurrent.duration.FiniteDuration>
reconnectTimeout()
Deprecated.scala.concurrent.duration.FiniteDuration
refreshContactsInterval()
Deprecated.ClusterClientSettings
withBufferSize(int bufferSize)
Deprecated.ClusterClientSettings
withEstablishingGetContactsInterval(scala.concurrent.duration.FiniteDuration establishingGetContactsInterval)
Deprecated.ClusterClientSettings
withHeartbeat(scala.concurrent.duration.FiniteDuration heartbeatInterval, scala.concurrent.duration.FiniteDuration acceptableHeartbeatPause)
Deprecated.ClusterClientSettings
withInitialContacts(java.util.Set<ActorPath> initialContacts)
Deprecated.Java APIClusterClientSettings
withInitialContacts(scala.collection.immutable.Set<ActorPath> initialContacts)
Deprecated.Scala APIClusterClientSettings
withReconnectTimeout(scala.Option<scala.concurrent.duration.FiniteDuration> reconnectTimeout)
Deprecated.ClusterClientSettings
withRefreshContactsInterval(scala.concurrent.duration.FiniteDuration refreshContactsInterval)
Deprecated.
-
-
-
Constructor Detail
-
ClusterClientSettings
public ClusterClientSettings(scala.collection.immutable.Set<ActorPath> initialContacts, scala.concurrent.duration.FiniteDuration establishingGetContactsInterval, scala.concurrent.duration.FiniteDuration refreshContactsInterval, scala.concurrent.duration.FiniteDuration heartbeatInterval, scala.concurrent.duration.FiniteDuration acceptableHeartbeatPause, int bufferSize, scala.Option<scala.concurrent.duration.FiniteDuration> reconnectTimeout)
Deprecated.
-
ClusterClientSettings
public ClusterClientSettings(scala.collection.immutable.Set<ActorPath> initialContacts, scala.concurrent.duration.FiniteDuration establishingGetContactsInterval, scala.concurrent.duration.FiniteDuration refreshContactsInterval, scala.concurrent.duration.FiniteDuration heartbeatInterval, scala.concurrent.duration.FiniteDuration acceptableHeartbeatPause, int bufferSize)
Deprecated.For binary/source compatibility
-
-
Method Detail
-
apply
public static ClusterClientSettings apply(ActorSystem system)
Deprecated.Create settings from the default configurationpekko.cluster.client
.
-
apply
public static ClusterClientSettings apply(com.typesafe.config.Config config)
Deprecated.Create settings from a configuration with the same layout as the default configurationpekko.cluster.client
.
-
create
public static ClusterClientSettings create(ActorSystem system)
Deprecated.Java API: Create settings from the default configurationpekko.cluster.client
.
-
create
public static ClusterClientSettings create(com.typesafe.config.Config config)
Deprecated.Java API: Create settings from a configuration with the same layout as the default configurationpekko.cluster.client
.
-
initialContacts
public scala.collection.immutable.Set<ActorPath> initialContacts()
Deprecated.
-
establishingGetContactsInterval
public scala.concurrent.duration.FiniteDuration establishingGetContactsInterval()
Deprecated.
-
refreshContactsInterval
public scala.concurrent.duration.FiniteDuration refreshContactsInterval()
Deprecated.
-
heartbeatInterval
public scala.concurrent.duration.FiniteDuration heartbeatInterval()
Deprecated.
-
acceptableHeartbeatPause
public scala.concurrent.duration.FiniteDuration acceptableHeartbeatPause()
Deprecated.
-
bufferSize
public int bufferSize()
Deprecated.
-
reconnectTimeout
public scala.Option<scala.concurrent.duration.FiniteDuration> reconnectTimeout()
Deprecated.
-
withInitialContacts
public ClusterClientSettings withInitialContacts(scala.collection.immutable.Set<ActorPath> initialContacts)
Deprecated.Scala API
-
withInitialContacts
public ClusterClientSettings withInitialContacts(java.util.Set<ActorPath> initialContacts)
Deprecated.Java API
-
withEstablishingGetContactsInterval
public ClusterClientSettings withEstablishingGetContactsInterval(scala.concurrent.duration.FiniteDuration establishingGetContactsInterval)
Deprecated.
-
withRefreshContactsInterval
public ClusterClientSettings withRefreshContactsInterval(scala.concurrent.duration.FiniteDuration refreshContactsInterval)
Deprecated.
-
withHeartbeat
public ClusterClientSettings withHeartbeat(scala.concurrent.duration.FiniteDuration heartbeatInterval, scala.concurrent.duration.FiniteDuration acceptableHeartbeatPause)
Deprecated.
-
withBufferSize
public ClusterClientSettings withBufferSize(int bufferSize)
Deprecated.
-
withReconnectTimeout
public ClusterClientSettings withReconnectTimeout(scala.Option<scala.concurrent.duration.FiniteDuration> reconnectTimeout)
Deprecated.
-
-