TestProjection

akka.projection.testkit.javadsl.TestProjection$
See theTestProjection companion trait

Attributes

Companion:
trait
Source:
TestProjection.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Concise view

Value members

Concrete methods

def create[Offset, Envelope](projectionId: ProjectionId, sourceProvider: SourceProvider[Offset, Envelope], handler: Supplier[Handler[Envelope]]): TestProjection[Offset, Envelope]

Create a TestProjection that can be used to assert a akka.projection.javadsl.Handler implementation.

Create a TestProjection that can be used to assert a akka.projection.javadsl.Handler implementation.

The TestProjection allows the user to test their akka.projection.javadsl.Handler implementation in isolation, without requiring the Projection implementation (i.e. a database) to exist at test runtime.

The akka.projection.javadsl.SourceProvider can be a concrete implementation, or a TestSourceProvider to provide further test isolation.

The TestProjection uses an at-least-once offset saving strategy where an offset is saved for each element.

The TestProjection does not support grouping, at least once offset batching, or restart backoff strategies.

Attributes

handler
projectionId
  • a Projection ID
sourceProvider
Source:
TestProjection.scala