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

Fix the lease coordination table permissions #5097

Merged
merged 2 commits into from
Oct 22, 2024

Conversation

sb2k16
Copy link
Member

@sb2k16 sb2k16 commented Oct 22, 2024

Description

This PR is to fix the credentials required for Lease Coordination table access. The fix is to use the default credentials instead of the pipeline role when Data Prepper would access the dynamoDb table.

Issues Resolved

Resolves #1082

Check List

  • Commits are signed with a real name per the DCO

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Signed-off-by: Souvik Bose <souvbose@amazon.com>
graytaylor0
graytaylor0 previously approved these changes Oct 22, 2024
@@ -65,6 +74,10 @@ public Map<String, String> getStsHeaderOverrides() {
return stsHeaderOverrides;
}

public boolean isUseDefaultCredentials() {
Copy link
Member

Choose a reason for hiding this comment

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

We already have a concept of default in the plugin configuration. So using "default" here is rather confusing.

@JsonProperty("default")
private AwsStsConfiguration defaultStsConfiguration = new AwsStsConfiguration();

So I think we should use a different name here.

One idea: isUseDefaultCredentialsProvider to clarify that this is coupled with the SDK's DefaultCredentialsProvider.

Thoughts?

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks @dlvenable for your input. I will make the change.

@@ -49,6 +54,10 @@ public static AwsCredentialsOptions defaultOptions() {
return DEFAULT_OPTIONS;
}

public static AwsCredentialsOptions defaultOptionsWithDefaultCreds() {
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
public static AwsCredentialsOptions defaultOptionsWithDefaultCreds() {
public static AwsCredentialsOptions defaultOptionsWithDefaultCredentialsProvider() {

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks @dlvenable. I have made the name change.

* @param useDefaultCredentials
* @return The {@link Builder} for continuing to build
*/
public Builder withUseDefaultCredentials(final boolean useDefaultCredentials) {
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
public Builder withUseDefaultCredentials(final boolean useDefaultCredentials) {
public Builder withUseDefaultCredentialsProvider(final boolean useDefaultCredentialsProvider) {

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks @dlvenable. I have made the name change.

Signed-off-by: Souvik Bose <souvbose@amazon.com>
@sb2k16 sb2k16 merged commit e26deaa into opensearch-project:main Oct 22, 2024
47 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.

Support AWS Kinesis Data Streams as a Source
4 participants