Skip to content

Support for asynchronous, incremental snapshot capturing #102

@volkerstampa

Description

@volkerstampa

Imagine the following scenario:

  • 2 actors: A, B
  • A is eventsourced and
    • gets message from "outside"
    • updates its internal state
    • computes new messages and sends them to B
  • B is not eventsourced
    • gets message only from A
    • updates its internal state

In this case taking snapshots in a straightforward manner does not lead to consistent recovery as message sent from A to B could be either applied twice or get lost. For consistent recovery the following trick can be applied:

  • Send SnapshotRequest to A
  • A creates A-snapshot and does not call SnapshotRequest.process, but forwards its snapshot in custom message to B
  • B creates B-snapshot and combines it with received A-snapshot to AB-snapshot
  • B calls SnapshotRequest.process(AB-snapshot)

Having library support for this kind of consistent snapshots could relieve a developer from implementing the described process and probably saves a couple of process related custom types.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions