Open
Description
Is your feature request related to a problem? Please describe.
My organization does not allow getting user delegation key in Azure and the only option for us to authenticate with Azure is to use service principal. When my spark job tries to write to Azure, I will get the following exception at Polaris server:
c.a.s.f.d.DataLakeServiceClient: If you are using a StorageSharedKeyCredential, and the server returned an error message that says 'Signature did not match', you can compare the string to sign with the one generated by the SDK. To log the string to sign, pass in the context key value pair 'Azure-Storage-Log-String-To-Sign': true to the appropriate method call. If you are using a SAS token, and the server returned an error message that says 'Signature did not match', you can compare the string to sign with the one generated by the SDK. To log the string to sign, pass in the context key value pair 'Azure-Storage-Log-String-To-Sign': true to the appropriate generateSas method call. Please remember to disable 'Azure-Storage-Log-String-To-Sign' before going to production as this string can potentially contain PII."
<?xml version="1.0" encoding="utf-8"?><Error><Code>AuthorizationPermissionMismatch</Code><Message>This request is not authorized to perform this operation using this permission.</Message></Error>"
Describe the solution you'd like
Since ADLSFileIO
fall back to use DefaultAzureCredentialBuilder
when there are no SAS token
or Storage Shared Key credential
, we can have a default catalog option to use environment as authentication type e.g.:
{
"name": "test",
"type": "INTERNAL",
"properties": {
"default-base-location": "abfss://[email protected]/test/"
},
"storageConfigInfo": {
"tenantId": "tenant-id",
"storageType": "AZURE",
"allowedLocations": [
"abfss://[email protected]/test/"
],
"authType": "APPLICATION_DEFAULT"
}
}
so that any query engine can abstract away the credential and the main credential still being govern by Polaris Catalog for Azure.