skills/event-driven-architecture-expert/SKILL.md
Message queues, pub/sub, event sourcing with Kafka, RabbitMQ, Redis Streams. Activate on: event-driven, message queue, pub/sub, Kafka, RabbitMQ, event bus, async messaging, dead letter queue. NOT for: CQRS projections (use cqrs-event-sourcing-architect), real-time WebSocket (use websocket-realtime-expert), observability (use observability-apm-expert).
npx skillsauth add curiositech/windags-skills event-driven-architecture-expertInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Design and implement resilient message-driven systems using Kafka, RabbitMQ, Redis Streams, and cloud-native event buses.
Activate on: "event-driven", "message queue", "pub/sub", "Kafka", "RabbitMQ", "event bus", "async messaging", "dead letter queue", "event broker", "fan-out", "Redis Streams"
NOT for: CQRS projections/event stores → cqrs-event-sourcing-architect | WebSocket real-time → websocket-realtime-expert | Distributed tracing → observability-apm-expert
| Domain | Technologies | |--------|-------------| | Message Brokers | Apache Kafka 3.8+, RabbitMQ 4.x, Redis Streams 7.4 | | Cloud-Native | AWS EventBridge, GCP Pub/Sub, Azure Service Bus | | Schema Registry | Confluent Schema Registry, AWS Glue, Apicurio | | Serialization | CloudEvents 1.0, Avro, Protobuf, JSON Schema | | Frameworks | KafkaJS, amqplib, BullMQ 5.x, Temporal |
Producer → Topic/Exchange
├─→ Consumer A (order-service)
├─→ Consumer B (notification-service)
└─→ Consumer C (analytics-service)
↓ (failure after 3 retries)
Dead Letter Queue → Alert + Manual Review
Avoid dual-write problems by writing events to an outbox table within the same DB transaction, then polling/CDC to publish:
┌─────────────────────────────┐
│ BEGIN TRANSACTION │
│ INSERT INTO orders (...) │
│ INSERT INTO outbox ( │
│ event_type, payload, │
│ published_at = NULL │
│ ) │
│ COMMIT │
└─────────────────────────────┘
↓ (CDC / Poller)
Kafka / RabbitMQ Topic
// KafkaJS consumer group — 3 partitions, 3 consumers
const kafka = new Kafka({ brokers: ['broker:9092'] });
const consumer = kafka.consumer({ groupId: 'order-processors' });
await consumer.subscribe({ topic: 'orders', fromBeginning: false });
await consumer.run({
partitionsConsumedConcurrently: 3,
eachMessage: async ({ topic, partition, message }) => {
const event = JSON.parse(message.value.toString());
await processIdempotent(event, message.headers['idempotency-key']);
},
});
type, source, id, timetools
Building resilient distributed systems with circuit breakers, retries with full-jitter exponential backoff, retry budgets (per-request 3-attempt + per-client 10% ratio per Google SRE), deadline propagation, and the cascading-failure math (4 layers × 3 retries = 64x amplification). Grounded in Resilience4j, Microsoft Cloud Patterns, AWS Architecture Blog (Marc Brooker), and Google SRE Book.
testing
Designing HTTP cache headers that work correctly across browsers, CDNs, and shared proxies — `Cache-Control` directives per RFC 9111, `stale-while-revalidate` and `stale-if-error` per RFC 5861, the Vary header for varying responses, and surrogate keys for tag-based purging. Grounded in IETF RFCs and Cloudflare/Fastly docs.
development
Use when designing or fixing a Content Security Policy on a real site, choosing between nonce-based and hash-based CSP, adding strict-dynamic, debugging "Refused to execute inline script" errors, deploying CSP in report-only mode first, configuring report-to / report-uri, or auditing an existing policy for unsafe-inline / unsafe-eval / wildcards. Triggers: "CSP blocks legitimate inline script", strict-dynamic, nonce-{RANDOM}, sha256-{HASH}, object-src none, base-uri none, frame-ancestors, Trusted Types, X-Content-Security-Policy obsolete, report-only vs enforced. NOT for general HTTP security headers (HSTS, COOP/COEP), Trusted Types deep dive, CORS configuration, or building a WAF.
tools
Choosing and operating an HTTP API versioning strategy that doesn't break clients — Stripe's date-based pinned versions, the Deprecation/Sunset header pair (RFC 9745 + RFC 8594), URI vs header vs media-type approaches, and the version-transformer pattern. Grounded in Stripe's published architecture and IETF RFCs.