Declare side effects and idempotency
Stub
This How-to is a stub. Side-effect classes exist in design, but enforcement patterns are still being stabilized in the stack.
Goal
You will declare a node’s side-effect class and idempotency posture so retries are safe and policy can reason about risk.
When to use this
- You are authoring a node that can mutate external state (write/irreversible).
- You need safe retry semantics for durable execution.
Prerequisites
- A
NodeTypemetadata model that includes side-effect class and idempotency hints - A policy/checkpoint strategy for “pre-irreversible action”
Steps
- Classify the node as
read,write, orirreversible. - Define an idempotency key strategy (request-level / resource-level).
- Ensure retries are safe (or explicitly disallowed) and observable in artifacts.
Verify
- Retries do not duplicate side effects.
- Policy can deny irreversible actions unless explicitly allowed.
Troubleshooting
- “Duplicate write” incidents → idempotency is missing → require idempotency keys and enforce them in the handler.
- Policy denies unexpectedly → you marked a node as
write/irreversible→ update policy profile or node classification. - Ambiguous side effects → split a node into smaller capabilities with clearer semantics.
Cleanup / Rollback
- Deprecate a risky node version and roll back to a safe version.
Next steps
- Concept: Policy checkpoints
- Reference: ARP Standard: PDP
- How-to: Configure PDP checkpoints