diff --git a/azure/src/main/java/org/apache/iceberg/azure/adlsv2/VendedAdlsCredentialProvider.java b/azure/src/main/java/org/apache/iceberg/azure/adlsv2/VendedAdlsCredentialProvider.java index 145e236cc62c..4293549d87db 100644 --- a/azure/src/main/java/org/apache/iceberg/azure/adlsv2/VendedAdlsCredentialProvider.java +++ b/azure/src/main/java/org/apache/iceberg/azure/adlsv2/VendedAdlsCredentialProvider.java @@ -33,7 +33,6 @@ import org.apache.iceberg.rest.ErrorHandlers; import org.apache.iceberg.rest.HTTPClient; import org.apache.iceberg.rest.RESTClient; -import org.apache.iceberg.rest.RESTUtil; import org.apache.iceberg.rest.auth.OAuth2Properties; import org.apache.iceberg.rest.auth.OAuth2Util; import org.apache.iceberg.rest.credentials.Credential; @@ -141,23 +140,15 @@ private RESTClient httpClient() { } private LoadCredentialsResponse fetchCredentials() { - Map headers = - RESTUtil.merge( - configHeaders(properties), - OAuth2Util.authHeaders(properties.get(OAuth2Properties.TOKEN))); return httpClient() .get( properties.get(URI), null, LoadCredentialsResponse.class, - headers, + OAuth2Util.authHeaders(properties.get(OAuth2Properties.TOKEN)), ErrorHandlers.defaultErrorHandler()); } - private Map configHeaders(Map props) { - return RESTUtil.extractPrefixMap(props, "header."); - } - private void checkCredential(Credential credential, String property) { Preconditions.checkState( credential.config().containsKey(property),