-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pass arbitrary data to Policy execution #1
Comments
I think this is a really good idea and I will look into implementing it. In the meantime, you can probably get information about the call that raised the exception from either the exception itself or the call stack. See How to get the name of the method that caused the exception for more information. |
Great, thanks... |
asherw
pushed a commit
to asherw/Polly
that referenced
this issue
May 4, 2015
…evel Add service level circuit breaker state
joelhulen
pushed a commit
that referenced
this issue
Apr 14, 2016
…dedWindows Merge code which divides the timeslice of the TimesliceCircuitBreaker into internal windows, for smoothing of statistics at timeslice rollver
4 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I have a generic policy, like this:
Now you can see I am writing to a log when the retry operation happens. However, I am using this same policy for many different Execute() functions. I would like to perhaps be able to pass some data, maybe just a string that says what call this is - so when the log is written it can accurately record which operation is retrying.
Is there a way to do this - if not, do you think it is a valuable addition to your library (perhaps as an optional parameter to the Execute() call - and then that parameter passed into the lambdas like timespan/retryattempt/exception is?
The text was updated successfully, but these errors were encountered: