Class/Object

com.rbmhtechnology.eventuate.log

EventLog

Related Docs: object EventLog | package log

Permalink

abstract class EventLog[A <: EventLogState] extends Actor with EventLogSPI[A] with Stash

An abstract event log that handles EventsourcingProtocol and ReplicationProtocol messages and translates them to read and write operations declared on the EventLogSPI trait. Storage providers implement an event log by implementing the EventLogSPI.

A

Event log state type (a subtype of EventLogState).

Linear Supertypes
Stash, RequiresMessageQueue[DequeBasedMessageQueueSemantics], UnrestrictedStash, StashSupport, EventLogSPI[A], Actor, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. EventLog
  2. Stash
  3. RequiresMessageQueue
  4. UnrestrictedStash
  5. StashSupport
  6. EventLogSPI
  7. Actor
  8. AnyRef
  9. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new EventLog(id: String)

    Permalink

Type Members

  1. type Receive = PartialFunction[Any, Unit]

    Permalink
    Definition Classes
    Actor

Abstract Value Members

  1. abstract def read(fromSequenceNr: Long, toSequenceNr: Long, max: Int, aggregateId: String): Future[BatchReadResult]

    Permalink

    Asynchronously batch-reads events whose destinationAggregateIds contains the given aggregateId.

    Asynchronously batch-reads events whose destinationAggregateIds contains the given aggregateId. At most max events must be returned that are within the sequence number bounds fromSequenceNr and toSequenceNr.

    fromSequenceNr

    sequence number to start reading (inclusive).

    toSequenceNr

    sequence number to stop reading (inclusive) or earlier if max events have already been read.

    Definition Classes
    EventLogSPI
  2. abstract def read(fromSequenceNr: Long, toSequenceNr: Long, max: Int): Future[BatchReadResult]

    Permalink

    Asynchronously batch-reads events from the raw event log.

    Asynchronously batch-reads events from the raw event log. At most max events must be returned that are within the sequence number bounds fromSequenceNr and toSequenceNr.

    fromSequenceNr

    sequence number to start reading (inclusive).

    toSequenceNr

    sequence number to stop reading (inclusive) or earlier if max events have already been read.

    Definition Classes
    EventLogSPI
  3. abstract def readReplicationProgress(logId: String): Future[Long]

    Permalink

    Asynchronously reads the replication progress for given source logId.

    Asynchronously reads the replication progress for given source logId.

    Definition Classes
    EventLogSPI
    See also

    ReplicationProtocol.GetReplicationProgress

  4. abstract def readReplicationProgresses: Future[Map[String, Long]]

    Permalink

    Asynchronously reads all stored local replication progresses.

    Asynchronously reads all stored local replication progresses.

    Definition Classes
    EventLogSPI
    See also

    ReplicationProtocol.GetReplicationProgresses

  5. abstract def recoverState: Future[A]

    Permalink

    Asynchronously recovers event log state from the storage backend.

    Asynchronously recovers event log state from the storage backend.

    Definition Classes
    EventLogSPI
  6. abstract def replicationRead(fromSequenceNr: Long, toSequenceNr: Long, max: Int, scanLimit: Int, filter: (DurableEvent) ⇒ Boolean): Future[BatchReadResult]

    Permalink

    Asynchronously batch-reads events from the raw event log.

    Asynchronously batch-reads events from the raw event log. At most max events must be returned that are within the sequence number bounds fromSequenceNr and toSequenceNr and that pass the given filter.

    fromSequenceNr

    sequence number to start reading (inclusive).

    toSequenceNr

    sequence number to stop reading (inclusive) or earlier if max events have already been read.

    Definition Classes
    EventLogSPI
  7. abstract def settings: EventLogSettings

    Permalink

    Event log settings.

    Event log settings.

    Definition Classes
    EventLogSPI
  8. abstract def write(events: Seq[DurableEvent], partition: Long, clock: EventLogClock): Unit

    Permalink

    Synchronously writes events to the given partition.

    Synchronously writes events to the given partition. The partition is calculated from the configured partitionSizeMax and the current sequence number. Asynchronous writes will be supported in future versions.

    This method may only throw an exception if it can guarantee that events have not been written to the storage backend. If this is not the case (e.g. after a timeout communicating with a remote storage backend) this method must retry writing or give up by stopping the actor with context.stop(self). This is necessary to avoid that events are erroneously excluded from the event stream sent to event-sourced actors, views, writers and processors, as they may later re-appear during recovery which would violate ordering/causality guarantees.

    Implementations that potentially retry a write for a longer time should use a CircuitBreaker for protecting themselves against request overload.

    Definition Classes
    EventLogSPI
    See also

    EventLogSettings

  9. abstract def writeDeletionMetadata(data: DeletionMetadata): Unit

    Permalink

    Synchronously writes metadata for a Delete request.

    Synchronously writes metadata for a Delete request. This marks events up to DeletionMetadata.toSequenceNr as deleted, i.e. they are not read on replay and indicates which remote logs must have replicated these events before they are allowed to be physically deleted locally.

    Definition Classes
    EventLogSPI
  10. abstract def writeEventLogClockSnapshot(clock: EventLogClock): Future[Unit]

    Permalink

    Asynchronously writes the current snapshot of the event log clock

    Asynchronously writes the current snapshot of the event log clock

    Definition Classes
    EventLogSPI
  11. abstract def writeReplicationProgresses(progresses: Map[String, Long]): Future[Unit]

    Permalink

    Asynchronously writes the replication progresses for source log ids given by progresses keys.

    Asynchronously writes the replication progresses for source log ids given by progresses keys.

    Definition Classes
    EventLogSPI

Concrete 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. def aroundPostRestart(reason: Throwable): Unit

    Permalink
    Attributes
    protected[akka]
    Definition Classes
    Actor
    Annotations
    @InternalApi()
  5. def aroundPostStop(): Unit

    Permalink
    Attributes
    protected[akka]
    Definition Classes
    Actor
    Annotations
    @InternalApi()
  6. def aroundPreRestart(reason: Throwable, message: Option[Any]): Unit

    Permalink
    Attributes
    protected[akka]
    Definition Classes
    Actor
    Annotations
    @InternalApi()
  7. def aroundPreStart(): Unit

    Permalink
    Attributes
    protected[akka]
    Definition Classes
    Actor
    Annotations
    @InternalApi()
  8. def aroundReceive(receive: akka.actor.Actor.Receive, msg: Any): Unit

    Permalink
    Attributes
    protected[akka]
    Definition Classes
    Actor
    Annotations
    @InternalApi()
  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. implicit val context: ActorContext

    Permalink
    Definition Classes
    Actor
  12. def delete(toSequenceNr: Long): Future[Long]

    Permalink

    Instructs the log to asynchronously and physically delete events up to toSequenceNr.

    Instructs the log to asynchronously and physically delete events up to toSequenceNr. This operation completes when physical deletion completed and returns the sequence nr up to which events have been deleted. This can be smaller then the requested toSequenceNr if a backend has to keep events for internal reasons. A backend that does not support physical deletion should not override this method.

    Definition Classes
    EventLogSPI
  13. final def eq(arg0: AnyRef): Boolean

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

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

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  16. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  17. def hashCode(): Int

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

    Permalink
    Definition Classes
    Any
  19. val logger: LoggingAdapter

    Permalink

    This event log's logging adapter.

  20. final def ne(arg0: AnyRef): Boolean

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

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

    Permalink
    Definition Classes
    AnyRef
  23. def postRestart(reason: Throwable): Unit

    Permalink
    Definition Classes
    Actor
    Annotations
    @throws( classOf[java.lang.Exception] )
  24. def postStop(): Unit

    Permalink
    Definition Classes
    UnrestrictedStash → Actor
  25. def preRestart(reason: Throwable, message: Option[Any]): Unit

    Permalink
    Definition Classes
    UnrestrictedStash → Actor
  26. def preStart(): Unit

    Permalink
    Definition Classes
    EventLog → Actor
  27. def receive: Receive

    Permalink
    Definition Classes
    EventLog → Actor
  28. def recoverStateFailure(cause: Throwable): Unit

    Permalink

    Called after failed event log state recovery.

    Called after failed event log state recovery.

    Definition Classes
    EventLogSPI
  29. def recoverStateSuccess(state: A): Unit

    Permalink

    Called after successful event log state recovery.

    Called after successful event log state recovery.

    Definition Classes
    EventLogSPI
  30. implicit final val self: ActorRef

    Permalink
    Definition Classes
    Actor
  31. final def sender(): ActorRef

    Permalink
    Definition Classes
    Actor
  32. object services

    Permalink

    Service context for asynchronous read operations.

  33. def stash(): Unit

    Permalink
    Definition Classes
    StashSupport
  34. def supervisorStrategy: SupervisorStrategy

    Permalink
    Definition Classes
    Actor
  35. final def synchronized[T0](arg0: ⇒ T0): T0

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

    Permalink
    Definition Classes
    AnyRef → Any
  37. def unhandled(message: Any): Unit

    Permalink
    Definition Classes
    Actor
  38. def unstashAll(): Unit

    Permalink
    Definition Classes
    StashSupport
  39. final def wait(): Unit

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

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

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Stash

Inherited from RequiresMessageQueue[DequeBasedMessageQueueSemantics]

Inherited from UnrestrictedStash

Inherited from StashSupport

Inherited from EventLogSPI[A]

Inherited from Actor

Inherited from AnyRef

Inherited from Any

Ungrouped