Packages

final class EventProducerSource extends AnyRef

Annotations
@ApiMayChange()
Source
EventProducer.scala
Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. EventProducerSource
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Value Members

  1. def copy(entityType: String = entityType, streamId: String = streamId, transformation: Transformation = transformation, settings: EventProducerSettings = settings, producerFilter: (EventEnvelope[Any]) => Boolean = producerFilter, transformSnapshot: Option[(Any) => Any] = transformSnapshot, replicatedEventOriginFilter: Option[EventOriginFilter] = replicatedEventOriginFilter): EventProducerSource
  2. val entityType: String
  3. val producerFilter: (EventEnvelope[Any]) => Boolean
  4. val settings: EventProducerSettings
  5. val streamId: String
  6. val transformSnapshot: Option[(Any) => Any]
  7. val transformation: Transformation
  8. def withProducerFilter[Event](producerFilter: (EventEnvelope[Event]) => Boolean): EventProducerSource

    Filter events matching the predicate, for example based on tags.

  9. def withReplicatedEventOriginFilter(filter: EventOriginFilter): EventProducerSource
  10. def withStartingFromSnapshots[Snapshot, Event](transformSnapshot: (Snapshot) => Event): EventProducerSource

    Use snapshots as starting points and thereby reducing number of events that have to be loaded.

    Use snapshots as starting points and thereby reducing number of events that have to be loaded. This can be useful if the consumer start from zero without any previously processed offset or if it has been disconnected for a long while and its offset is far behind.

    First it loads all snapshots with timestamps greater than or equal to the offset timestamp. There is at most one snapshot per persistenceId. The snapshots are transformed to events with the given transformSnapshot function.

    After emitting the snapshot events the ordinary events with sequence numbers after the snapshots are emitted.

    Important note: This should not be used together with EventProducerPush. In that case SourceProvider with eventsBySlicesStartingFromSnapshots should be used instead.

  11. def withTopicProducerFilter(topicExpression: String): EventProducerSource

    Filter events matching the topic expression according to MQTT specification, including wildcards.

    Filter events matching the topic expression according to MQTT specification, including wildcards. The topic of an event is defined by a tag with certain prefix, see topic-tag-prefix configuration.