okumin commented on code in PR #6458:
URL: https://github.com/apache/hive/pull/6458#discussion_r4335735444
##########
standalone-metastore/metastore-rest-catalog/src/main/java/org/apache/iceberg/rest/HMSCatalogAdapter.java:
##########
@@ -468,6 +485,33 @@ private LoadViewResponse registerView(Map<String, String>
vars, Object body) {
return CatalogHandlers.registerView(asViewCatalog, namespace, request);
}
+ private LoadTableResponse withCredentials(
+ Set<AccessDelegationMode> accessDelegationModes,
+ TableIdentifier ident,
+ LoadTableResponse response) {
+ if (credentialProvider == null) {
+ return response;
+ }
+
+ if
(accessDelegationModes.contains(AccessDelegationMode.VENDED_CREDENTIALS)) {
+ return withVendedCredentials(ident, response);
+ }
+
+ if (accessDelegationModes.contains(AccessDelegationMode.REMOTE_SIGNING)) {
+ LOG.warn("Remote signing is not supported. Ignoring...");
+ }
+
+ return response;
+ }
+
+ private LoadTableResponse withVendedCredentials(TableIdentifier ident,
LoadTableResponse response) {
+ final var credentials = credentialProvider.vend(catalogName, ident,
response.tableMetadata());
Review Comment:
Interesting. Let me clarify my understanding. Say the table location is
`ofs://bucket/path/to/db/tbl`.
In this case, do some clients access it via `s3a://bucket/path/to/db/tbl`
and some Ozone-native clients access it via `ofs://bucket/path/to/db/tbl`?
Also, can we use the same credentials to access
`s3a://bucket/path/to/db/tbl` and `ofs://bucket/path/to/db/tbl`?
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]