-
Notifications
You must be signed in to change notification settings - Fork 38
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
Add IConfigurationRefresher.TryRefresh API #113
Comments
@zhenlan I'm surprised that we don't want to throw on 401 and 403. Those aren't transient and will never recover during the life time of the application. I can understand a user not wanting I would suggest that TryRefresh still throws UnauthorizedAccessException in the case of 403 or 401. |
@jimmyca15 |
What I mean by transient is that the error can go away without any action by the user other than retrying. I see arguments for both ways and am fine with either, after all it is based off what the scenario is that we expect users to call |
From API prospective it's not transient, but from use case it could be. I think we are looking on scenario based definition here. App doesn't need to crash on refresh. |
Okay, I agree with that then. If the API intention is a no-crash refresh then it makes sense. |
We may need to look at logging in such case, though. |
Closing this issue since the proposed APIs The addition of logging to |
To make it easier for customers to trigger configuration refresh without worrying about crashing the app due to various transient errors, propose to add the API below in
IConfigurationRefresher
.Details
The
TryRefresh
will not throw on Transient or any FailedRequestException, regardless of the status code (even 401, 403)The existing API
Refresh
will not catch anything.More discussion
Propose to follow the convention and rename APIs to
The text was updated successfully, but these errors were encountered: