resilience

Enforce retry, timeout, and circuit breaker patterns in workflows.

3|1|Updated Jan 4, 2026
One-click install
npx skills add https://github.com/jagreehal/jagreehal-claude-skills --skill resilience
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: resilience
Source: https://github.com/jagreehal/jagreehal-claude-skills/tree/main/skills/resilience
Command: npx skills add https://github.com/jagreehal/jagreehal-claude-skills --skill resilience

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Resilience patterns for workflows keep business logic clean by moving retry, timeout, and circuit-breaker behavior out of functions and into the workflow engine.

Core Features & Use Cases

  • Retry at the workflow level to handle transient failures without duplicating logic in business functions.
  • Timeout control for each operation with configurable backoff and jitter to prevent cascading failures.
  • Circuit-breaker guidance to avoid hammering flaky services and to fail fast when dependencies are down.
  • Idempotence guidance to ensure multi-step operations can be retried safely.

Quick Start

Install and integrate the resilience patterns by wiring step.retry and step.withTimeout into your workflow, then run a sample workflow to observe retries and timeouts in action.

Frequently Asked Questions about resilience

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I handle transient failures in TypeScript workflows without duplicating retry logic?

To handle transient failures in TypeScript workflows without duplicating logic, enforce retry patterns at the workflow level using step.retry capabilities. This moves retry behavior out of business functions and into the workflow engine to keep logic clean.

What is a circuit breaker pattern in workflow resilience and when should I use it?

A circuit breaker in workflow resilience prevents hammering flaky services and fails fast when dependencies are down. Use it to avoid cascading failures in multi-step operations when external systems become unresponsive or unreliable.

How do I configure timeouts and backoff for workflow operations in TypeScript?

Configure timeouts for workflow operations by wiring step.withTimeout into your workflow steps. This enforces timeout control for each operation with configurable backoff and jitter to prevent cascading failures when external dependencies experience delays.

Why do I need idempotence guidance for retrying workflow steps?

Idempotence guidance ensures multi-step operations can be retried safely. When retrying transient errors in workflows, idempotent operations guarantee that re-executing a step does not produce duplicate side effects in external dependent systems.

Do I need the @jagreehal/workflow library to implement resilience patterns?

Yes, implementing these workflow resilience patterns relies on the @jagreehal/workflow library. It provides the necessary workflow engine capabilities to wire step.retry and step.withTimeout into your business logic safely.

What are the limitations of moving circuit breaker behavior into workflow engines?

Moving circuit breaker behavior into workflow engines limits your ability to handle failures directly inside individual functions. This approach targets workflow-level business logic and requires dependent external systems to support idempotent operations for safe retries.