Object/Class

akka.cluster.ddata

Replicator

Related Docs: class Replicator | package ddata

Permalink

object Replicator

Source
Replicator.scala
Linear Supertypes
Content Hierarchy Learn more about scaladoc diagrams
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Replicator
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Visibility
  1. Public
  2. All

Type Members

  1. final case class Changed[A <: ReplicatedData](key: Key[A])(data: A) extends ReplicatorMessage with Product with Serializable

    Permalink

    The data value is retrieved with #get using the typed key.

    The data value is retrieved with #get using the typed key.

    See also

    Replicator.Subscribe

  2. sealed trait Command[A <: ReplicatedData] extends AnyRef

    Permalink
  3. final case class DataDeleted[A <: ReplicatedData](key: Key[A]) extends RuntimeException with NoStackTrace with DeleteResponse[A] with Product with Serializable

    Permalink
  4. final case class Delete[A <: ReplicatedData](key: Key[A], consistency: WriteConsistency) extends Command[A] with Product with Serializable

    Permalink

    Send this message to the local Replicator to delete a data value for the given key.

    Send this message to the local Replicator to delete a data value for the given key. The Replicator will reply with one of the DeleteResponse messages.

  5. sealed trait DeleteResponse[A <: ReplicatedData] extends AnyRef

    Permalink
  6. final case class DeleteSuccess[A <: ReplicatedData](key: Key[A]) extends DeleteResponse[A] with Product with Serializable

    Permalink
  7. final case class Get[A <: ReplicatedData](key: Key[A], consistency: ReadConsistency, request: Option[Any] = None) extends Command[A] with ReplicatorMessage with Product with Serializable

    Permalink

    Send this message to the local Replicator to retrieve a data value for the given key.

    Send this message to the local Replicator to retrieve a data value for the given key. The Replicator will reply with one of the GetResponse messages.

    The optional request context is included in the reply messages. This is a convenient way to pass contextual information (e.g. original sender) without having to use ask or maintain local correlation data structures.

  8. final case class GetFailure[A <: ReplicatedData](key: Key[A], request: Option[Any]) extends GetResponse[A] with ReplicatorMessage with Product with Serializable

    Permalink

    The Get request could not be fulfill according to the given consistency level and timeout.

  9. sealed abstract class GetResponse[A <: ReplicatedData] extends NoSerializationVerificationNeeded

    Permalink
  10. final case class GetSuccess[A <: ReplicatedData](key: Key[A], request: Option[Any])(data: A) extends GetResponse[A] with ReplicatorMessage with Product with Serializable

    Permalink

    Reply from Get.

    Reply from Get. The data value is retrieved with #get using the typed key.

  11. final case class ModifyFailure[A <: ReplicatedData](key: Key[A], errorMessage: String, cause: Throwable, request: Option[Any]) extends UpdateFailure[A] with Product with Serializable

    Permalink

    If the modify function of the Update throws an exception the reply message will be this ModifyFailure message.

    If the modify function of the Update throws an exception the reply message will be this ModifyFailure message. The original exception is included as cause.

  12. final case class NotFound[A <: ReplicatedData](key: Key[A], request: Option[Any]) extends GetResponse[A] with ReplicatorMessage with Product with Serializable

    Permalink
  13. final case class ReadAll(timeout: FiniteDuration) extends ReadConsistency with Product with Serializable

    Permalink
  14. sealed trait ReadConsistency extends AnyRef

    Permalink
  15. final case class ReadFrom(n: Int, timeout: FiniteDuration) extends ReadConsistency with Product with Serializable

    Permalink
  16. final case class ReadMajority(timeout: FiniteDuration) extends ReadConsistency with Product with Serializable

    Permalink
  17. final case class ReplicaCount(n: Int) extends Product with Serializable

    Permalink

    Current number of replicas.

    Current number of replicas. Reply to GetReplicaCount.

  18. final case class ReplicationDeleteFailure[A <: ReplicatedData](key: Key[A]) extends DeleteResponse[A] with Product with Serializable

    Permalink
  19. trait ReplicatorMessage extends Serializable

    Permalink

    Marker trait for remote messages serialized by akka.cluster.ddata.protobuf.ReplicatorMessageSerializer.

  20. final case class Subscribe[A <: ReplicatedData](key: Key[A], subscriber: ActorRef) extends ReplicatorMessage with Product with Serializable

    Permalink

    Register a subscriber that will be notified with a Changed message when the value of the given key is changed.

    Register a subscriber that will be notified with a Changed message when the value of the given key is changed. Current value is also sent as a Changed message to a new subscriber.

    Subscribers will be notified periodically with the configured notify-subscribers-interval, and it is also possible to send an explicit FlushChanges message to the Replicator to notify the subscribers immediately.

    The subscriber will automatically be unregistered if it is terminated.

    If the key is deleted the subscriber is notified with a DataDeleted message.

  21. final case class Unsubscribe[A <: ReplicatedData](key: Key[A], subscriber: ActorRef) extends ReplicatorMessage with Product with Serializable

    Permalink

    Unregister a subscriber.

    Unregister a subscriber.

    See also

    Replicator.Subscribe

  22. final case class Update[A <: ReplicatedData](key: Key[A], writeConsistency: WriteConsistency, request: Option[Any])(modify: (Option[A]) ⇒ A) extends Command[A] with NoSerializationVerificationNeeded with Product with Serializable

    Permalink

    Send this message to the local Replicator to update a data value for the given key.

    Send this message to the local Replicator to update a data value for the given key. The Replicator will reply with one of the UpdateResponse messages.

    Note that the companion object provides apply functions for convenient construction of this message.

    The current data value for the key is passed as parameter to the modify function. It is None if there is no value for the key, and otherwise Some(data). The function is supposed to return the new value of the data, which will then be replicated according to the given writeConsistency.

    The modify function is called by the Replicator actor and must therefore be a pure function that only uses the data parameter and stable fields from enclosing scope. It must for example not access sender() reference of an enclosing actor.

  23. sealed abstract class UpdateFailure[A <: ReplicatedData] extends UpdateResponse[A]

    Permalink
  24. sealed abstract class UpdateResponse[A <: ReplicatedData] extends NoSerializationVerificationNeeded

    Permalink
  25. final case class UpdateSuccess[A <: ReplicatedData](key: Key[A], request: Option[Any]) extends UpdateResponse[A] with Product with Serializable

    Permalink
  26. final case class UpdateTimeout[A <: ReplicatedData](key: Key[A], request: Option[Any]) extends UpdateFailure[A] with Product with Serializable

    Permalink

    The direct replication of the Update could not be fulfill according to the given consistency level and timeout.

    The direct replication of the Update could not be fulfill according to the given consistency level and timeout.

    The Update was still performed locally and possibly replicated to some nodes. It will eventually be disseminated to other replicas, unless the local replica crashes before it has been able to communicate with other replicas.

  27. final case class WriteAll(timeout: FiniteDuration) extends WriteConsistency with Product with Serializable

    Permalink
  28. sealed trait WriteConsistency extends AnyRef

    Permalink
  29. final case class WriteMajority(timeout: FiniteDuration) extends WriteConsistency with Product with Serializable

    Permalink
  30. final case class WriteTo(n: Int, timeout: FiniteDuration) extends WriteConsistency with Product with Serializable

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. object FlushChanges extends Product with Serializable

    Permalink

    Notify subscribers of changes now, otherwise they will be notified periodically with the configured notify-subscribers-interval.

  5. object GetReplicaCount extends Product with Serializable

    Permalink

    Get current number of replicas, including the local replica.

    Get current number of replicas, including the local replica. Will reply to sender with ReplicaCount.

  6. object ReadLocal extends ReadConsistency with Product with Serializable

    Permalink
  7. object Update extends Serializable

    Permalink
  8. object WriteLocal extends WriteConsistency with Product with Serializable

    Permalink
  9. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  10. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  11. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  13. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  14. def flushChanges: FlushChanges.type

    Permalink

    Java API: The FlushChanges instance

  15. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  16. def getReplicaCount: GetReplicaCount.type

    Permalink

    Java API: The GetReplicaCount instance

  17. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  18. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  19. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  20. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  21. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  22. def props(settings: ReplicatorSettings): Props

    Permalink

    Factory method for the akka.actor.Props of the Replicator actor.

  23. def readLocal: ReadLocal.type

    Permalink

    Java API: The ReadLocal instance

  24. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  25. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  26. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  27. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  28. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  29. def writeLocal: WriteLocal.type

    Permalink

    Java API: The WriteLocal instance

Inherited from AnyRef

Inherited from Any

Ungrouped