Skip to content

Commit 2a123d1

Browse files
committed
Remove REFRESH_CREDENTIALS_ENABLED from server response
1 parent cae0632 commit 2a123d1

File tree

8 files changed

+0
-29
lines changed

8 files changed

+0
-29
lines changed

polaris-core/src/main/java/org/apache/polaris/core/storage/StorageAccessProperty.java

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,6 @@ public enum StorageAccessProperty {
4242
Boolean.class, "s3.path-style-access", "whether to use S3 path style access", false),
4343
CLIENT_REGION(
4444
String.class, "client.region", "region to configure client for making requests to AWS"),
45-
AWS_REFRESH_CREDENTIALS_ENABLED(
46-
Boolean.class,
47-
AwsClientProperties.REFRESH_CREDENTIALS_ENABLED,
48-
"whether to enable automatic refresh of credentials",
49-
false,
50-
false),
5145
AWS_REFRESH_CREDENTIALS_ENDPOINT(
5246
String.class,
5347
AwsClientProperties.REFRESH_CREDENTIALS_ENDPOINT,
@@ -62,12 +56,6 @@ public enum StorageAccessProperty {
6256
"the time the gcs access token expires, in milliseconds",
6357
true,
6458
true),
65-
GCS_REFRESH_CREDENTIALS_ENABLED(
66-
Boolean.class,
67-
GCPProperties.GCS_OAUTH2_REFRESH_CREDENTIALS_ENABLED,
68-
"whether to enable automatic refresh of credentials",
69-
false,
70-
false),
7159
GCS_REFRESH_CREDENTIALS_ENDPOINT(
7260
String.class,
7361
GCPProperties.GCS_OAUTH2_REFRESH_CREDENTIALS_ENDPOINT,
@@ -79,12 +67,6 @@ public enum StorageAccessProperty {
7967
// it expects for SAS
8068
AZURE_ACCESS_TOKEN(String.class, "", "the azure scoped access token"),
8169
AZURE_SAS_TOKEN(String.class, "adls.sas-token.", "an azure shared access signature token"),
82-
AZURE_REFRESH_CREDENTIALS_ENABLED(
83-
Boolean.class,
84-
"adls.refresh-credentials-enabled",
85-
"whether to enable automatic refresh of credentials",
86-
false,
87-
false),
8870
AZURE_REFRESH_CREDENTIALS_ENDPOINT(
8971
String.class,
9072
"adls.refresh-credentials-endpoint",

polaris-core/src/main/java/org/apache/polaris/core/storage/aws/AwsCredentialsStorageIntegration.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,6 @@ public AccessConfig getSubscopedCreds(
123123

124124
refreshCredentialsEndpoint.ifPresent(
125125
endpoint -> {
126-
accessConfig.put(StorageAccessProperty.AWS_REFRESH_CREDENTIALS_ENABLED, "true");
127126
accessConfig.put(StorageAccessProperty.AWS_REFRESH_CREDENTIALS_ENDPOINT, endpoint);
128127
});
129128

polaris-core/src/main/java/org/apache/polaris/core/storage/azure/AzureCredentialsStorageIntegration.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,6 @@ static AccessConfig toAccessConfig(
188188
refreshCredentialsEndpoint.ifPresent(
189189
endpoint -> {
190190
accessConfig.put(StorageAccessProperty.AZURE_REFRESH_CREDENTIALS_ENDPOINT, endpoint);
191-
accessConfig.put(StorageAccessProperty.AZURE_REFRESH_CREDENTIALS_ENABLED, "true");
192191
});
193192
return accessConfig.build();
194193
}

polaris-core/src/main/java/org/apache/polaris/core/storage/gcp/GcpCredentialsStorageIntegration.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,6 @@ public AccessConfig getSubscopedCreds(
118118
refreshCredentialsEndpoint.ifPresent(
119119
endpoint -> {
120120
accessConfig.put(StorageAccessProperty.GCS_REFRESH_CREDENTIALS_ENDPOINT, endpoint);
121-
accessConfig.put(StorageAccessProperty.GCS_REFRESH_CREDENTIALS_ENABLED, "true");
122121
});
123122

124123
return accessConfig.build();

polaris-core/src/test/java/org/apache/polaris/core/storage/azure/AzureCredentialsStorageIntegrationTest.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,6 @@ public void testAzureCredentialFormatting() {
5858
.containsEntry(
5959
StorageAccessProperty.AZURE_REFRESH_CREDENTIALS_ENDPOINT.getPropertyName(),
6060
"endpoint/credentials");
61-
Assertions.assertThat(adlsSuffixResult.extraProperties())
62-
.containsEntry(
63-
StorageAccessProperty.AZURE_REFRESH_CREDENTIALS_ENABLED.getPropertyName(), "true");
6461

6562
AccessConfig blobSuffixResult =
6663
toAccessConfig(

polaris-core/src/test/java/org/apache/polaris/service/storage/aws/AwsCredentialsStorageIntegrationTest.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,8 +107,6 @@ public void testGetSubscopedCreds(String scheme) {
107107
StorageAccessProperty.AWS_SESSION_TOKEN_EXPIRES_AT_MS.getPropertyName(),
108108
String.valueOf(EXPIRE_TIME.toEpochMilli()));
109109
assertThat(accessConfig.extraProperties())
110-
.containsEntry(
111-
StorageAccessProperty.AWS_REFRESH_CREDENTIALS_ENABLED.getPropertyName(), "true")
112110
.containsEntry(
113111
StorageAccessProperty.AWS_REFRESH_CREDENTIALS_ENDPOINT.getPropertyName(),
114112
"/namespace/table/credentials");

polaris-core/src/test/java/org/apache/polaris/service/storage/gcp/GcpCredentialsStorageIntegrationTest.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -311,8 +311,6 @@ public void testRefreshCredentialsEndpointIsReturned() throws IOException {
311311
List.of("gs://bucket1/path/to/data"), List.of("gs://bucket1/path/to/data"), true);
312312
assertThat(accessConfig.get(StorageAccessProperty.GCS_REFRESH_CREDENTIALS_ENDPOINT))
313313
.isEqualTo(REFRESH_ENDPOINT);
314-
assertThat(accessConfig.get(StorageAccessProperty.GCS_REFRESH_CREDENTIALS_ENABLED))
315-
.isEqualTo(Boolean.TRUE.toString());
316314
}
317315

318316
private boolean isNotNull(JsonNode node) {

runtime/service/src/intTest/java/org/apache/polaris/service/it/RestCatalogMinIOSpecialIT.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,6 @@ public LoadTableResponse doTestCreateTable(RESTCatalog restCatalog) throws IOExc
269269
catalogApi.loadTableWithAccessDelegation(catalogName, id, "ALL");
270270
assertThat(loadTableResponse.config())
271271
.containsKey("s3.endpoint")
272-
.containsEntry(AwsClientProperties.REFRESH_CREDENTIALS_ENABLED, Boolean.TRUE.toString())
273272
.containsEntry(
274273
AwsClientProperties.REFRESH_CREDENTIALS_ENDPOINT,
275274
"v1/" + catalogName + "/namespaces/test-ns/tables/t1/credentials");

0 commit comments

Comments
 (0)