/enterprise-software-playbook:resiliencefrom enterprise-software-playbook
Applies fault-tolerance patterns (timeouts, retries with backoff+jitter, circuit breakers, bulkheads, idempotency keys) to outbound calls and async consumers for hardening against partial failures.
Ships in enterprise-software-playbook. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Make I/O failures boring: set explicit timeouts, retry safely, keep operations idempotent, and prevent cascades with circuit breakers and bulkheads.
Enterprise systems fail partially (timeouts, 5xx, queue lag). Resilience patterns make those failures bounded and observable.
Inputs: I/O boundary code (HTTP/gRPC/DB/cache/queue clients); dependency map (what calls what).
Outputs: Hardened code with resilience patterns applied (timeouts, retries, idempotency, breakers, bulkheads); failure model documentation. Consumed by testing and finish.
Identify the I/O boundary: HTTP, gRPC, DB, cache, queue/stream, third-party API.
Define the failure model:
Apply patterns in this order:
GATE: If adding retries, idempotency (pattern 2) MUST be addressed first. Never retry a non-idempotent operation without an idempotency key or server-side dedupe.
Add observability (retry counts, breaker state, queue lag, error codes). Each metric should have a named decision it supports and an owner — see observability.
Add consumer-visible tests for semantics; add a local smoke test for failure modes.
When context or time is constrained, these are the load-bearing steps:
Steps that can be cut under pressure: circuit breaker (step 3.4), bulkheads (step 3.5), detailed observability (step 4).
Backoff with jitter:
export function backoffDelayMs(
attempt: number,
baseMs = 100,
maxMs = 2_000,
): number {
const exp = Math.min(maxMs, baseMs * 2 ** attempt);
const jitter = 0.5 + Math.random(); // [0.5, 1.5)
return Math.round(exp * jitter);
}
references/checklists.mdreferences/snippets/typescript.mdCircuit Breaker, Idempotent Consumer, Transactional outboxobservabilitytypescriptdesign (Proxy/Decorator — see structural pattern references)When applying this skill, return:
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub bricerising/enterprise-software-playbook --plugin enterprise-software-playbook17 skills in this plugin
/architectureDesign or refactor multi-service system architecture (domain boundaries, service decomposition, event-driven vs request/response, CQRS, sagas, API gateways, data ownership). Use when work spans multiple processes/services, needs eventual consistency, or requires clearer integration seams. NOT for in-process code structure like GoF patterns (use design); NOT for applying timeouts/retries/breakers to a single call (use resilience)./archobsRun architecture observability analysis on a git repository to measure coupling, boundary health, risk hotspots, and temporal drift. Use when you need empirical data about code structure before making architecture or refactoring decisions, or to validate that changes improved boundary discipline. NOT for choosing architecture patterns (use architecture); NOT for choosing code patterns (use design); NOT for adversarial code review (use review); NOT for trajectory prediction or trend forecasting from cluster activity (use forecast)./debugTriage and diagnose production or local issues by following logs → traces → metrics (HTTP/gRPC/async). Use when investigating errors, latency spikes, 5xx responses, SLO violations, or regressions in an instrumented app. NOT for adding new instrumentation (use observability); NOT for applying resilience patterns (use resilience)./designPick the right in-process code pattern for a refactoring or extensibility need (GoF creational/structural/behavioral), and access implementation guides for specific patterns. Use as a decision workflow when unsure which pattern family fits, or go directly to pattern references when you already know. NOT for multi-service/distributed architecture (use architecture)./finishRun a final "definition of done" check before shipping: verify correctness, tighten contracts/docs, and produce a change summary. Use at the end of non-trivial work to confirm nothing was missed before merge/release. NOT for writing tests (use testing); NOT for adversarial code review (use review); NOT for initial planning (use plan)./forecastPredict likely next developments from internal development patterns (git history, archobs clusters) and external signals (intel feeds). Use when you need forward-looking intelligence — what's GOING to happen, not what already happened. NOT for gathering raw signals (use intel); NOT for static code-structure analysis (coupling, boundary health, risk scores — use archobs); NOT for implementation planning (use plan).