diff --git a/.autover/changes/388041c1-4920-4e10-994a-a71a83e09f54.json b/.autover/changes/388041c1-4920-4e10-994a-a71a83e09f54.json new file mode 100644 index 0000000..5c7b1fa --- /dev/null +++ b/.autover/changes/388041c1-4920-4e10-994a-a71a83e09f54.json @@ -0,0 +1,13 @@ +{ + "Projects": [ + { + "Name": "Amazon.Extensions.Configuration.SystemsManager", + "Type": "Major", + "ChangelogMessages": [ + "Updated the .NET SDK dependencies to the latest version 4.0.0-preview.4", + "Marked project as trimmable", + "Added SourceLink support" + ] + } + ] +} \ No newline at end of file diff --git a/src/Amazon.Extensions.Configuration.SystemsManager/Amazon.Extensions.Configuration.SystemsManager.csproj b/src/Amazon.Extensions.Configuration.SystemsManager/Amazon.Extensions.Configuration.SystemsManager.csproj index d1d55c6..cf82610 100644 --- a/src/Amazon.Extensions.Configuration.SystemsManager/Amazon.Extensions.Configuration.SystemsManager.csproj +++ b/src/Amazon.Extensions.Configuration.SystemsManager/Amazon.Extensions.Configuration.SystemsManager.csproj @@ -6,15 +6,13 @@ Amazon.Extensions.Configuration.SystemsManager Amazon.Extensions.Configuration.SystemsManager Library - 6.2.2 true Amazon.Extensions.Configuration.SystemsManager .NET Configuration Extensions for AWS Systems Manager Amazon.Extensions.Configuration.SystemsManager .NET Configuration Extensions for AWS Systems Manager Amazon Web Services - 2018-2024 - AWS;Amazon;aws-sdk-v3;SimpleSystemsManagement;configuration + AWS;Amazon;aws-sdk-v4;SimpleSystemsManagement;configuration https://github.com/aws/aws-dotnet-extensions-configuration/ LICENSE icon.png @@ -22,6 +20,17 @@ Amazon Web Services true ../ruleset.xml + + true + true + true + snupkg + + 7.0.0-preview.1 + + + + true @@ -35,11 +44,12 @@ - - - + + + + diff --git a/src/Amazon.Extensions.Configuration.SystemsManager/AppConfig/AppConfigProcessor.cs b/src/Amazon.Extensions.Configuration.SystemsManager/AppConfig/AppConfigProcessor.cs index e3acf2c..094fde8 100644 --- a/src/Amazon.Extensions.Configuration.SystemsManager/AppConfig/AppConfigProcessor.cs +++ b/src/Amazon.Extensions.Configuration.SystemsManager/AppConfig/AppConfigProcessor.cs @@ -84,11 +84,13 @@ public async Task> GetDataAsync() if(_appConfigDataClient != null) { - return await GetDataFromServiceAsync().ConfigureAwait(false); + return await GetDataFromServiceAsync().ConfigureAwait(false) + ?? new Dictionary(); } else { - return await GetDataFromLambdaExtensionAsync().ConfigureAwait(false); + return await GetDataFromLambdaExtensionAsync().ConfigureAwait(false) + ?? new Dictionary(); } } @@ -126,7 +128,7 @@ private async Task> GetDataFromServiceAsync() var response = await _appConfigDataClient.GetLatestConfigurationAsync(request).ConfigureAwait(false); PollConfigurationToken = response.NextPollConfigurationToken; - NextAllowedPollTime = DateTime.UtcNow.AddSeconds(response.NextPollIntervalInSeconds); + NextAllowedPollTime = DateTime.UtcNow.AddSeconds(response.NextPollIntervalInSeconds ?? 0); // Configuration is empty when the last received config is the latest // so only attempt to parse the AppConfig response when it is not empty diff --git a/src/Amazon.Extensions.Configuration.SystemsManager/Internal/SystemsManagerProcessor.cs b/src/Amazon.Extensions.Configuration.SystemsManager/Internal/SystemsManagerProcessor.cs index c569234..d03f703 100644 --- a/src/Amazon.Extensions.Configuration.SystemsManager/Internal/SystemsManagerProcessor.cs +++ b/src/Amazon.Extensions.Configuration.SystemsManager/Internal/SystemsManagerProcessor.cs @@ -63,7 +63,7 @@ private async Task> GetParametersByPathAsync() { var response = await client.GetParametersByPathAsync(new GetParametersByPathRequest { Path = Source.Path, Recursive = true, WithDecryption = true, NextToken = nextToken, ParameterFilters = Source.Filters }).ConfigureAwait(false); nextToken = response.NextToken; - parameters.AddRange(response.Parameters); + parameters.AddRange(response.Parameters ?? new List()); } while (!string.IsNullOrEmpty(nextToken)); return AddPrefix(Source.ParameterProcessor.ProcessParameters(parameters, Source.Path), Source.Prefix); diff --git a/test/Amazon.Extensions.Configuration.SystemsManager.Integ/Amazon.Extensions.Configuration.SystemsManager.Integ.csproj b/test/Amazon.Extensions.Configuration.SystemsManager.Integ/Amazon.Extensions.Configuration.SystemsManager.Integ.csproj index 72d0664..c2c3acb 100644 --- a/test/Amazon.Extensions.Configuration.SystemsManager.Integ/Amazon.Extensions.Configuration.SystemsManager.Integ.csproj +++ b/test/Amazon.Extensions.Configuration.SystemsManager.Integ/Amazon.Extensions.Configuration.SystemsManager.Integ.csproj @@ -7,9 +7,9 @@ - + - + all