NoOpSnapshotRepository

No-operation implementation of SnapshotRepository that does nothing. Useful for testing or when snapshots are not needed.

Properties

Link copied to clipboard
const val NAME: String

The name of this repository.

Link copied to clipboard
open override val name: String

The name of this repository.

Functions

Link copied to clipboard
open fun getVersion(aggregateId: AggregateId): Mono<Int>

Gets the version of the latest snapshot for the specified aggregate. Returns UNINITIALIZED_VERSION if no snapshot exists.

Link copied to clipboard
open override fun <S : Any> load(aggregateId: AggregateId): Mono<Snapshot<S>>

Always returns empty, as this is a no-op repository.

Link copied to clipboard

Wraps a SnapshotRepository with metrics collection capabilities. Returns a MetricSnapshotRepository that collects metrics on snapshot storage operations.

Link copied to clipboard
open override fun <S : Any> save(snapshot: Snapshot<S>): Mono<Void>

Does nothing, as this is a no-op repository.

Link copied to clipboard
open override fun scanAggregateId(namedAggregate: NamedAggregate, afterId: String, limit: Int): Flux<AggregateId>

Always returns empty, as this is a no-op repository.