-
Notifications
You must be signed in to change notification settings - Fork 80
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
feat: IAM auth token generator for RDS #1851
Conversation
… module instead of AWSClientRuntime module.
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.
Misc. informational comments
@@ -0,0 +1,100 @@ | |||
// |
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.
This is the handwritten code for token generator, located in AWSClientRuntime
@@ -0,0 +1,63 @@ | |||
// |
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.
This is the generated token generator located in AWSRDS that wraps AWSClientRuntime.AuthTokenGenerator; it's included in the PR as reference for reviewers on what generated output looks like.
@@ -0,0 +1,84 @@ | |||
/* |
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.
This is the new codegen integration that writes a new file with wrapper token generator if service is RDS.
@@ -26,3 +26,4 @@ software.amazon.smithy.aws.swift.codegen.AWSClientConfigurationIntegration | |||
software.amazon.smithy.swift.codegen.swiftintegrations.InitialRequestIntegration | |||
software.amazon.smithy.aws.swift.codegen.swiftintegrations.RegistryConfigIntegration | |||
software.amazon.smithy.aws.swift.codegen.swiftintegrations.AmzSdkRetryHeadersIntegration | |||
software.amazon.smithy.aws.swift.codegen.customization.rds.AuthTokenGeneratorIntegration |
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.
Makes the new integration run during codegen
Issue #
Description of changes
Changes:
AWSClientRuntime.AuthTokenGenerator
. It's tagged with@_spi
to hide it and re-expose through AWSRDS module.AWSRDS.AuthTokenGenerator
, which is a wrapper class forAWSClientRutime.AuthTokenGenerator
(this is done to expose token generator via RDS module, as outlined by specifications)Tested using a dummy AWS RDS MySQL database and confirmed it works.
New/existing dependencies impact assessment, if applicable
Conventional Commits
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.