Skip to content
Agentmart
Submit a tool

event-driven

Event-driven — sourcing, CQRS, saga, idempotency, schema registry.

Skill by Dev-Toolbelt

IndexedMIT★ 7
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/dev-toolbelt-event-driven

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Event-driven — sourcing, CQRS, saga, idempotency, schema registry.

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/event-driven

What's inside

Skill name
event-driven
Description
Event-driven — sourcing, CQRS, saga, idempotency, schema registry.
License
MIT
Instructions
65 lines in SKILL.md · view on GitHub

Files (1)

  • SKILL.md

SKILL.md (first lines)

# Event-Driven Architecture

## When to Load

Load when the project uses message queues (Kafka, RabbitMQ, SQS, Pub/Sub), event stores, or distributed transactions.

## Core Patterns

| Pattern | Use when | Key constraint |
|---------|----------|----------------|
| **Event Sourcing** | Audit log required; time-travel queries needed | Event log is append-only; state derived on read |
| **CQRS** | Read and write models diverge; separate scaling needed | Two models must stay eventually consistent |
| **Saga (Orchestration)** | Central coordinator acceptable; easier debugging | Single point of failure in orchestrator |
| **Saga (Choreography)** | Loose coupling preferred; no central bottleneck | Harder to trace; each service reacts to events |
| **Outbox Pattern** | Atomicity between DB write and event publish required | Requires outbox table + background publisher |

## Event Types

| Type | Scope | Versioning |
|------|-------|------------|
| Domain event | Within a bounded context | Internal; break freely |
| Integration event | Crosses bounded contexts | Public contract; version explicitly |

## Idempotency

Every consumer must handle duplicate events:
- Store processed event IDs (`event_id` column or Redis SET)
- Check before processing: if already processed, return success without side effects
- Use idempotency key in HTTP retries (`Idempotency-Key` header)

## Schema & Versioning

| Strategy | Tooling | Trade-off |
|----------|---------|-----------|
| Schema registry | Confluent Registry, AWS Glue | Enforces contract; requires registry infra |
| Avro / Protobuf | Binary; backward/forward compatible with rules | Requires code generation |
| JSON Schema | Human-readable; no code gen | Weaker enforcement |

**Backward-compatible changes**: add optional fields, add enum values at end.
**Breaking changes**: remove fields, rename fields, change types → require new event version.

## Eventual Consistency Trade-offs

- **Read-your-writes**: client must read from the same replica or cache the write locally
- **Causality**: tag events with a `causation_id` and `correlation_id`
- **Compensating transactions**: for sagas, define a compensating action for every step that can fail

## Failure Modes

| Failure | Mitigation |
|---------|------------|
| Consumer lag | Dead-letter queue (DLQ) + alerting on lag |
| Duplicate delivery | Idempotency (see above) |
| Ordering guarantee lost | Partition by entity ID; use sequence numbers |
| Event store grows unbounded | Snapshots: periodically collapse N events into current state |

## Decision Checklist

- [ ] Does the domain require a full audit log? → consider event sourcing
- [ ] Do read and write patterns differ significantly? → consider CQRS
- [ ] Do you need distributed transactions across services? → choose saga strategy
- [ ] Is your message broker at-least-once? → implement idempotent consumers
- [ ] Are events crossing team/service boundaries? → define integration events with explicit versions

From Dev-Toolbelt/dev-team-agents, MIT.

More from Dev-Toolbelt/dev-team-agents

Signals

Stars
7
Forks
0
Open issues
0
Last commit (this folder)
Oct 18, 2026 (10 days ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from Dev-Toolbelt

Cite this page

event-driven skill. Agent Mart. https://agentmart.dev/skills/dev-toolbelt-event-driven (last updated 2026-10-24)