dennishuo commented on code in PR #2473:
URL: https://github.com/apache/polaris/pull/2473#discussion_r2310989646
##########
polaris-core/src/main/java/org/apache/polaris/core/storage/PolarisStorageConfigurationInfo.java:
##########
@@ -160,7 +161,7 @@ public static Optional<PolarisStorageConfigurationInfo>
forEntityPath(
Set<String> locations =
StorageUtil.getLocationsAllowedToBeAccessed(
null, entityPathReversed.get(0).getPropertiesAsMap());
- return new StorageConfigurationOverride(
+ return new LocationRestrictions(
Review Comment:
Right, regardless of whether this allows or disallows setting
`write.metadata.path` for Views, that test case is currently documenting the
incorrect behavior that also applies to Tables.
Probably better to fix-forward the test; even #1320 itself indicated it was
just documenting current observed behavior, but we can update the
`createViewWithCustomMetadataLocationUsingPolaris` to ensure it also fails with
ForbiddenException even if the custom path is in the parent.
In this case we also want to make sure even with
`ALLOW_UNSTRUCTURED_TABLE_LOCATION=true` for the *CreateTable* scenario (not
CreateView), the creation will fail if the "custom location" isn't part of the
Catalog's `allowedLocations`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]