Skip to content

Commit 2d8baf9

Browse files
committed
feat: Support non-default adls authority host
1 parent 4da0177 commit 2d8baf9

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

crates/iceberg/src/io/storage_azdls.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,11 @@ pub const ADLS_CLIENT_ID: &str = "adls.client-id";
5050
/// The client-secret.
5151
pub const ADLS_CLIENT_SECRET: &str = "adls.client-secret";
5252

53+
/// The authority host of the service principal.
54+
/// - required for client_credentials authentication
55+
/// - default value: `https://login.microsoftonline.com`
56+
pub const ADLS_AUTHORITY_HOST: &str = "adls.authority-host";
57+
5358
/// Parses adls.* prefixed configuration properties.
5459
pub(crate) fn azdls_config_parse(mut properties: HashMap<String, String>) -> Result<AzdlsConfig> {
5560
let mut config = AzdlsConfig::default();
@@ -85,6 +90,10 @@ pub(crate) fn azdls_config_parse(mut properties: HashMap<String, String>) -> Res
8590
config.client_secret = Some(client_secret);
8691
}
8792

93+
if let Some(authority_host) = properties.remove(ADLS_AUTHORITY_HOST) {
94+
config.authority_host = Some(authority_host);
95+
}
96+
8897
Ok(config)
8998
}
9099

0 commit comments

Comments
 (0)