Resilient
|
A policy describes how to execute a task. More...
Classes | |
class | resilient::Circuitbreaker |
Fail-fast when tasks are consistently failing. More... | |
class | resilient::Noop |
A Policy which simply invokes the task. More... | |
class | resilient::Pipeline< Policies > |
Define a sequence of polices, which will be executed in order. More... | |
class | resilient::Ratelimiter< Strategy > |
Execute a Task limiting the times it can be executed following a strategy. More... | |
class | resilient::retry::Retry< RetryStateFactory > |
Reduce the impact of tasks failing due to transient failures. More... | |
A policy describes how to execute a task.
When executing a task there are several ways to cope with failure. An application might require to try to execute the task again, another one might need to stop when running them too many times.
A policy specifies the rules of executing a task.
A class to qualify for the Policy
concept needs to define a execute()
method. The method need to take a callable object (which implements the Task
concept) and the arguments to invoke the callable with. It needs to return a Failable.