object DistributedData extends ExtensionId[DistributedData]
- Source
- DistributedData.scala
- Alphabetic
- By Inheritance
- DistributedData
- ExtensionId
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Value Members
- final def apply(system: ActorSystem[_]): DistributedData
Lookup or create an instance of the extension identified by this id.
Lookup or create an instance of the extension identified by this id.
- Definition Classes
- ExtensionId
- def createExtension(system: ActorSystem[_]): DistributedData
Create the extension, will be invoked at most one time per actor system where the extension is registered.
Create the extension, will be invoked at most one time per actor system where the extension is registered.
- Definition Classes
- → ExtensionId
- final def equals(other: Any): Boolean
- Definition Classes
- ExtensionId → AnyRef → Any
- def get(system: ActorSystem[_]): DistributedData
- final def hashCode(): Int
- Definition Classes
- ExtensionId → AnyRef → Any
- def id: [DistributedData]
Java API: The identifier of the extension
Java API: The identifier of the extension
- Definition Classes
- ExtensionId
- def withReplicatorMessageAdapter[A, B <: ReplicatedData](factory: (ReplicatorMessageAdapter[A, B]) => Behavior[A]): Behavior[A]
When interacting with the from an actor the ReplicatorMessageAdapter provides convenient methods that adapts the response messages to the requesting actor's message protocol.
When interacting with the from an actor the ReplicatorMessageAdapter provides convenient methods that adapts the response messages to the requesting actor's message protocol.
One
ReplicatorMessageAdapter
instance can be used for a givenReplicatedData
type, e.g. anOrSet[String]
. Interaction with several akka.cluster.ddata.Keys can be used via the same adapter but they must all be of the sameReplicatedData
type. For interaction with several differentReplicatedData
types, e.g. anOrSet[String]
and aGCounter
, an adapter can be created for each type.*Warning*: A
ReplicatorMessageAdapter
instance is not thread-safe and must only be used from a single actor It must not be accessed from threads other than the ordinary actor message processing thread, such as scala.concurrent.Future callbacks. It must not be shared between several actor instances.- A
Message type of the requesting actor.
- B
Type of the ReplicatedData.
- factory
Factory of the
Behavior
for the actor that is using theReplicatorMessageAdapter