qa-saga-cqrs
Saga + CQRS + event sourcing test patterns: 5 skills (cqrs-projection-tests, event-sourcing-tests, eventual-consistency-tests, outbox-pattern-test-author, saga-transaction-tests) and 1 agent (saga-critic). Covers ACD-without-isolation saga tests, replay determinism, and projection consistency windows.
Install this plugin
/plugin install qa-saga-cqrs@testland-qaPart of role bundle: qa-role-backend
qa-saga-cqrs
Distributed-transaction patterns: sagas (replace 2PC across microservices), event sourcing (events as system of record) with CQRS projection testing and the eventual-consistency convergence window folded into its references, and the transactional outbox.
Components
| Type | Name | Description |
|---|---|---|
| Agent | saga-critic | Audits saga orchestrators and event-sourcing write paths for missing compensating transactions, non-idempotent compensations, dual-write without outbox, absent retry policy, and missing optimistic-concurrency guard on event append. Emits BLOCK / PASS verdict. |
| Skill | saga-transaction-tests | Orchestration vs choreography; per-step compensating-action verification; partial-failure matrix; outbox pattern atomicity; saga timeout |
| Skill | event-sourcing-tests | Aggregate-replay determinism; snapshot equivalence; event-versioning + upcasting; CQRS projection rebuild + zero-downtime swap + idempotent/out-of-order apply; convergence-window assertions in references/ |
| Skill | outbox-pattern-test-author | Tests the transactional outbox: atomic write+event, relay at-least-once + dedup + ordering + retry. |
Install
/plugin marketplace add testland/qa
/plugin install qa-saga-cqrs@testland-qaSkills
event-sourcing-tests
Build event-sourcing + CQRS tests - the given-events / when-command / then-events aggregate test, replay determinism (same events produce the same state), event-versioning + upcasting, snapshot equivalence (replay-to-N vs snapshot-at-N must agree), retroactive event correction, and CQRS read-model projection tests (per-event projection deltas, idempotent + out-of-order apply, rebuild + zero-downtime swap, read-your-writes guard) with eventual-consistency convergence-window assertions in references/convergence-windows.md. Per martinfowler.com EventSourcing + CQRS references. Use when an event-sourced aggregate gains a new event type or a changed payload schema, when snapshots are introduced to shorten replay, when a read model is projected from the event stream, or when a documented convergence window needs a test.
outbox-pattern-test-author
Authors tests for the transactional outbox pattern: atomic DB-write-plus-event-insert in one transaction, relay/poller publishing with at-least-once delivery and consumer deduplication, insertion-order preservation, idempotent consumers, and relay failure/retry. Use when adding outbox infrastructure, changing the relay or poller, or auditing whether dual-write atomicity and at-least-once delivery guarantees hold under failure.
saga-transaction-tests
Build saga transaction tests - orchestration vs choreography variants, per-step compensating-action verification, partial-failure scenarios (Step 3 fails → Steps 1+2 must compensate), idempotency of compensations, outbox pattern for atomic DB-update + message-publish. Per microservices.io/saga; tests guard against ACD-without-Isolation anomalies. Use when a business transaction spans two or more services and the compensating paths for a mid-sequence failure have no coverage, or right after compensation logic changes.