This is an automated email from the ASF dual-hosted git repository.

dimas pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/polaris.git


The following commit(s) were added to refs/heads/main by this push:
     new 304bff899 Remove unused `refreshCredentials` methods on 
`BasePolarisCatalog` (#1143)
304bff899 is described below

commit 304bff899d6c499b1a69c02d4367e8553f77b007
Author: smaheshwar-pltr <[email protected]>
AuthorDate: Mon Mar 10 21:09:48 2025 +0000

    Remove unused `refreshCredentials` methods on `BasePolarisCatalog` (#1143)
    
    Co-authored-by: Sreesh Maheshwar <[email protected]>
---
 .../service/catalog/BasePolarisCatalog.java        | 55 ----------------------
 1 file changed, 55 deletions(-)

diff --git 
a/service/common/src/main/java/org/apache/polaris/service/catalog/BasePolarisCatalog.java
 
b/service/common/src/main/java/org/apache/polaris/service/catalog/BasePolarisCatalog.java
index ca9771ef2..b49b73e9c 100644
--- 
a/service/common/src/main/java/org/apache/polaris/service/catalog/BasePolarisCatalog.java
+++ 
b/service/common/src/main/java/org/apache/polaris/service/catalog/BasePolarisCatalog.java
@@ -883,61 +883,6 @@ public class BasePolarisCatalog extends 
BaseMetastoreViewCatalog
     return FileIOUtil.findStorageInfoFromHierarchy(resolvedStorageEntity);
   }
 
-  private Map<String, String> refreshCredentials(
-      TableIdentifier tableIdentifier,
-      Set<PolarisStorageActions> storageActions,
-      String tableLocation,
-      PolarisEntity entity) {
-    return refreshCredentials(tableIdentifier, storageActions, 
Set.of(tableLocation), entity);
-  }
-
-  private Map<String, String> refreshCredentials(
-      TableIdentifier tableIdentifier,
-      Set<PolarisStorageActions> storageActions,
-      Set<String> tableLocations,
-      PolarisEntity entity) {
-    Boolean skipCredentialSubscopingIndirection =
-        getBooleanContextConfiguration(
-            PolarisConfiguration.SKIP_CREDENTIAL_SUBSCOPING_INDIRECTION.key,
-            
PolarisConfiguration.SKIP_CREDENTIAL_SUBSCOPING_INDIRECTION.defaultValue);
-    if (Boolean.TRUE.equals(skipCredentialSubscopingIndirection)) {
-      LOGGER
-          .atInfo()
-          .addKeyValue("tableIdentifier", tableIdentifier)
-          .log("Skipping generation of subscoped creds for table");
-      return Map.of();
-    }
-
-    boolean allowList =
-        storageActions.contains(PolarisStorageActions.LIST)
-            || storageActions.contains(PolarisStorageActions.ALL);
-    Set<String> writeLocations =
-        storageActions.contains(PolarisStorageActions.WRITE)
-                || storageActions.contains(PolarisStorageActions.DELETE)
-                || storageActions.contains(PolarisStorageActions.ALL)
-            ? tableLocations
-            : Set.of();
-    Map<String, String> credentialsMap =
-        entityManager
-            .getCredentialCache()
-            .getOrGenerateSubScopeCreds(
-                getCredentialVendor(),
-                callContext.getPolarisCallContext(),
-                entity,
-                allowList,
-                tableLocations,
-                writeLocations);
-    LOGGER
-        .atDebug()
-        .addKeyValue("tableIdentifier", tableIdentifier)
-        .addKeyValue("credentialKeys", credentialsMap.keySet())
-        .log("Loaded scoped credentials for table");
-    if (credentialsMap.isEmpty()) {
-      LOGGER.debug("No credentials found for table");
-    }
-    return credentialsMap;
-  }
-
   /**
    * Validates that the specified {@code location} is valid for whatever 
storage config is found for
    * this TableLike's parent hierarchy.

Reply via email to