Upgrade AWS SDK for Go from V1 to V2 #78
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
This Pull Request aims to upgrade the version of the AWS SDK for Go from V1 to V2.
Changes
Main changes from V1 to V2
<OperationName>WithContext
method for calling APIs has been renamed to just<OperationName>
types
package for each serviceaws.StringValue()
has been changed toaws.ToString()
Changes Made with Uncertainty
session.NewSessionWithOptions()
withconfig.LoadDefaultConfig()
maintains equivalent behavior to the original. ( However, as far as I have confirmed, it seems to work the same way, so there may not be a problem.)~/.aws/*
) by specifyingsession.SharedConfigEnable
.config.LoadDefaultConfig()
reads the shared config, so I have replaced it with this function.Testing
The following has been tested
apply
,dump
,run
, anddiff
can be executed.Behavior Incompatibility
dump
now always includes thepropagateTag
when retrieving remote Rule information.propagateTag: ""
will be output as a diff ifpropagateTag
is not explicitly specified in config.yaml.apply
ordiff
.