Currently, all the monkeys are cancellable, which is fine, but we want to allow the user to make the latency monkey no cancellable for those scenarios where even if a token is signaled, they don't want to cancel the latency.
Proposal: add a new property to LatencyOptions/AyncLatencyOptions like this:
internal Func<Context, CancellationToken, Task<bool>> IsCancellable { get; set; }
Might be true by default, then validate it before to honor the token.
Currently, all the monkeys are cancellable, which is fine, but we want to allow the user to make the latency monkey no cancellable for those scenarios where even if a token is signaled, they don't want to cancel the latency.
Proposal: add a new property to
LatencyOptions/AyncLatencyOptionslike this:Might be true by default, then validate it before to honor the token.