Class ClusterReceptionist.State
- java.lang.Object
-
- akka.cluster.typed.internal.receptionist.ClusterReceptionist.State
-
- All Implemented Interfaces:
java.io.Serializable
,scala.Equals
,scala.Product
- Enclosing class:
- ClusterReceptionist
public static final class ClusterReceptionist.State extends java.lang.Object implements scala.Product, java.io.Serializable
param: registry The last seen state from the replicator - only updated when we get an update from th replicator param: servicesPerActor needed since an actor can implement several services param: tombstones Local actors that were stopped and should not be re-added to the available set of actors for a key. param: subscriptions Locally subscriptions, not replicated- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description State(ShardedServiceRegistry registry, scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<AbstractServiceKey>> servicesPerActor, scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<scala.Tuple2<AbstractServiceKey,scala.concurrent.duration.Deadline>>> tombstones, TypedMultiMap<AbstractServiceKey,ActorRef> subscriptions)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <T> scala.Tuple2<scala.collection.immutable.Set<ActorRef<T>>,scala.collection.immutable.Set<ActorRef<T>>>
activeActorRefsFor(ServiceKey<T> key, UniqueAddress selfUniqueAddress)
<T> ClusterReceptionist.State
addLocalService(ActorRef<T> serviceInstance, ServiceKey<T> key)
ClusterReceptionist.State
addTombstone(ActorRef<?> actor, scala.concurrent.duration.Deadline deadline)
tombstone all services actor is registered for<T> ClusterReceptionist.State
addTombstone(ActorRef<T> actor, ServiceKey<T> serviceKey, scala.concurrent.duration.Deadline deadline)
tombstone specific service actor is registered forboolean
canEqual(java.lang.Object x$1)
ClusterReceptionist.State
copy(ShardedServiceRegistry registry, scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<AbstractServiceKey>> servicesPerActor, scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<scala.Tuple2<AbstractServiceKey,scala.concurrent.duration.Deadline>>> tombstones, TypedMultiMap<AbstractServiceKey,ActorRef> subscriptions)
ShardedServiceRegistry
copy$default$1()
scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<AbstractServiceKey>>
copy$default$2()
scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<scala.Tuple2<AbstractServiceKey,scala.concurrent.duration.Deadline>>>
copy$default$3()
TypedMultiMap<AbstractServiceKey,ActorRef>
copy$default$4()
boolean
equals(java.lang.Object x$1)
int
hashCode()
<T> boolean
hasTombstone(ServiceKey<T> serviceKey, ActorRef<T> actorRef)
int
productArity()
java.lang.Object
productElement(int x$1)
java.lang.String
productElementName(int x$1)
scala.collection.Iterator<java.lang.Object>
productIterator()
java.lang.String
productPrefix()
ClusterReceptionist.State
pruneTombstones()
ShardedServiceRegistry
registry()
<T> ClusterReceptionist.State
removeLocalService(ActorRef<T> serviceInstance, ServiceKey<T> key, scala.concurrent.duration.Deadline tombstoneDeadline)
ClusterReceptionist.State
removeSubscriber(ActorRef<ReceptionistMessages.Listing<java.lang.Object>> subscriber)
scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<AbstractServiceKey>>
servicesPerActor()
TypedMultiMap<AbstractServiceKey,ActorRef>
subscriptions()
scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<scala.Tuple2<AbstractServiceKey,scala.concurrent.duration.Deadline>>>
tombstones()
java.lang.String
toString()
-
-
-
Constructor Detail
-
State
public State(ShardedServiceRegistry registry, scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<AbstractServiceKey>> servicesPerActor, scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<scala.Tuple2<AbstractServiceKey,scala.concurrent.duration.Deadline>>> tombstones, TypedMultiMap<AbstractServiceKey,ActorRef> subscriptions)
-
-
Method Detail
-
registry
public ShardedServiceRegistry registry()
-
servicesPerActor
public scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<AbstractServiceKey>> servicesPerActor()
-
tombstones
public scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<scala.Tuple2<AbstractServiceKey,scala.concurrent.duration.Deadline>>> tombstones()
-
subscriptions
public TypedMultiMap<AbstractServiceKey,ActorRef> subscriptions()
-
addTombstone
public ClusterReceptionist.State addTombstone(ActorRef<?> actor, scala.concurrent.duration.Deadline deadline)
tombstone all services actor is registered for
-
addTombstone
public <T> ClusterReceptionist.State addTombstone(ActorRef<T> actor, ServiceKey<T> serviceKey, scala.concurrent.duration.Deadline deadline)
tombstone specific service actor is registered for
-
hasTombstone
public <T> boolean hasTombstone(ServiceKey<T> serviceKey, ActorRef<T> actorRef)
-
pruneTombstones
public ClusterReceptionist.State pruneTombstones()
-
activeActorRefsFor
public <T> scala.Tuple2<scala.collection.immutable.Set<ActorRef<T>>,scala.collection.immutable.Set<ActorRef<T>>> activeActorRefsFor(ServiceKey<T> key, UniqueAddress selfUniqueAddress)
- Returns:
- (reachable-nodes, all)
-
addLocalService
public <T> ClusterReceptionist.State addLocalService(ActorRef<T> serviceInstance, ServiceKey<T> key)
-
removeLocalService
public <T> ClusterReceptionist.State removeLocalService(ActorRef<T> serviceInstance, ServiceKey<T> key, scala.concurrent.duration.Deadline tombstoneDeadline)
-
removeSubscriber
public ClusterReceptionist.State removeSubscriber(ActorRef<ReceptionistMessages.Listing<java.lang.Object>> subscriber)
-
copy
public ClusterReceptionist.State copy(ShardedServiceRegistry registry, scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<AbstractServiceKey>> servicesPerActor, scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<scala.Tuple2<AbstractServiceKey,scala.concurrent.duration.Deadline>>> tombstones, TypedMultiMap<AbstractServiceKey,ActorRef> subscriptions)
-
copy$default$1
public ShardedServiceRegistry copy$default$1()
-
copy$default$2
public scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<AbstractServiceKey>> copy$default$2()
-
copy$default$3
public scala.collection.immutable.Map<ActorRef<?>,scala.collection.immutable.Set<scala.Tuple2<AbstractServiceKey,scala.concurrent.duration.Deadline>>> copy$default$3()
-
copy$default$4
public TypedMultiMap<AbstractServiceKey,ActorRef> copy$default$4()
-
productPrefix
public java.lang.String productPrefix()
- Specified by:
productPrefix
in interfacescala.Product
-
productArity
public int productArity()
- Specified by:
productArity
in interfacescala.Product
-
productElement
public java.lang.Object productElement(int x$1)
- Specified by:
productElement
in interfacescala.Product
-
productIterator
public scala.collection.Iterator<java.lang.Object> productIterator()
- Specified by:
productIterator
in interfacescala.Product
-
canEqual
public boolean canEqual(java.lang.Object x$1)
- Specified by:
canEqual
in interfacescala.Equals
-
productElementName
public java.lang.String productElementName(int x$1)
- Specified by:
productElementName
in interfacescala.Product
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object x$1)
- Specified by:
equals
in interfacescala.Equals
- Overrides:
equals
in classjava.lang.Object
-
-