-
Notifications
You must be signed in to change notification settings - Fork 136
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
Store AWS region in AwsStorageConfigurationInfo #455
base: main
Are you sure you want to change the base?
Conversation
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.
[doubt] This region specified will be region of the polaris catalog ? Do we plan to support federation of catalogs in future if yes, the should this be the region of polaris catalog or the region of federated catalog ?
for ex:
can this a possible case in coming future ?
Polaris -> (Federated to) -> Glue
(region A) ------ > (region B)
Hey @singhpk234, the idea is that you can associate a region with a storage configuration so that the region can be used by any client that leverages credentials/files associated that storage configuration. As you pointed out, it is not clear how this will work with catalog federation (cc @dennishuo). But I think it is also unclear how storage configurations will work with federated catalogs more generally -- for example, a single role ARN may not be valid for the entire federated catalog. So this is something our design for federation must address. At the very least, we have discussed allowing storage configurations to be defined on a level more granular than the catalog (e.g. at the table or namespace level). Maybe @munendrasn, the filer of #342, can also help provide some additional context here. For my part I am curious if there's a particular test case we can add here to make sure the issue reported in #342 is fully addressed. |
@eric-maynard On the testing, are you looking to test it via Iceberg APIs or directly S3 client API? If AWS_REGION is set to one region but the table's storage in another region.. any read or listOperation would fail unless region is explicitly specified on s3Client creation |
Hi @munendrasn I see -- do the current changes here work for your use case then? |
@eric-maynard |
Hi @munendrasn, please see the newly-added test. |
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.
lgtm
...core/src/main/java/org/apache/polaris/core/storage/aws/AwsCredentialsStorageIntegration.java
Outdated
Show resolved
Hide resolved
@JsonProperty(value = "roleARN", required = true) @NotNull String roleARN) { | ||
this(storageType, allowedLocations, roleARN, null); | ||
@JsonProperty(value = "roleARN", required = true) @NotNull String roleARN, | ||
@JsonProperty(value = "region", required = false) @NotNull String region) { |
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.
Why @NotNull
here while the property is nullable?
Description
This adds support for a new property,
region
for AWS storage configurations.Fixes #342
Type of change
Please delete options that are not relevant.
How Has This Been Tested?
I'm able to create catalogs and add the
region
property to the StorageConfigInfo: