| name | distributed-systems |
| license | MIT |
| compatibility | Claude Code 2.1.220+. |
| description | Distributed systems patterns for locking, resilience, idempotency, and rate limiting. Use when implementing distributed locks, circuit breakers, retry policies, idempotency keys, token bucket rate limiters, or fault tolerance patterns. |
| tags | ["distributed-systems","distributed-locks","resilience","circuit-breaker","idempotency","rate-limiting","retry","fault-tolerance","edge-computing","cloudflare-workers","vercel-edge","event-sourcing","cqrs","saga","outbox","message-queue","kafka"] |
| context | fork |
| agent | backend-system-architect |
| version | 2.0.0 |
| author | OrchestKit |
| user-invocable | false |
| disable-model-invocation | true |
| complexity | medium |
| persuasion-type | reference |
| metadata | {"category":"document-asset-creation"} |
| allowed-tools | ["Read","Glob","Grep","WebFetch","WebSearch"] |
Distributed Systems Patterns
Comprehensive patterns for building reliable distributed systems. Each category has individual rule files in rules/ loaded on-demand.
Quick Reference
| Category | Rules | Impact | When to Use |
|---|
| Distributed Locks | 1 | CRITICAL | Fencing tokens, owner validation; Redis/Redlock and Postgres advisory via upstream docs |
| Resilience | 3 | CRITICAL | Circuit breakers, retry with backoff, bulkhead isolation |
| Idempotency | 1 | HIGH | Idempotency keys; dedup and database-backed storage via upstream docs |
| Rate Limiting | 2 | HIGH | Token bucket, sliding window; SlowAPI integration via upstream docs |
| Edge Computing | 2 | HIGH | Edge workers, V8 isolates, CDN caching, geo-routing |
| Event-Driven | 2 | HIGH | Event sourcing, CQRS, transactional outbox, sagas |
Total: 11 rules across 6 categories. Removed topics point at first-party sources in Upstream coverage; ork-specific scars live in ${CLAUDE_PLUGIN_ROOT}/skills/distributed-systems/references/ork-delta.md.
Quick Start
async with RedisLock(redis_client, "payment:order-123"):
await process_payment(order_id)
@circuit_breaker(failure_threshold=5, recovery_timeout=30)
@retry(max_attempts=3, base_delay=1.0)
async def ():
...
():
idempotent_execute(db, idempotency_key, , process)
limiter = TokenBucketLimiter(redis_client, capacity=, refill_rate=)
limiter.is_allowed():
handle_request()