Skip to content

minor: Add new intermediate S3 role - #20540

Draft
adarshsanjeev wants to merge 2 commits into
apache:masterfrom
adarshsanjeev:intermediate-s3-role
Draft

adarshsanjeev wants to merge 2 commits into
apache:masterfrom
adarshsanjeev:intermediate-s3-role

Conversation

@adarshsanjeev

Copy link
Copy Markdown
Contributor

This pull request introduces support for configuring an intermediate AWS role to assume before the final role specified in S3 ingestion and export operations. This allows Druid clusters to use a fixed intermediate role, simplifying trust policies for S3 bucket owners.

  • Added a new configuration property, druid.s3.intermediateAssumeRoleArn, which specifies an intermediate AWS role to assume before the final assumeRoleArn.

This PR has:

  • been self-reviewed.
  • added documentation for new or modified features or behaviors.
  • a release note entry in the PR description.
  • added Javadocs for most classes and all non-trivial methods. Linked related entities via Javadoc links.
  • added or updated version, license, or notice information in licenses.yaml
  • added comments explaining the "why" and the intent of the code wherever would not be obvious for an unfamiliar reader.
  • added unit tests or modified existing tests to cover new code paths, ensuring the threshold for code coverage is met.
  • added integration tests.
  • been tested in a test Druid cluster.

@adarshsanjeev adarshsanjeev changed the title Add new intermediate S3 role minor: Add new intermediate S3 role Oct 9, 2026
@JsonProperty("endpointConfig") @Nullable AWSEndpointConfig awsEndpointConfig,
@JsonProperty("clientConfig") @Nullable AWSClientConfig awsClientConfig
@JsonProperty("clientConfig") @Nullable AWSClientConfig awsClientConfig,
@JacksonInject @Nullable S3IntermediateRoleConfig intermediateRoleConfig

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

note: was just looking around; I know its a draft - but one thing caught my eye:

there are already some JacksonInject stuff already; couldn't it make sense to just reuse an exiting config instead of adding a new S3IntermediateRoleConfig and passing that to a lot of places?

@adarshsanjeev adarshsanjeev Oct 9, 2026 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I was considering reusing AWSCredentialsConfig, but it's wasn't clear to me since it is not actually injected into all the classes I need. I would have to add it to places which might make it visible and, since it contains credentials, I figured I'd keep it separate in the initial PR.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

We already do have two classes bound to druid.s3 so it shouldn't break anything in terms of backward compatibility.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants