Pudu programming language
Menu
Package

@chrismichaelps / pudu-lang-resilience

Resilience pipelines for Pudu: retry, circuit breaker, timeout, fallback, hedging, rate limiting, and chaos injection

0.1.0Apache-2.01

InstallClose

ADR-0001-outcomes-not-exceptions.md

Markdown32 lines843 B

GitHub ↗

ADR-0001 — Every result is an outcome value


type: adr status: Accepted tags: [adr]


Context

Pudu reports failures as values. A resilience layer must add its own rejections (timeouts, open circuits, rate limits) to whatever the callback can fail with.

Decision

Callbacks and strategies answer Outcome[T, E] = Result[T, Failure[E]]. Failure wraps the callback's error as Raised(E) beside the package's own variants. Callbacks that answer a plain Result run through Pipeline.run, which lifts their errors.

Consequences

  • Every rejection is matched exhaustively by the caller.
  • Predicates decide on values and failures alike.

Rejected

  • A trait object of errors: loses exhaustive matching and needs casts.

Referenced by

[[CHANGELOG]] · [[decisions/_MOC]] · [[handoffs/2026-09-28-initial-package]]