Skip to content
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

Clean up auth schemes/signers that are no longer needed #4368

Conversation

sugmanue
Copy link
Contributor

Motivation and Context

Clean up auth schemes/signers that are no longer needed. After the consolidation of all the signing logic into single classes we can remove all the special auth schemes and implementations that are not longer needed.

Modifications

Testing

Screenshots (if appropriate)

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Checklist

  • I have read the CONTRIBUTING document
  • Local run of mvn install succeeds
  • My code follows the code style of this project
  • My change requires a change to the Javadoc documentation
  • I have updated the Javadoc documentation accordingly
  • I have added tests to cover my changes
  • All new and existing tests passed
  • I have added a changelog entry. Adding a new entry must be accomplished by running the scripts/new-change script and following the instructions. Commit the new file created by the script in .changes/next-release with your changes.
  • My change is to implement 1.11 parity feature and I have updated LaunchChangelog

License

  • I confirm that this pull request can be released under the Apache 2 license

@sugmanue sugmanue force-pushed the sugmanue/sra-ia-cleanup-sigv4a-interfaces branch from a567c29 to a66c049 Compare August 29, 2023 20:40
@@ -38,11 +37,7 @@ private SignerLoader() {
}

public static AwsV4aHttpSigner getSigV4aSigner() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit, because it is SdkInternalApi, but could keep the method name close to the return type - getAwsV4aHttpSIgner()

@@ -29,20 +28,16 @@
/**
* Utility class for instantiating signers only if they're available on the class path.
*/
@SdkInternalApi
@SdkProtectedApi
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The SignerLoader itself is not used cross-module; used only by AwsV4aHttpSigner. This should remain SdkInternalApi.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, I moved it to protected to mirror the existing one, but we can relax this once and if needed. I will move it back to internal.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fyi, the existing one is SdkProtectedApi, because it is used by generated {Service}EndpointAuthSchemeInterceptor.

@@ -44,9 +44,16 @@
* An implementation of a {@link AwsV4aHttpSigner} that uses properties to compose v4a-signers in order to delegate signing of a
* request and payload (if applicable) accordingly.
*/
@SdkInternalApi
@SdkProtectedApi
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry, one more point. I think this should now be moved to software.amazon.awssdk.http.auth.aws.crt instead of under internal

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pushed a new commit to move the class and test.

@sonarcloud
Copy link

sonarcloud bot commented Aug 30, 2023

SonarCloud Quality Gate failed.    Quality Gate failed

Bug C 2 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 320 Code Smells

0.0% 0.0% Coverage
2.4% 2.4% Duplication

idea Catch issues before they fail your Quality Gate with our IDE extension sonarlint SonarLint

@sugmanue sugmanue merged commit e5d7809 into feature/master/sra-identity-auth Aug 30, 2023
12 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants