Class AppConfigAgentConfigurationProvider
- Namespace
- SEBT.Portal.Infrastructure.Configuration
- Assembly
- SEBT.Portal.Infrastructure.dll
Configuration provider that reads feature flags from AWS AppConfig Agent. Uses the agent's HTTP API instead of direct AWS SDK calls
public sealed class AppConfigAgentConfigurationProvider : ConfigurationProvider
- Inheritance
-
objectConfigurationProviderAppConfigAgentConfigurationProvider
Constructors
AppConfigAgentConfigurationProvider(HttpClient, AppConfigAgentProfile, ILogger<AppConfigAgentConfigurationProvider>?, bool)
public AppConfigAgentConfigurationProvider(HttpClient httpClient, AppConfigAgentProfile profile, ILogger<AppConfigAgentConfigurationProvider>? logger = null, bool ownsHttpClient = false)
Parameters
httpClientHttpClientprofileAppConfigAgentProfileloggerILogger<AppConfigAgentConfigurationProvider>ownsHttpClientbool
Methods
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public void Dispose()
Load()
Loads (or reloads) the data for this provider.
public override void Load()
ReloadAsync(CancellationToken)
Re-fetches configuration from the AppConfig Agent. Called by the reload background service on its polling interval. Only raises a change notification when the configuration actually changed.
public Task<bool> ReloadAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationToken
Returns
- Task<bool>
trueif the configuration changed since the last load; otherwisefalse.
ToString()
Generates a string representing this provider name and relevant details.
public override string ToString()
Returns
- string
The configuration name.