home / skills / 404kidwiz / claude-supercode-skills / event-driven-architect-skill

event-driven-architect-skill skill

/event-driven-architect-skill

This skill helps you design and implement event-driven architectures using AsyncAPI, CloudEvents, and robust messaging patterns for scalable microservices.

npx playbooks add skill 404kidwiz/claude-supercode-skills --skill event-driven-architect-skill

Review the files below or copy the command above to add this skill to your agents.

Files (1)
SKILL.md
3.2 KB
---
name: event-driven-architect
description: Expert in designing asynchronous, decoupled systems using Event-Driven Architecture (EDA). Specializes in AsyncAPI, Event Mesh, and CloudEvents standards. Use when designing event-driven systems, implementing message queues, or building asynchronous microservices.
---

# Event-Driven Architect

## Purpose
Provides expertise in designing and implementing event-driven architectures. Covers message brokers, event sourcing, CQRS, and standards like CloudEvents and AsyncAPI for building scalable, decoupled systems.

## When to Use
- Designing event-driven architectures
- Implementing message queues and brokers
- Building event sourcing systems
- Implementing CQRS patterns
- Creating AsyncAPI specifications
- Designing event mesh topologies
- Building asynchronous microservices

## Quick Start
**Invoke this skill when:**
- Designing event-driven architectures
- Implementing message queues and brokers
- Building event sourcing systems
- Implementing CQRS patterns
- Creating AsyncAPI specifications

**Do NOT invoke when:**
- Building synchronous REST APIs (use api-designer)
- Setting up Kafka infrastructure (use data-engineer)
- Building workflow orchestration (use workflow-orchestrator)
- Designing GraphQL APIs (use graphql-architect)

## Decision Framework
```
Message Broker Selection:
├── High throughput, streaming → Kafka
├── Flexible routing → RabbitMQ
├── Cloud-native, serverless → EventBridge, Pub/Sub
├── Simple queuing → SQS, Redis Streams
└── Enterprise integration → Azure Service Bus

Pattern Selection:
├── Audit/replay needed → Event Sourcing
├── Read/write separation → CQRS
├── Simple async → Pub/Sub
├── Guaranteed delivery → Transactional outbox
└── Complex routing → Message router
```

## Core Workflows

### 1. Event-Driven System Design
1. Identify domain events
2. Define event schemas (CloudEvents)
3. Choose message broker
4. Design topic/queue structure
5. Define consumer groups
6. Plan dead letter handling
7. Document with AsyncAPI

### 2. Event Sourcing Implementation
1. Define aggregate boundaries
2. Design event types
3. Implement event store
4. Build projection handlers
5. Create read models
6. Handle schema evolution
7. Plan snapshot strategy

### 3. AsyncAPI Specification
1. Define servers and protocols
2. Describe channels (topics/queues)
3. Define message schemas
4. Document operations (pub/sub)
5. Add security schemes
6. Generate documentation
7. Enable code generation

## Best Practices
- Use CloudEvents format for interoperability
- Design idempotent consumers
- Implement dead letter queues
- Version event schemas carefully
- Monitor consumer lag
- Plan for at-least-once delivery

## Anti-Patterns
| Anti-Pattern | Problem | Correct Approach |
|--------------|---------|------------------|
| Synchronous over async | Defeats purpose | Use proper patterns |
| No idempotency | Duplicate processing | Design idempotent handlers |
| Ignoring order | Data consistency issues | Partition by key if needed |
| Huge events | Network overhead | Small events, fetch details |
| No schema evolution | Breaking changes | Versioning strategy |

Overview

This skill provides expert guidance for designing and implementing event-driven, asynchronous systems using Event-Driven Architecture (EDA). It focuses on practical choices around message brokers, event schemas, event sourcing, CQRS, and documentation with AsyncAPI and CloudEvents. Use it to create scalable, decoupled microservices and resilient event pipelines.

How this skill works

The skill inspects system goals, throughput, ordering and delivery requirements, and operational constraints to recommend brokers, topologies, and patterns. It codifies workflows for event-driven system design, event sourcing implementation, and AsyncAPI specification generation. It also prescribes best practices such as CloudEvents formatting, idempotent consumers, dead-letter handling, and schema versioning.

When to use it

  • Designing an event-driven system or event mesh topology
  • Choosing a message broker (Kafka, RabbitMQ, EventBridge, Pub/Sub, SQS, etc.)
  • Implementing event sourcing or CQRS patterns
  • Creating AsyncAPI specifications and message schemas
  • Building asynchronous microservices with reliable delivery

Best practices

  • Adopt CloudEvents for standardized event envelopes and interoperability
  • Design consumers to be idempotent and resilient to retries
  • Implement dead-letter queues and monitor consumer lag
  • Version event schemas and plan schema evolution strategy
  • Use partitioning or keys to preserve ordering when required
  • Prefer small, expressive events and reference large payloads

Example use cases

  • Designing a high-throughput streaming pipeline: recommend Kafka with partitioning and consumer groups
  • Migrating a monolith to async microservices: define domain events, AsyncAPI, and event routers
  • Implementing event sourcing for auditability: design aggregates, event store, projections, and snapshots
  • Creating cross-cloud integrations: standardize on CloudEvents and an event mesh
  • Building serverless async workflows: choose cloud-native pub/sub and transactional outbox for consistency

FAQ

How do I choose the right broker?

Match requirements: Kafka for high throughput/streaming, RabbitMQ for complex routing, cloud pub/sub for serverless, SQS/Redis Streams for simple queues, and enterprise buses for legacy integration.

When should I use event sourcing over a CRUD model?

Use event sourcing when auditability, replayability, or temporal queries are required; prefer CRUD for simpler domains to avoid added complexity.