From f3d1d6fff990d3b20675af701b35b9e9dafee939 Mon Sep 17 00:00:00 2001 From: xylaaaaa <2392805527@qq.com> Date: Fri, 14 Aug 2026 19:25:17 +0800 Subject: [PATCH] [fix](iceberg) Support Azure vended credentials ### What problem does this PR solve? Issue Number: None Related PR: None Problem Summary: Databricks Unity Catalog returns Azure SAS credentials using Iceberg ADLS property names. Doris previously filtered those properties and did not package Iceberg ADLSFileIO, so catalog discovery could succeed while data reads failed. Passing the resulting Hadoop configuration to BE also risked logging the short-lived SAS value. This change normalizes account-scoped ADLS SAS credentials for Hadoop ABFS, packages the Iceberg Azure runtime, and stops logging HDFS configuration values. ### Release note Support Azure SAS credentials vended by Iceberg REST catalogs such as Databricks Unity Catalog. ### Check List (For Author) - Test: - Unit Test: CredentialUtilsTest, DefaultConnectorContextVendTest, and IcebergScanPlanProviderTest - Manual test: FE build and BE build with -j 8 - Behavior changed: Yes. Iceberg REST catalogs can use vended Azure SAS credentials for ADLS data access. - Does this need documentation: No --- be/src/io/hdfs_builder.cpp | 3 +- fe/fe-connector/fe-connector-iceberg/pom.xml | 12 +++++++ .../iceberg/IcebergScanPlanProviderTest.java | 13 +++++++ .../connector/DefaultConnectorContext.java | 8 ++--- .../credentials/CredentialUtils.java | 35 +++++++++++++++++++ .../DefaultConnectorContextVendTest.java | 27 ++++++++++++++ .../credentials/CredentialUtilsTest.java | 17 +++++++++ fe/pom.xml | 10 ++++++ 8 files changed, 120 insertions(+), 5 deletions(-) diff --git a/be/src/io/hdfs_builder.cpp b/be/src/io/hdfs_builder.cpp index cb9c75fb29debc..b004d41de53afa 100644 --- a/be/src/io/hdfs_builder.cpp +++ b/be/src/io/hdfs_builder.cpp @@ -210,7 +210,8 @@ Status create_hdfs_builder(const THdfsParams& hdfsParams, const std::string& fs_ // set other conf for (const THdfsConf& conf : hdfsParams.hdfs_conf) { builder->set_hdfs_conf(conf.key, conf.value); - LOG(INFO) << "set hdfs config key: " << conf.key << ", value: " << conf.value; + // HDFS configuration may contain short-lived storage credentials such as an ADLS SAS token. + LOG(INFO) << "set hdfs config key: " << conf.key; if (strcmp(conf.key.c_str(), "hadoop.security.authentication") == 0) { auth_type = conf.value; } diff --git a/fe/fe-connector/fe-connector-iceberg/pom.xml b/fe/fe-connector/fe-connector-iceberg/pom.xml index e3432510b22b49..5896b1f32e50a8 100644 --- a/fe/fe-connector/fe-connector-iceberg/pom.xml +++ b/fe/fe-connector/fe-connector-iceberg/pom.xml @@ -150,6 +150,18 @@ under the License. ${iceberg.version} + + + org.apache.iceberg + iceberg-azure + ${iceberg.version} + + + org.apache.iceberg + iceberg-azure-bundle + ${iceberg.version} + + software.amazon.s3tables