Retry boundary for retrying operations.
Required callback:
with_retry/2- Execute a function with retry semantics
Optional callbacks for HTTP-specific features:
should_retry?/1- Determine if a response should be retriedparse_retry_after/1- Extract retry delay from response headers
Summary
Callbacks
Build a backoff policy struct from keyword options.
Build a retry policy struct from keyword options.
Parse retry delay from HTTP response headers. Returns delay in milliseconds, or nil if not available.
Determine if an HTTP response should be retried based on status code and headers.
Callbacks
Build a backoff policy struct from keyword options.
Build a retry policy struct from keyword options.
@callback parse_retry_after(map()) :: non_neg_integer() | nil
Parse retry delay from HTTP response headers. Returns delay in milliseconds, or nil if not available.
Determine if an HTTP response should be retried based on status code and headers.