Uh oh!
There was an error while loading. Please reload this page.
[Fix](MS)Handle missing endpoint in DLF-only Metastore scenario with region fallback - #54300
Conversation
…region fallback ### PR Description This PR fixes a special case where the endpoint parameter might be missing when using DLF as the Hive Metastore (MS) without configuring any storage backend. #### Background In certain deployments, users rely solely on DLF as the metastore and do not explicitly configure object storage credentials. In these cases: Only DLF access_key, secret_key, and region are provided. dlf.endpoint is omitted by the user. The system attempts to initialize storage configuration, but fails because endpoint is required. This issue occurs because the existing logic assumes that the storage module always receives a valid endpoint, which is not the case when DLF is used as MS only. #### Fix When dlf.endpoint is not set, and dlf.region is available, this patch automatically derives a valid default endpoint based on the region and network mode (public or VPC). This logic is consistent with the existing behavior of DLF SDKs and avoids unnecessary configuration burden for users using DLF as MS only. #### Compatibility Backward compatible: No breaking change for users who already provide an endpoint. Recommended best practice remains: Users are encouraged to explicitly configure both endpoint and region for clarity.
Thearas
commented
Aug 4, 2025
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
CalvinKirs
commented
Aug 4, 2025
run buildall |
CalvinKirs
commented
Aug 4, 2025
run buildall |
hello-stephen
commented
Aug 4, 2025
FE UT Coverage ReportIncrement line coverage |
doris-robot
commented
Aug 4, 2025
TPC-H: Total hot run time: 33571 ms |
doris-robot
commented
Aug 4, 2025
TPC-DS: Total hot run time: 169809 ms |
doris-robot
commented
Aug 4, 2025
ClickBench: Total hot run time: 32.87 s |
CalvinKirs
commented
Aug 5, 2025
run buildall |
doris-robot
commented
Aug 5, 2025
TPC-H: Total hot run time: 34136 ms |
doris-robot
commented
Aug 5, 2025
TPC-DS: Total hot run time: 170971 ms |
doris-robot
commented
Aug 5, 2025
ClickBench: Total hot run time: 32.84 s |
CalvinKirs
commented
Aug 5, 2025
run buildall |
doris-robot
commented
Aug 5, 2025
TPC-H: Total hot run time: 33631 ms |
doris-robot
commented
Aug 5, 2025
TPC-DS: Total hot run time: 170279 ms |
doris-robot
commented
Aug 5, 2025
ClickBench: Total hot run time: 32.96 s |
hello-stephen
commented
Aug 5, 2025
FE UT Coverage ReportIncrement line coverage |
CalvinKirs
commented
Aug 5, 2025
run buildall |
doris-robot
commented
Aug 5, 2025
TPC-H: Total hot run time: 33710 ms |
doris-robot
commented
Aug 5, 2025
TPC-DS: Total hot run time: 171024 ms |
doris-robot
commented
Aug 5, 2025
ClickBench: Total hot run time: 33.34 s |
PR approved by at least one committer and no changes requested. |
PR approved by anyone and no changes requested. |
CalvinKirs
commented
Aug 8, 2025
run buildall |
CalvinKirs
commented
Aug 8, 2025
run buildall |
doris-robot
commented
Aug 8, 2025
TPC-H: Total hot run time: 33691 ms |
doris-robot
commented
Aug 8, 2025
TPC-DS: Total hot run time: 170825 ms |
doris-robot
commented
Aug 8, 2025
ClickBench: Total hot run time: 32.94 s |
CalvinKirs
commented
Aug 9, 2025
run buildall |
doris-robot
commented
Aug 9, 2025
TPC-H: Total hot run time: 33683 ms |
doris-robot
commented
Aug 9, 2025
TPC-DS: Total hot run time: 160099 ms |
doris-robot
commented
Aug 9, 2025
ClickBench: Total hot run time: 33.14 s |
| .require(dlfSecretKey, "dlf.secret_key is required"); | ||
| } | ||
| public void checkAndInit() { |
There was a problem hiding this comment.
| publicvoidcheckAndInit() { | |
| privatevoidcheckAndInit() { |
PR approved by at least one committer and no changes requested. |
Uh oh!
There was an error while loading. Please reload this page.
…region fallback (#54300) #50238 ### PR Description This PR fixes a special case where the endpoint parameter might be missing when using DLF as the Hive Metastore (MS) without configuring any storage backend. #### Background In certain deployments, users rely solely on DLF as the metastore and do not explicitly configure object storage credentials. In these cases: Only DLF access_key, secret_key, and region are provided. dlf.endpoint is omitted by the user. ``` create catalog if not exists pm_dlf properties ( "type" = "paimon", "paimon.catalog.type" = "dlf", "warehouse" = "oss://asf-doris-datalake-test/p2_regression_case", "dlf.proxy.mode" = "DLF_ONLY", "dlf.uid" = "1289998888", "dlf.region" = "cn-beijing", "dlf.catalog.id" = "asf", "dlf.access_key" = "ABSHJJJKKKLKJHVGFGHJKLKJHGHJKJHGHJK", "dlf.secret_key" = "UYGFHJKHGVVHBJKHVGBJKL:JHGVBJKLHVGHJHVGH" ); switch pm_dlf; show databases; exception: Exception:java.sql.SQLException: errCode = 2, detailMessage = UserException: errCode = 2, detailMessage = No storage properties found for schema: oss at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:129) at ``` The system attempts to initialize storage configuration, but fails because endpoint is required. This issue occurs because the existing logic assumes that the storage module always receives a valid endpoint, which is not the case when DLF is used as MS only. #### Fix When dlf.endpoint is not set, and dlf.region is available, this patch automatically derives a valid default endpoint based on the region and network mode (public or VPC). This logic is consistent with the existing behavior of DLF SDKs and avoids unnecessary configuration burden for users using DLF as MS only. #### Compatibility Backward compatible: No breaking change for users who already provide an endpoint. Recommended best practice remains: Users are encouraged to explicitly configure both endpoint and region for clarity.
#50238
PR Description
This PR fixes a special case where the endpoint parameter might be missing when using DLF as the Hive Metastore (MS) without configuring any storage backend.
Background
In certain deployments, users rely solely on DLF as the metastore and do not explicitly configure object storage credentials. In these cases:
Only DLF access_key, secret_key, and region are provided.
dlf.endpoint is omitted by the user.
The system attempts to initialize storage configuration, but fails because endpoint is required.
This issue occurs because the existing logic assumes that the storage module always receives a valid endpoint, which is not the case when DLF is used as MS only.
Fix
When dlf.endpoint is not set, and dlf.region is available, this patch automatically derives a valid default endpoint based on the region and network mode (public or VPC).
This logic is consistent with the existing behavior of DLF SDKs and avoids unnecessary configuration burden for users using DLF as MS only.
Compatibility
Backward compatible: No breaking change for users who already provide an endpoint.
Recommended best practice remains: Users are encouraged to explicitly configure both endpoint and region for clarity.
What problem does this PR solve?
Issue Number: close #xxx
Related PR: #xxx
Problem Summary:
Release note
None
Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)