workflow-orchestration-patterns
Projetar fluxos de trabalho duráveis do Temporal
Transações distribuídas falham sem orquestração clara. Esta habilidade fornece padrões do Temporal para fluxos de trabalho determinísticos, retentativas e ações de compensação.
Télécharger le ZIP du skill
Importer dans Claude
Allez dans Paramètres → Capacités → Skills → Importer un skill
Activez et commencez à utiliser
Tester
Utilisation de "workflow-orchestration-patterns". Outline a Temporal saga for booking travel with rollback steps.
Résultat attendu:
- Register compensations before each step
- Reserve flight, compensate by canceling reservation
- Book hotel, compensate by canceling booking
- Charge payment, compensate by refunding payment
- On failure, run compensations in reverse order (LIFO)
Utilisation de "workflow-orchestration-patterns". When should I use a child workflow versus parallel activities?
Résultat attendu:
- Use child workflows for complex, reusable process segments
- Use parallel activities for simple independent tasks
- Child workflows have their own execution history and timeouts
- Activities share parent workflow history and run faster
Utilisation de "workflow-orchestration-patterns". How do I handle long-running activities that might stall?
Résultat attendu:
- Implement heartbeat within activity to report progress
- Set heartbeat timeout to detect stalled work
- Use heartbeat details to enable progress-based retry
- Break long tasks into smaller idempotent steps
Audit de sécurité
SûrPure documentation skill containing only markdown guidance about Temporal workflow patterns. No executable code, scripts, or network activity. All 43 static findings are false positives triggered by documentation metadata and code block syntax - specifically git hash identifiers flagged as weak crypto, markdown backticks flagged as shell execution, and normal error classification flagged as reconnaissance.
Facteurs de risque
🌐 Accès réseau (1)
Score de qualité
Ce que vous pouvez construire
Design payment orchestration
Plan a multi-step payment workflow with compensations, retries, and idempotent activities.
Model long-lived entities
Choose entity workflows for accounts or carts with signals and queryable state.
Harden failure recovery
Define retry limits, backoff, and heartbeat policies for critical activities.
Essayez ces prompts
Classify each step of my order process as workflow or activity and explain why.
Draft a saga plan for reserve inventory, charge payment, and ship order with compensations and idempotency rules.
Propose a fan-out and fan-in design for 500,000 tasks using child workflows and bounded workflow size.
Recommend a versioning approach for a long-running workflow update with backward compatibility constraints.
Bonnes pratiques
- Keep workflows deterministic and move all I/O to activities
- Make activities idempotent, short-lived, and always configure timeouts
- Use child workflows to scale large parallel workloads
Éviter
- Calling external APIs directly from workflows
- Using system time or random functions in workflows
- Skipping compensation registration before executing a step