rezilience
rezilience copied to clipboard
Metrics for Retry policy
Periodically emit retry metrics from Retry for monitoring and alerting purposes
- Add parameter
metricsCollector: Retry.Metrics => UIO[Unit]
toRetry.make
- Add
metricsInterval: Duration
to customize the metrics emission interval - Emit metrics before end of use of the policy
- Metrics:
- total number of requests
- total number of attempts
- histogram of the number of attempts
- Metrics objects should be summable (including the histogram) to get the total metrics in some period, like in the zio-kinesis Producer