-
Notifications
You must be signed in to change notification settings - Fork 37
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 RegisterAll
API to enable monitoring collections of key-values for refresh
#574
base: preview
Are you sure you want to change the base?
Conversation
…otnetProvider into ajusupovic/collection-monitoring
…otnetProvider into ajusupovic/collection-monitoring
…otnetProvider into ajusupovic/collection-monitoring
…, separate selectors, add new methods to support new logic
…/Azure/AppConfiguration-DotnetProvider into ajusupovic/collection-monitoring
…otnetProvider into ajusupovic/collection-monitoring
{ | ||
internal class ConfigurationSettingPageableManager | ||
{ | ||
public virtual IAsyncEnumerable<Page<ConfigurationSetting>> GetPages(AsyncPageable<ConfigurationSetting> pageable, IEnumerable<MatchConditions> matchConditions) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are these methods virtual?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, I didn't document this anywhere so good callout. The approach recommended by the SDK team for testing the AsPages
extension with MatchConditions
as seen here was to create a virtual method that we could override in the tests using the MockConfigurationSettingPageableManager
class. Because Moq
doesn't let you mock extension methods, this was the only approach that we came up with. Any details I missed are probably in the issue I linked in the PR description.
…otnetProvider into ajusupovic/collection-monitoring
This PR adds the new
RegisterAll
API to monitor any key-values added withAzureAppConfigurationOptions.Select
for refresh as a collection, but it will also begin monitoring feature flags as a collection instead of on an individual basis. Consequently, feature flag changes will no longer be logged on an individual basis. This solves an existing issue.