Travix-International / Hystrix.Dotnet

A combination of circuit breaker and timeout. The .net version of the open source Hystrix library built by Netflix.
https://travix-international.github.io/Hystrix.Dotnet/
MIT License
95 stars 16 forks source link

Execute method does not pass exception as a parameter in Fallback method #27

Open vnadar opened 6 years ago

vnadar commented 6 years ago

Currently IHystrixCommand has Execute method with two overloads, but both does not provide exception parameter in fallback method. InnerException is valuable in case any exception occurred during execution, then in fallback we can log and throw an exception based on that.

Below are the two overloads. T Execute(Func primaryFunction, CancellationTokenSource cancellationTokenSource = null); T Execute(Func primaryFunction, Func fallbackFunction, CancellationTokenSource cancellationTokenSource = null)