-
Notifications
You must be signed in to change notification settings - Fork 50
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
fix: profile credentials provider needing opt in to internal annotation #1215
Conversation
A new generated diff is ready to view.
|
/** | ||
* Specifies the active profile and configured (may not actually exist) locations of configuration files. | ||
*/ | ||
@InternalSdkApi | ||
public data class AwsConfigurationSource(val profile: String, val configPath: String, val credentialsPath: String) |
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.
Correctness: I believe we still want this type to be @InternalSdkApi
. I think instead we should add to ProfileCredentialsProvider
a new constructor overload that doesn't have an AwsConfigurationSource
parameter. Then we can mark the current constructor as @InternalSdkApi
.
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.
What about if the user wants to configure the AwsConfigurationSource
?
A new generated diff is ready to view.
|
Quality Gate passedIssues Measures |
A new generated diff is ready to view.
|
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.
Looks good just one question on whether we verified the behavior change.
public val profileName: String? = null, | ||
public val region: String? = null, | ||
public val platformProvider: PlatformProvider = PlatformProvider.System, | ||
public val httpClient: HttpClientEngine? = null, | ||
public val configurationSource: AwsConfigurationSource? = null, | ||
) : CloseableCredentialsProvider { | ||
|
||
public constructor( |
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.
question: Have you tried this out by publishing it to maven local and trying to use it in a project? I tested the issue originally to verify and could see intellij correctly flagged it, we should verify this actually fixes the issue for customers by comparing before and after if you haven't already.
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.
Yes, I published it to maven local and gave it a try.
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.
I could see the warning go away and there was no longer a need to import aws.smithy.kotlin:http-client
Changes requested were made and received two approvals from rest of team.
Issue #
closes #1208
Description of changes
One of the constructor parameters was marked as internal SDK API. Which was causing the profile credentials provider to be marked as internal API.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.