Skip to content

v0.2.0

Choose a tag to compare

@rasuvaeff rasuvaeff released this 10 Oct 11:21
· 6 commits to master since this release
807284d
  • Pipeline::onRejected(\Closure(\Throwable): \Throwable): map a rejection (CircuitOpenException, BulkheadFullException, the breaker's StorageFailure) to a domain exception once per pipeline; runs outermost, before fallback; other exceptions pass through untouched (#3).
  • CompiledPipeline::call() is generic (@template T): Psalm infers the result type from the callback, no @var at call sites (#3).
  • Pipeline::bulkhead() accepts any Rasuvaeff\Bulkhead\Bulkhead and Pipeline::circuitBreaker() any Rasuvaeff\CircuitBreaker\CircuitBreakerInterface, so decorators and test stubs can replace the leaves (#4).
  • New Rejection::is() / Rejection::retryAfter(): tell "rejected without an attempt" from a downstream failure and get a relative retry hint; RetryExhausted is never a rejection (#5).
  • Requires rasuvaeff/retry ^1.3, rasuvaeff/circuit-breaker ^1.3, rasuvaeff/bulkhead ^1.3, and psr/clock ^1.0.