Skip to content

[fix](catalog) Restore DLF support for Iceberg and Paimon - #67545

Open
Gabriel39 wants to merge 5 commits into
apache:masterfrom
Gabriel39:fix/restore-dlf-catalog-support
Open

[fix](catalog) Restore DLF support for Iceberg and Paimon#67545
Gabriel39 wants to merge 5 commits into
apache:masterfrom
Gabriel39:fix/restore-dlf-catalog-support

Conversation

@Gabriel39

Copy link
Copy Markdown
Contributor

What problem does this PR solve?

Issue Number: None

Related PR: None

Problem Summary:

The connector metastore SPI refactor removed DLF provider registration and the plugin-local DLF client path, so existing Iceberg and Paimon catalogs using dlf can no longer be created or replayed on master.

This PR restores DLF support for both connectors:

  • Register engine-specific DLF metastore providers and restore legacy property aliases, endpoint derivation, catalog-id fallback, and sensitive credential handling.
  • Restore the Iceberg DLF catalog and client pool, with catalog-scoped client caching and OSS-backed S3FileIO.
  • Route Paimon DLF through its Hive catalog using ProxyMetaStoreClient, while preserving legacy alias-only OSS and OSS-HDFS storage configurations.
  • Bundle the matching Hive 3 and Hive 2 DLF clients into the existing Iceberg/HMS and Paimon private shades, including their Thrift and Tea namespace isolation.

Release note

Restore Aliyun DLF metastore support for Iceberg and Paimon catalogs.

Check List (For Author)

  • Test

    • Regression test
    • Unit Test
    • Manual test (add detailed scripts or steps below)
      • Targeted Iceberg, Paimon, metastore provider, property-binding, and DLF catalog tests passed.
      • The 19-module connector package build passed with tests skipped; FE Checkstyle reported zero violations.
      • Verified both generated private shade jars contain the DLF proxy client and relocated Thrift and Tea classes.
      • The full Iceberg connector suite was also attempted; 1 of 1,376 tests failed in the unrelated IcebergWritePlanProviderTest.planMergePreservesExplicitlyEmptyReadAcrossConcurrentFirstAppend case. The focused rerun reproduces the same failure, and this PR does not modify that code path.
    • No need to test or manual test. Explain why:
      • This is a refactor/code format and no logic has been changed.
      • Previous test can cover this change.
      • No code files have been changed.
      • Other reason
  • Behavior changed:

    • No.
    • Yes. Iceberg and Paimon catalogs can use the DLF metastore backend again.
  • Does this need documentation?

    • No. Existing DLF catalog properties and behavior are restored.
    • Yes.

Check List (For Reviewer who merge this PR)

  • Confirm the release note
  • Confirm test cases
  • Confirm document
  • Add branch pick label

@hello-stephen

Copy link
Copy Markdown
Contributor

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR.

Please clearly describe your PR:

  1. What problem was fixed (it's best to include specific error reporting information). How it was fixed.
  2. Which behaviors were modified. What was the previous behavior, what is it now, why was it modified, and what possible impacts might there be.
  3. What features were added. Why was this function added?
  4. Which code was refactored and why was this part of the code refactored?
  5. Which functions were optimized and what is the difference before and after the optimization?

@Gabriel39

Copy link
Copy Markdown
Contributor Author

run buildall

@Gabriel39

Copy link
Copy Markdown
Contributor Author

/review

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found ten correctness and lifecycle issues in the restored DLF paths and am requesting changes. The highest-impact failures are inconsistent credential aliases, incompatible endpoint/region validation, cross-catalog/stale Paimon client reuse, unreleased Iceberg DLF resources, unintended CREATE TABLE routing, mixed-format table discovery, and a no-op explicit connectivity test.

Critical checkpoint conclusions:

  • Goal and proof: The patch restores provider registration and catalog construction for Iceberg/Paimon DLF, but the end-to-end goal is not yet met because valid credential/endpoint forms fail, catalog replacement can reuse or leave clients open, and several runtime operations violate their contracts. The added tests prove dispatch and small property/helper cases only.
  • Scope and focus: The changes are DLF-focused, but they reintroduce a sizeable legacy catalog implementation instead of reusing Iceberg HiveCatalog semantics; the resulting deviations are called out inline.
  • Concurrency: No new locks or explicit worker threads are added. Caffeine itself is thread-safe, but Paimon's JVM-static pool creates cross-catalog/configuration isolation failures rather than a lock-order bug. No deadlock path was found.
  • Lifecycle: Not correct. Iceberg connector closure reaches only BaseMetastoreCatalog's metrics close, leaving DLF FileIO and metastore clients open; Paimon's static pool also survives catalog generations.
  • Configuration and dynamic changes: DLF aliases and endpoint derivation are added. ALTER/recreation with the same DLF catalog id is unsafe because the Paimon cache identity excludes endpoint/credential/proxy settings; the metastore/storage alias sets disagree; and endpoint-only DLF configuration cannot supply native OSS's required region.
  • Compatibility and rolling upgrade: No FE/BE wire format, storage format, or symbol contract changes were found. The Hive2/Hive3 DLF shade dependencies and relocations match their respective plugin families, but backward-compatible property aliases are incomplete at the storage boundary.
  • Parallel paths: Iceberg and Paimon providers are registered in both ServiceLoader files. The parallel OSS and OSS-HDFS binders both miss the same DLF secret/token aliases, while only OSS-HDFS understands DLF endpoints for region derivation; the new Iceberg DLF remote flavor is also omitted from the metastore connectivity-probe set.
  • Conditional checks: The type-routing and OSS-provider gates are understandable, but endpoint conversion is not idempotent, endpoint-or-region validation disagrees with storage requirements, and the connectivity-test condition excludes DLF. No other conditional-path defect survived review.
  • Test coverage: Unit tests cover provider dispatch, validation, derived endpoints, flavor resolution, and two endpoint conversions. They do not exercise STS alias propagation, endpoint-only storage binding, same-id catalog/ALTER isolation, catalog close, SQL DDL, mixed-format listing, namespace metadata/errors, explicit connectivity failure, or already-prefixed endpoints.
  • Test results: I did not run builds or tests because this review runner explicitly forbids them. No generated regression result files are changed.
  • Observability: Existing connector exception/log boundaries are generally adequate, but the unintended CREATE TABLE path replaces a stable unsupported-operation result with an unrelated URI/I/O failure. No new metrics are necessary for the intended feature.
  • Transactions and persistence: No Doris EditLog or transaction-state changes are present. External DLF metadata writes are only relevant through the newly exposed CREATE TABLE path, which must be gated or fully implemented.
  • Data writes: The intended restoration is primarily read/catalog access. CREATE TABLE is nevertheless reachable and fails before metastore commit after constructing a malformed metadata path; this is called out inline.
  • FE/BE variables: No new thrift variables or protocol fields are introduced. Existing BE storage credentials are affected by the missing token alias propagation.
  • Performance: No new hot-loop or asymptotic issue was found. The material resource risks are the static pool's incorrect reuse and the Iceberg client's missing deterministic closure after catalog replacement.
  • Other issues: Mixed-format table filtering, namespace location/error semantics, and S3-compatible endpoint normalization have separate inline comments.
  • User focus: No additional focus was supplied; the complete PR was reviewed.
  • Review completion: Complete for head d11010b after three full rounds, including normal and risk-focused convergence; every candidate was accepted, merged, or dismissed with evidence.

@hello-stephen

Copy link
Copy Markdown
Contributor
TPC-H: Total hot run time: 16778 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit d11010bbd679570c048aa4e2dba5a88d512fdbd0, data reload: false

------ Round 1 ----------------------------------
============================================
q1	17562	3030	3038	3030
q2	2051	254	229	229
q3	10272	899	521	521
q4	4674	253	215	215
q5	7664	569	391	391
q6	133	117	94	94
q7	525	492	388	388
q8	9245	952	985	952
q9	3476	2422	2432	2422
q10	6502	859	703	703
q11	394	200	183	183
q12	612	262	197	197
q13	18163	1543	1154	1154
q14	163	150	145	145
q15	q16	433	400	378	378
q17	1321	847	717	717
q18	3137	2325	2318	2318
q19	1274	855	729	729
q20	395	297	210	210
q21	5580	1574	1918	1574
q22	329	272	228	228
Total cold run time: 93905 ms
Total hot run time: 16778 ms

----- Round 2, with runtime_filter_mode=off -----
============================================
q1	3358	3297	3283	3283
q2	513	394	381	381
q3	2256	2468	2207	2207
q4	1207	1194	910	910
q5	2253	2162	2158	2158
q6	166	123	87	87
q7	1074	960	910	910
q8	1616	1426	1412	1412
q9	3268	3250	3176	3176
q10	1877	1850	1695	1695
q11	364	286	259	259
q12	454	435	344	344
q13	1510	1562	1156	1156
q14	173	192	170	170
q15	q16	398	404	358	358
q17	3674	3413	3253	3253
q18	4938	4555	4987	4555
q19	938	859	852	852
q20	987	996	859	859
q21	3800	3108	3210	3108
q22	397	347	327	327
Total cold run time: 35221 ms
Total hot run time: 31460 ms

@hello-stephen

Copy link
Copy Markdown
Contributor
TPC-DS: Total hot run time: 83196 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit d11010bbd679570c048aa4e2dba5a88d512fdbd0, data reload: false

query5	4240	413	341	341
query6	383	137	135	135
query7	4940	403	233	233
query8	290	124	122	122
query9	8677	2879	2900	2879
query10	400	236	181	181
query11	5390	1059	925	925
query12	115	70	72	70
query13	1194	454	316	316
query14	6053	2255	2125	2125
query14_1	2063	2022	2016	2016
query15	171	124	113	113
query16	919	380	349	349
query17	799	465	368	368
query18	2335	338	236	236
query19	168	143	113	113
query20	73	73	74	73
query21	203	101	88	88
query22	5505	5569	5426	5426
query23	6874	6376	6036	6036
query23_1	6123	6182	6302	6182
query24	7247	1081	789	789
query24_1	768	789	789	789
query25	418	273	237	237
query26	1213	243	130	130
query27	2770	397	259	259
query28	4715	1491	1490	1490
query29	926	432	348	348
query30	250	159	127	127
query31	818	408	332	332
query32	133	74	69	69
query33	449	215	167	167
query34	1003	839	485	485
query35	393	400	349	349
query36	590	571	558	558
query37	118	84	67	67
query38	1005	857	843	843
query39	494	510	499	499
query39_1	463	490	468	468
query40	214	89	86	86
query41	61	51	51	51
query42	73	75	71	71
query43	239	247	213	213
query44	1002	545	552	545
query45	112	103	103	103
query46	796	829	534	534
query47	770	777	715	715
query48	320	308	211	211
query49	531	237	193	193
query50	726	250	195	195
query51	8206	8052	7934	7934
query52	74	78	61	61
query53	193	218	204	204
query54	234	184	197	184
query55	79	61	59	59
query56	227	193	179	179
query57	697	641	663	641
query58	207	175	163	163
query59	1275	1257	1152	1152
query60	237	190	180	180
query61	139	142	169	142
query62	355	205	183	183
query63	173	141	143	141
query64	2819	678	598	598
query65	1627	1677	1632	1632
query66	1892	266	219	219
query67	10084	10090	9905	9905
query68	2745	1256	760	760
query69	326	216	196	196
query70	702	637	634	634
query71	255	186	163	163
query72	2359	1762	1585	1585
query73	616	581	342	342
query74	1585	1237	1166	1166
query75	1179	1134	987	987
query76	2280	744	551	551
query77	252	255	203	203
query78	4120	3869	3290	3290
query79	2332	898	589	589
query80	1595	341	283	283
query81	479	157	136	136
query82	625	129	101	101
query83	271	207	192	192
query84	292	113	89	89
query85	793	368	294	294
query86	387	178	181	178
query87	1042	1011	927	927
query88	2800	2107	2159	2107
query89	291	196	176	176
query90	1997	134	133	133
query91	134	127	102	102
query92	82	73	71	71
query93	1566	1149	678	678
query94	632	265	206	206
query95	530	266	218	218
query96	745	573	269	269
query97	1099	1142	1059	1059
query98	160	139	137	137
query99	421	347	317	317
Total cold run time: 178181 ms
Total hot run time: 83196 ms

@hello-stephen

Copy link
Copy Markdown
Contributor
ClickBench: Total hot run time: 14.87 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit d11010bbd679570c048aa4e2dba5a88d512fdbd0, data reload: false

query1	0.01	0.00	0.01
query2	0.07	0.04	0.03
query3	0.24	0.11	0.11
query4	1.62	0.10	0.10
query5	0.18	0.15	0.15
query6	1.28	0.68	0.70
query7	0.03	0.00	0.00
query8	0.05	0.04	0.03
query9	0.28	0.21	0.22
query10	0.36	0.35	0.35
query11	0.17	0.12	0.11
query12	0.14	0.12	0.12
query13	0.32	0.31	0.31
query14	0.46	0.45	0.46
query15	0.37	0.36	0.35
query16	0.22	0.22	0.23
query17	0.70	0.70	0.71
query18	0.18	0.16	0.16
query19	1.17	1.20	1.24
query20	0.01	0.01	0.01
query21	15.43	0.19	0.13
query22	5.02	0.04	0.04
query23	16.24	0.25	0.10
query24	2.99	0.33	0.23
query25	0.10	0.04	0.03
query26	0.75	0.17	0.12
query27	0.03	0.03	0.03
query28	3.61	0.58	0.27
query29	12.45	3.18	2.60
query30	0.25	0.12	0.12
query31	2.76	0.37	0.18
query32	3.52	0.32	0.24
query33	1.50	1.40	1.59
query34	15.40	2.17	1.78
query35	1.80	1.79	1.78
query36	0.46	0.30	0.30
query37	0.06	0.04	0.04
query38	0.04	0.03	0.03
query39	0.03	0.03	0.02
query40	0.12	0.07	0.07
query41	0.07	0.03	0.02
query42	0.04	0.03	0.02
query43	0.04	0.03	0.03
Total cold run time: 90.57 s
Total hot run time: 14.87 s

Gabriel39 added a commit to Gabriel39/incubator-doris that referenced this pull request Sep 6, 2026
### What problem does this PR solve?

Issue Number: None

Related PR: apache#67545

Problem Summary: Restored DLF catalogs did not keep metastore and OSS credential aliases aligned, could reuse stale Paimon DLF clients across catalog configurations, omitted endpoint-derived OSS regions, leaked catalog-owned resources, exposed non-Iceberg tables, dropped namespace metadata, skipped connectivity checks, and lost legacy error contracts. This change aligns DLF storage binding, isolates client pools with a configuration fingerprint, restores Iceberg-compatible metadata and lifecycle behavior, rejects unsupported DLF table creation before remote access, and adds regression coverage.

### Release note

Improve Iceberg and Paimon DLF catalog compatibility, validation, metadata listing, and resource cleanup.

### Check List (For Author)

- Test: Regression test and Unit Test
    - Ran test_dlf_catalog locally in generated-output and comparison modes.
    - Ran 209 focused FE unit tests with zero failures or errors.
    - Ran Connector SPI tests and packaged Iceberg/Paimon connectors with Maven install.
    - Ran the full FE build and FE Checkstyle validation.
- Behavior changed: Yes. DLF aliases, endpoint inference, connection checks, read-only DDL validation, mixed-format filtering, namespace metadata, pool isolation, and cleanup now follow the supported contracts.
- Does this need documentation: No
@Gabriel39

Copy link
Copy Markdown
Contributor Author

run buildall

@Gabriel39

Copy link
Copy Markdown
Contributor Author

/review

@hello-stephen

Copy link
Copy Markdown
Contributor
TPC-H: Total hot run time: 16648 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit 02284619614253ec8855f1e0bc58a5c1ba636ea2, data reload: false

------ Round 1 ----------------------------------
============================================
q1	17630	2995	2965	2965
q2	2098	254	241	241
q3	10214	870	497	497
q4	4669	254	203	203
q5	7672	562	383	383
q6	136	115	95	95
q7	519	503	389	389
q8	9250	912	911	911
q9	3451	2357	2361	2357
q10	6527	820	696	696
q11	390	192	183	183
q12	608	259	196	196
q13	18140	1534	1145	1145
q14	157	147	140	140
q15	q16	440	395	363	363
q17	1355	898	775	775
q18	3092	2234	2212	2212
q19	1261	854	813	813
q20	388	288	195	195
q21	5560	1659	1860	1659
q22	328	259	230	230
Total cold run time: 93885 ms
Total hot run time: 16648 ms

----- Round 2, with runtime_filter_mode=off -----
============================================
q1	3342	3271	3289	3271
q2	493	423	376	376
q3	2166	2317	2163	2163
q4	1173	1156	884	884
q5	2165	2077	2051	2051
q6	161	121	86	86
q7	1005	904	865	865
q8	1569	1388	1394	1388
q9	3088	3064	3059	3059
q10	1813	1779	1606	1606
q11	357	268	255	255
q12	443	431	350	350
q13	1466	1529	1147	1147
q14	164	168	167	167
q15	q16	402	398	357	357
q17	3608	3262	3239	3239
q18	4774	4392	4654	4392
q19	867	792	785	785
q20	1136	957	820	820
q21	3751	3015	3204	3015
q22	396	351	321	321
Total cold run time: 34339 ms
Total hot run time: 30597 ms

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found nine distinct issues on head 02284619614253ec8855f1e0bc58a5c1ba636ea2 and am requesting changes. The highest-impact failures are provider-independent disclosure of a newly accepted session-token alias and Paimon's no-op explicit DLF connectivity test. The remaining issues affect rooted DLF namespaces, namespace-scale table listing, OSS-HDFS endpoint normalization, Iceberg base catalog state, public/VPC endpoint parity, CREATE/IF NOT EXISTS ordering, and directory-plugin classloader isolation.

Critical checkpoint conclusions:

  • Goal and proof: The patch substantially restores Iceberg and Paimon DLF provider registration, clients, storage binding, packaging, read-side catalog access, connection validation, and unsupported catalog DDL handling. The ordinary paths have focused unit/regression coverage, but the nine inline counterexamples show the end-to-end goal is not yet complete.
  • Scope and focus: All 47 changed paths are cohesive with DLF restoration or the required connector SPI, shade/assembly, and test infrastructure. The generic provider preflight is the broadest change and accounts for the two framework-level findings.
  • Concurrency: Iceberg catalog publication, generation leases, checked-out DLF clients, cache eviction, ALTER reset, and concurrent close were traced. Existing synchronization and retirement/drain behavior prevent a distinct race, deadlock, lock-order, or use-after-close issue.
  • Lifecycle and static state: FileIO, catalog, cached client pools, individual clients, metrics reporter, authentication scope, and TCCL were followed through initialization, partial failure, reset, and close. Partial-construction cleanup remains covered by the existing review thread; the new defects are dropped base state and an unpinned provider callback, not a separate lifetime race. Paimon's library-owned static cache is identity-scoped and expiry-closed.
  • Configuration and dynamic changes: Legacy/canonical credentials, STS, endpoint/region/public selection, OSS versus OSS-HDFS, arbitrary Iceberg options, raw-map replay, and ALTER recreation were checked. These are catalog-lifecycle properties rather than live process settings. The remaining configuration defects are the rooted-namespace mapping, degraded secret masking, endpoint conversion, lost base options, and boolean-parser mismatch.
  • Compatibility: The default SPI method, frozen surface, API-major 6-to-7 transition, and plugin manifests are aligned; no journal, storage, Thrift, or FE/BE wire format changes are present. The remaining compatibility issue is that a compatible directory provider's new callback runs outside its defining TCCL.
  • Parallel paths: Iceberg/Paimon, native OSS/OSS-HDFS, endpoint/region, static/session credentials, loaded/degraded providers, root/no-root namespaces, CREATE/CTAS/IF NOT EXISTS, and built-in/directory plugins were reviewed separately. Their residual asymmetries are represented by the inline findings or hard-fenced existing threads.
  • Conditional checks: Flavor/provider gates and normal DLF rejection are understandable. The unsound branches are the case-sensitive endpoint conversion, inconsistent boolean parsing, and branch-insensitive CREATE preflight ordering.
  • Test coverage: Tests cover normal aliases, STS propagation, lowercase endpoints, literal booleans, provider dispatch, API/version surfaces, pool identity, mixed-format filtering, namespace errors, close behavior, loaded-provider masking, direct CREATE rejection, and Iceberg connection failure. Missing counterexamples map directly to the nine findings: rooted namespaces, large mixed namespaces, degraded masking, mixed-case OSS-HDFS, Paimon test_connection=true, custom base properties, nonliteral truthy values, CTAS/IF NOT EXISTS ordering, and a directory-provider CREATE callback.
  • Test results: I did not run builds or tests because this review runner explicitly prohibits them. Static inspection found the checked-in generated regression oracle deterministic and consistent. At the final live check, style, license, secret, dependency, and change-detection checks passed; FE UT, compile, and performance were still pending.
  • Error handling and observability: DLF interruptions restore the flag; remote construction/probe failures retain causes and side-specific context; close aggregates failures. Remaining wrong outcomes are the empty rooted catalog, false Paimon connectivity success, wrong CREATE/no-op ordering, and directory-helper error, all covered inline. No additional metric was substantiated.
  • Transactions and persistence: Catalog properties continue through the existing raw-property journal/replay and connector reset flow; no new EditLog or transaction protocol is introduced. The degraded persisted-property display issue is called out inline.
  • Data writes and modification: DLF catalog/namespace DDL remains unsupported and no new Doris transaction format is added. A final hypothesis that generic existing-table DML violated this contract was dismissed: the exact pre-refactor DLF implementation already used writable HiveTableOperations, installed the generic Iceberg transaction manager, and exposed the same sinks, so those commits are restored behavior rather than a new regression. The remaining mutation-adjacent defect is the branch-aware CREATE/IF NOT EXISTS ordering.
  • FE/BE variables: No new cross-process field exists. Existing bound storage maps carry endpoint, credentials, token, and test location; the two remaining route inconsistencies are described inline.
  • Performance and memory: Lazy construction and pooling are appropriate. The namespace-wide full-object DLF batch is the only substantiated new scale/peak-allocation issue; no additional hot-lock, retry amplification, or per-row cost survived review.
  • Other/security: SECURITY.md and the repository threat model were applied. The provider-independent STS-token display path is the only additional security-sensitive issue; no authentication, authorization, tenancy, or unsafe-network-boundary finding survived. This Java-only diff has no BE nullable-column, allocator, cross-TU, or memory-order checkpoint.
  • User focus: No additional review focus was supplied; the complete PR was reviewed.
  • Review completion: Complete after three rounds of normal and separate risk-focused review. Every candidate is accepted here, hard-duplicate-fenced by a live thread, or dismissed with concrete code/history evidence; no suspicious point remains unresolved.

@hello-stephen

Copy link
Copy Markdown
Contributor
TPC-DS: Total hot run time: 81267 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit 02284619614253ec8855f1e0bc58a5c1ba636ea2, data reload: false

query5	4273	407	332	332
query6	386	141	128	128
query7	4958	417	233	233
query8	290	123	112	112
query9	8671	2840	2856	2840
query10	390	214	176	176
query11	5405	1040	938	938
query12	120	69	69	69
query13	1189	465	319	319
query14	6118	2153	2058	2058
query14_1	1952	1938	1916	1916
query15	169	118	113	113
query16	907	372	312	312
query17	791	453	374	374
query18	2331	334	243	243
query19	168	141	109	109
query20	73	66	69	66
query21	222	98	86	86
query22	5334	5459	5130	5130
query23	6692	5977	5882	5882
query23_1	5946	5992	6105	5992
query24	7273	1077	759	759
query24_1	765	782	762	762
query25	431	316	253	253
query26	1239	232	130	130
query27	2775	394	252	252
query28	4713	1520	1493	1493
query29	945	437	357	357
query30	257	155	130	130
query31	829	397	335	335
query32	129	74	78	74
query33	475	235	180	180
query34	994	801	483	483
query35	409	400	331	331
query36	578	550	554	550
query37	121	80	72	72
query38	996	857	825	825
query39	488	477	487	477
query39_1	484	464	473	464
query40	207	93	78	78
query41	60	57	55	55
query42	75	82	78	78
query43	237	242	211	211
query44	1009	543	551	543
query45	110	112	97	97
query46	771	826	519	519
query47	766	768	729	729
query48	304	299	240	240
query49	586	237	182	182
query50	738	257	195	195
query51	8035	8070	8013	8013
query52	65	70	58	58
query53	185	192	141	141
query54	223	172	152	152
query55	72	63	53	53
query56	190	166	169	166
query57	674	656	651	651
query58	192	173	236	173
query59	1216	1217	1081	1081
query60	226	185	168	168
query61	108	115	118	115
query62	382	202	176	176
query63	165	142	138	138
query64	2704	678	620	620
query65	1591	1582	1579	1579
query66	1879	269	204	204
query67	9880	9583	9565	9565
query68	2747	1211	739	739
query69	341	222	210	210
query70	656	594	626	594
query71	257	182	164	164
query72	2314	1743	1574	1574
query73	697	561	362	362
query74	1572	1226	1151	1151
query75	1172	1111	957	957
query76	2292	722	535	535
query77	255	260	216	216
query78	3893	3685	3173	3173
query79	2907	851	584	584
query80	1587	323	273	273
query81	496	152	130	130
query82	622	129	91	91
query83	282	204	190	190
query84	303	111	91	91
query85	825	358	304	304
query86	395	168	167	167
query87	1022	952	890	890
query88	2783	2098	2122	2098
query89	282	196	168	168
query90	1927	132	129	129
query91	139	118	99	99
query92	79	73	67	67
query93	1460	1091	631	631
query94	657	279	211	211
query95	529	264	291	264
query96	833	558	232	232
query97	1012	1035	990	990
query98	172	133	133	133
query99	425	338	309	309
Total cold run time: 177265 ms
Total hot run time: 81267 ms

@hello-stephen

Copy link
Copy Markdown
Contributor
ClickBench: Total hot run time: 14.58 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 02284619614253ec8855f1e0bc58a5c1ba636ea2, data reload: false

query1	0.01	0.00	0.00
query2	0.07	0.03	0.03
query3	0.25	0.09	0.10
query4	1.60	0.10	0.10
query5	0.17	0.16	0.16
query6	1.26	0.72	0.68
query7	0.04	0.01	0.00
query8	0.04	0.03	0.02
query9	0.29	0.22	0.21
query10	0.34	0.35	0.33
query11	0.17	0.11	0.11
query12	0.15	0.13	0.12
query13	0.31	0.31	0.30
query14	0.45	0.45	0.45
query15	0.36	0.33	0.34
query16	0.23	0.21	0.21
query17	0.73	0.75	0.68
query18	0.17	0.18	0.17
query19	1.15	1.14	1.20
query20	0.02	0.01	0.01
query21	15.42	0.17	0.12
query22	5.08	0.04	0.04
query23	16.17	0.25	0.10
query24	3.01	0.32	0.23
query25	0.11	0.04	0.04
query26	0.76	0.16	0.13
query27	0.03	0.03	0.03
query28	3.62	0.55	0.26
query29	12.50	3.25	2.55
query30	0.26	0.10	0.11
query31	2.76	0.39	0.18
query32	3.50	0.32	0.24
query33	1.41	1.53	1.46
query34	15.38	2.19	1.76
query35	1.72	1.73	1.69
query36	0.45	0.28	0.29
query37	0.06	0.04	0.04
query38	0.04	0.03	0.03
query39	0.03	0.02	0.02
query40	0.11	0.07	0.07
query41	0.08	0.03	0.03
query42	0.04	0.02	0.02
query43	0.03	0.03	0.02
Total cold run time: 90.38 s
Total hot run time: 14.58 s

@hello-stephen

Copy link
Copy Markdown
Contributor

FE UT Coverage Report

Increment line coverage 50.00% (3/6) 🎉
Increment coverage report
Complete coverage report

@hello-stephen

Copy link
Copy Markdown
Contributor

FE Regression Coverage Report

Increment line coverage 100.00% (6/6) 🎉
Increment coverage report
Complete coverage report

Gabriel39 added a commit to Gabriel39/incubator-doris that referenced this pull request Sep 6, 2026
### What problem does this PR solve?

Issue Number: None

Related PR: apache#67545

Problem Summary: Follow-up review found that DLF table listing still needed bounded metadata filtering, Iceberg base catalog properties were not retained, one token alias was not masked statically, public-endpoint boolean parsing diverged between metadata and storage, Paimon connectivity checks did not exercise DLF and storage, mixed-case DLF OSS-HDFS endpoints were misconverted, and CREATE TABLE preflight ordering and plugin classloading were incomplete. This change fixes those contracts and preserves IF NOT EXISTS no-op behavior.

### Release note

Complete DLF validation, connectivity, metadata listing, credential masking, and CREATE TABLE compatibility for Iceberg and Paimon.

### Check List (For Author)

- Test: Regression test and Unit Test
    - Ran the focused Iceberg, Paimon, filesystem, plugin, DDL-routing, and CTAS unit tests.
    - Ran test_dlf_catalog locally: 1 suite, 0 failed, 0 fatal.
    - Ran Maven install for Iceberg and Paimon connectors.
    - Ran the full FE build and FE Checkstyle validation.
- Behavior changed: Yes. DLF connection validation, metadata batching, endpoint parsing, masking, and DDL preflight now enforce the supported contracts.
- Does this need documentation: No
@Gabriel39

Copy link
Copy Markdown
Contributor Author

run buildall

@Gabriel39

Copy link
Copy Markdown
Contributor Author

/review

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review status: changes requested on exact head 05a951692df6e46c379e7eb8dd92a9c5bf993bc2.

New finding:

  • P1: Paimon DLF now accepts an OSS-HDFS-only binding, but the default native reader cannot route ordinary oss://bucket/... warehouse, data, or deletion-vector paths to it. A separate inline comment is attached at PaimonConnector.java:494.

Existing exact-head threads remain applicable, so I did not duplicate them inline: production Paimon CREATE validation still skips both storage legs; Iceberg CREATE validation still skips its BE probe; and DLF catalog construction can still strand FileIO on a client-pool constructor failure.

Critical checkpoint conclusions:

  1. Goal and proof: The change substantially restores DLF metadata, property, packaging, and scan support, but does not complete the goal because ordinary Paimon DLF-on-OSS-HDFS native reads fail before I/O. The added unit and p0 tests do not exercise that real adapter-selection seam.
  2. Scope and clarity: The patch is broad because it restores two connector stacks and packaging, but the changes are internally focused and generally follow existing abstractions. The accepted routing condition is the material clarity/correctness exception.
  3. Concurrency: Lazy catalog publication uses synchronized/volatile state; Iceberg resource leases retain active generations; client pools and filesystem caches use their established concurrency controls. I found no changed lock-order or deadlock defect, and setup work is not added to scan loops.
  4. Lifecycle: Connector replacement, cache retirement, checked-out clients, and normal close are covered. The pre-publication FileIO cleanup gap remains, but is already covered by the live partial-initialization thread. No C++ cross-TU static initialization is involved.
  5. Configuration: The new keys are catalog properties rather than dynamically reloadable process configuration. CREATE, ALTER, and replay re-enter the binders; changed identities separate catalog/client generations. No restart-sensitive dynamic-config issue was found.
  6. Compatibility: The ConnectorProvider surface change is paired with API major 7, surface-baseline updates, manifest stamping, and fail-closed version gating. No storage-format or FE-BE wire-format change is introduced; incompatible external plugins are rejected explicitly.
  7. Parallel paths: Iceberg/Paimon, FE/BE probes, native/JNI scans, and OSS/OSS-HDFS were traced. The Paimon OSS-HDFS native path is the new P1; the two production probe omissions are already live-thread duplicates.
  8. Conditional logic: CREATE/CTAS/IF NOT EXISTS ordering and provider TCCL conditions are documented and preserve no-op/race behavior. hasDlfCompatibleStorage accepts OSS-HDFS without ensuring that plain OSS URIs can select that binding, which is the inline issue.
  9. Test coverage: Unit tests cover aliases, endpoint derivation, TCCL, pool identity, DDL rejection, lifecycle, and masking; remote suites cover real DLF and native/JNI reads. Missing real lightweight-validation contexts and an OSS-HDFS-only plain-URI oracle leave the known probe gaps and new P1 unproved.
  10. Test results: The modified regression output is consistent with the corresponding negative and masking queries. No incorrect handwritten expectation was found.
  11. Observability: Existing exceptions retain catalog/location context and the routing failure names the unresolved schema. No new hot INFO logging or critical metric requirement was identified.
  12. Transactions and persistence: CREATE/ALTER/replay and IF NOT EXISTS race ordering were traced. ALTER validates a detached candidate before journaling, and this patch adds no new edit-log payload or failover-sensitive transaction state.
  13. Data writes: DLF catalog-structure writes remain rejected before remote work; CTAS executes its sink only when this statement owns table creation. Existing-table Iceberg commit behavior is preserved, with no new atomicity or crash-leak issue found beyond the live lifecycle thread.
  14. FE-BE propagation: Storage credentials/configuration continue through the existing typed maps and thrift paths; no new wire variable is added. The skipped BE validation legs are already covered by existing threads.
  15. Performance: Configuration hashing and catalog setup are bounded, DLF table listing is chunked to 100 descriptors, and no new CPU/memory hot-path regression was found. The accepted issue is correctness, not performance.
  16. Other issues: API/shade/ServiceLoader closure, masking, authentication, TCCL restoration, namespace/error mapping, and security boundaries were rechecked. No additional distinct finding survived duplicate fencing; this is a correctness/availability review, not a security-vulnerability report.

Convergence: Round 2 completed with three normal full reviews and a separate adversarial risk pass, all ending NO_NEW_VALUABLE_FINDINGS beyond the accepted/duplicate-fenced records. No additional user focus was supplied, so the full PR was reviewed.

Validation note: static review only, as required by the runner prompt; no local builds or tests were run. At submission time, style, license, secrets, coverage, BE UT, and Cloud UT were passing; compile, FE UT, performance, and the code-review check were still pending.

@hello-stephen

Copy link
Copy Markdown
Contributor
TPC-H: Total hot run time: 16748 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit 05a951692df6e46c379e7eb8dd92a9c5bf993bc2, data reload: false

------ Round 1 ----------------------------------
============================================
q1	17574	3056	3078	3056
q2	2137	266	220	220
q3	10198	879	502	502
q4	4665	247	198	198
q5	7685	564	381	381
q6	135	114	94	94
q7	519	483	391	391
q8	9237	925	893	893
q9	3383	2362	2352	2352
q10	6492	925	709	709
q11	389	199	181	181
q12	610	259	194	194
q13	18118	1528	1176	1176
q14	158	155	139	139
q15	q16	451	397	364	364
q17	1301	886	728	728
q18	3010	2260	2209	2209
q19	1294	930	794	794
q20	377	275	198	198
q21	5636	1750	1929	1750
q22	323	269	219	219
Total cold run time: 93692 ms
Total hot run time: 16748 ms

----- Round 2, with runtime_filter_mode=off -----
============================================
q1	3464	3390	3396	3390
q2	514	387	390	387
q3	2213	2624	2162	2162
q4	1170	1165	901	901
q5	2161	2095	2080	2080
q6	163	127	84	84
q7	1029	923	870	870
q8	1605	1414	1392	1392
q9	3133	3098	3070	3070
q10	1854	1784	1597	1597
q11	355	267	250	250
q12	452	428	347	347
q13	1482	1532	1173	1173
q14	173	175	154	154
q15	q16	395	391	360	360
q17	3651	3372	3241	3241
q18	4744	4332	4731	4332
q19	850	891	875	875
q20	1003	940	823	823
q21	3755	3035	3171	3035
q22	393	340	325	325
Total cold run time: 34559 ms
Total hot run time: 30848 ms

@hello-stephen

Copy link
Copy Markdown
Contributor
TPC-DS: Total hot run time: 81438 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit 05a951692df6e46c379e7eb8dd92a9c5bf993bc2, data reload: false

query5	4370	408	329	329
query6	385	132	119	119
query7	4977	407	238	238
query8	294	126	112	112
query9	8706	2859	2872	2859
query10	430	216	201	201
query11	5361	1028	896	896
query12	127	70	72	70
query13	1198	439	331	331
query14	6082	2182	2069	2069
query14_1	1959	1947	1932	1932
query15	176	116	109	109
query16	912	364	352	352
query17	793	457	368	368
query18	2332	340	251	251
query19	162	139	108	108
query20	72	70	70	70
query21	209	99	88	88
query22	5515	5236	5353	5236
query23	6574	6214	6099	6099
query23_1	6206	5982	6213	5982
query24	7281	1066	774	774
query24_1	748	796	754	754
query25	433	299	262	262
query26	1233	242	128	128
query27	2777	414	265	265
query28	4676	1485	1485	1485
query29	937	442	354	354
query30	257	156	132	132
query31	812	394	323	323
query32	134	76	78	76
query33	465	235	173	173
query34	973	853	495	495
query35	396	406	361	361
query36	561	565	549	549
query37	117	78	73	73
query38	999	837	808	808
query39	470	491	458	458
query39_1	456	463	439	439
query40	201	87	79	79
query41	54	57	52	52
query42	78	69	68	68
query43	239	240	212	212
query44	998	536	549	536
query45	120	107	96	96
query46	763	792	526	526
query47	751	746	697	697
query48	300	315	213	213
query49	529	235	205	205
query50	739	248	195	195
query51	8111	8067	7987	7987
query52	67	68	65	65
query53	184	196	150	150
query54	215	176	156	156
query55	68	58	56	56
query56	194	214	171	171
query57	679	655	655	655
query58	186	159	199	159
query59	1235	1235	1088	1088
query60	233	178	162	162
query61	122	123	107	107
query62	351	202	184	184
query63	170	153	148	148
query64	2790	656	586	586
query65	1618	1601	1596	1596
query66	1848	263	211	211
query67	9835	9505	9651	9505
query68	2739	1147	757	757
query69	337	214	197	197
query70	659	629	613	613
query71	250	172	167	167
query72	2292	1736	1569	1569
query73	659	609	361	361
query74	1610	1223	1131	1131
query75	1152	1083	954	954
query76	2303	729	553	553
query77	253	269	201	201
query78	3909	3600	3063	3063
query79	2471	811	581	581
query80	1602	337	267	267
query81	488	160	129	129
query82	621	125	93	93
query83	280	220	202	202
query84	286	114	90	90
query85	767	355	291	291
query86	384	179	167	167
query87	1025	956	888	888
query88	2793	2094	2085	2085
query89	292	194	173	173
query90	1987	124	127	124
query91	129	126	101	101
query92	77	70	70	70
query93	1452	1038	707	707
query94	645	248	230	230
query95	554	323	219	219
query96	773	546	265	265
query97	1038	1033	997	997
query98	163	136	133	133
query99	418	337	306	306
Total cold run time: 177105 ms
Total hot run time: 81438 ms

@hello-stephen

Copy link
Copy Markdown
Contributor
ClickBench: Total hot run time: 14.75 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 05a951692df6e46c379e7eb8dd92a9c5bf993bc2, data reload: false

query1	0.01	0.00	0.01
query2	0.08	0.04	0.03
query3	0.24	0.11	0.11
query4	1.60	0.10	0.10
query5	0.19	0.16	0.16
query6	1.25	0.71	0.68
query7	0.03	0.01	0.00
query8	0.04	0.04	0.03
query9	0.29	0.21	0.21
query10	0.35	0.35	0.35
query11	0.16	0.11	0.11
query12	0.15	0.13	0.12
query13	0.33	0.31	0.30
query14	0.45	0.45	0.45
query15	0.35	0.35	0.34
query16	0.22	0.25	0.22
query17	0.68	0.70	0.68
query18	0.19	0.17	0.16
query19	1.17	1.16	1.11
query20	0.01	0.00	0.01
query21	15.43	0.15	0.12
query22	5.09	0.05	0.04
query23	16.18	0.26	0.10
query24	2.96	0.33	0.26
query25	0.11	0.05	0.03
query26	0.85	0.16	0.12
query27	0.04	0.03	0.03
query28	3.73	0.53	0.27
query29	12.47	3.19	2.58
query30	0.25	0.11	0.12
query31	2.76	0.37	0.17
query32	3.52	0.32	0.23
query33	1.32	1.53	1.55
query34	15.40	2.16	1.76
query35	1.74	1.73	1.74
query36	0.46	0.29	0.30
query37	0.06	0.04	0.04
query38	0.04	0.03	0.03
query39	0.03	0.03	0.02
query40	0.11	0.08	0.07
query41	0.08	0.03	0.02
query42	0.04	0.02	0.02
query43	0.03	0.03	0.02
Total cold run time: 90.49 s
Total hot run time: 14.75 s

@hello-stephen

Copy link
Copy Markdown
Contributor

FE UT Coverage Report

Increment line coverage 38.71% (12/31) 🎉
Increment coverage report
Complete coverage report

@hello-stephen

Copy link
Copy Markdown
Contributor

FE Regression Coverage Report

Increment line coverage 87.10% (27/31) 🎉
Increment coverage report
Complete coverage report

Gabriel39 added a commit to Gabriel39/incubator-doris that referenced this pull request Sep 7, 2026
### What problem does this PR solve?

Issue Number: None

Related PR: apache#67545

Problem Summary: In an OSS-HDFS-only catalog, plain oss:// bucket paths were classified as native OSS because the path itself did not contain an oss-dls endpoint. Native OSS was intentionally absent from the catalog adapter map, so URI normalization failed before scans; retaining only the adapter selection would also lose the Jindo/HDFS identity at the connector string boundary. Fall back to the selected OSS-HDFS adapter when native OSS is absent and embed its configured endpoint in normalized plain bucket URIs so data and deletion-vector paths remain FILE_HDFS downstream.

### Release note

Fix DLF-backed OSS-HDFS scans for plain oss:// bucket paths.

### Check List (For Author)

- Test: Unit Test and Regression test
    - DefaultConnectorContextNormalizeUriTest and OssHdfsPropertiesTest
    - external_table_p0/test_dlf_catalog
- Behavior changed: Yes. Plain oss:// paths in OSS-HDFS-only catalogs are normalized through Jindo and routed as FILE_HDFS.
- Does this need documentation: No
@Gabriel39

Copy link
Copy Markdown
Contributor Author

run buildall

@Gabriel39

Copy link
Copy Markdown
Contributor Author

/review

@github-actions

github-actions Bot commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Codex automated review failed and did not complete.

Error: Selected model is at capacity. Please try a different model.
Workflow run: https://github.com/apache/doris/actions/runs/34080139544

Please inspect the workflow logs and rerun the review after the underlying issue is resolved.

@Gabriel39

Copy link
Copy Markdown
Contributor Author

/review

@hello-stephen

Copy link
Copy Markdown
Contributor

FE UT Coverage Report

Increment line coverage 44.12% (15/34) 🎉
Increment coverage report
Complete coverage report

@github-actions

github-actions Bot commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Codex automated review failed and did not complete.

Error: Review step was failure (possibly timeout or cancelled)
Workflow run: https://github.com/apache/doris/actions/runs/34084341514

Please inspect the workflow logs and rerun the review after the underlying issue is resolved.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Request changes: three distinct storage-routing regressions remain on this head: malformed OSS-HDFS normalization for native-qualified paths (P1), an Iceberg DLF connectivity probe that targets the wrong native-OSS bucket (P1), and mixed-case OSS-HDFS identity loss at BE dispatch (P2). Existing live-thread concerns were treated as duplicate fences and were not reposted.

Critical checkpoint conclusions:

  • Goal and proof: The PR broadly restores DLF provider registration, aliases, Iceberg catalog support, Paimon proxying, and private dependency closures. Unit and P0 coverage exercises the baseline paths, but the three accepted URI shapes are not covered end to end, so the restoration is not yet correct for all supported inputs.
  • Scope: The 63-file change is large but focused on the DLF restoration and its SPI/filesystem/test plumbing. The remaining defects sit at the shared URI and connectivity seams.
  • Concurrency: Iceberg generation/resource tracking, Caffeine client pools, and Paimon's JVM-static pool were traced through concurrent use and retirement. No distinct race, lock-order, or deadlock issue survived; the partial-construction cleanup concern is already covered by live thread 3942659426.
  • Lifecycle: Initialization, statement/table leases, ALTER/DROP generation rotation, eviction, close, and failure cleanup were reviewed. No new lifecycle issue survived beyond existing threads.
  • Configuration and dynamic behavior: Legacy/canonical credentials, token masking, endpoint/region/public-VPC derivation, and ALTER rebinding were checked. No dynamic global configuration was added; catalog regeneration picks up property changes. Existing topology/boolean concerns remain in their live threads.
  • Compatibility: The SPI v7 surface/version gate rejects older providers before use, and both Hive 2 and Hive 3 private shades contain the required relocated DLF/Thrift/Tea closure. No storage-format or new serialized protocol change is introduced.
  • Parallel paths: Iceberg and Paimon data, position/equality-delete and deletion-vector scans, Iceberg writes, and FE/BE connectivity probes were traced. MAIN-1 and MAIN-2 cross several of these paths; MAIN-3 is isolated to the new Iceberg DLF validation probe.
  • Special conditions: Provider priority, OSS versus OSS-HDFS exclusivity, endpoint case/idempotence, CREATE/CTAS, and IF NOT EXISTS paths were reviewed. Remaining preflight/TCCL variants are already covered by live threads 3943032141 and 3943032138.
  • Test coverage: The PR adds broad provider/property/catalog/DDL/connectivity unit tests and a P0 catalog suite. It lacks mixed-case DLS data/delete/write dispatch, native-OSS-qualified OSS-HDFS normalization, and endpoint-qualified native-OSS connectivity cases corresponding to the three findings.
  • Test results: The checked-in .out matches the two single-row SHOW CREATE cases and carries the generator header. Current CI shows COMPILE, FE UT, CheckStyle, Clang Formatter, license, secrets, and dependency review passing; vault_p0 is failing and the other regression groups are still pending. No local build or test was run because the review prompt forbids it.
  • Observability: Probe failures log the catalog and distinguish FE from compute-node failures; no new metric appears necessary. The accepted routing defects can nevertheless surface as misleading access failures after constructing the wrong path/bucket.
  • Transactions and persistence: Catalog replay, property persistence, and ALTER generation behavior use the existing mechanisms; there is no new EditLog or transaction-format change, and no distinct persistence issue was found.
  • Data writes and atomicity: Iceberg commit semantics are unchanged. The routing defects can prevent access before a successful write/commit, but no additional partial-write or atomicity defect was found.
  • FE-BE transmission: No new Thrift field is added. Existing file-type, normalized-location, and backend-property seams are used, but MAIN-1 misclassifies a path and MAIN-2/MAIN-3 send incorrect locations for specific supported forms.
  • Performance: Scan-scoped normalization memoizes adapter construction, listing work is bounded, and no distinct CPU, allocation, or hot-path regression survived review.
  • Error handling: Provider and probe failures propagate as connector failures with context; no ignored Status path was introduced. The accepted bugs are incorrect URI construction/classification rather than swallowed errors.
  • Memory safety and BE nullable handling: No BE code or nullable-column logic changes in this PR; no new tracked-allocation or ownership issue was found.
  • Other issues: The apparent missing-Tea shade closure was disproved against the exact vendor shaded classifier. All other candidates were either dismissed with code evidence or deduplicated against live threads.

User focus: No additional review focus was specified; the full PR was reviewed.

Review completion: capped/incomplete after the maximum three rounds because MAIN-3 was newly accepted in Round 3. Every currently known candidate has a final disposition and the three accepted issues are reported here, but the review contract does not permit a fourth convergence round.

Issue Number: None

Related PR: apache#67545

Problem Summary: Restored DLF catalogs did not keep metastore and OSS credential aliases aligned, could reuse stale Paimon DLF clients across catalog configurations, omitted endpoint-derived OSS regions, leaked catalog-owned resources, exposed non-Iceberg tables, dropped namespace metadata, skipped connectivity checks, and lost legacy error contracts. This change aligns DLF storage binding, isolates client pools with a configuration fingerprint, restores Iceberg-compatible metadata and lifecycle behavior, rejects unsupported DLF table creation before remote access, and adds regression coverage.

Improve Iceberg and Paimon DLF catalog compatibility, validation, metadata listing, and resource cleanup.

- Test: Regression test and Unit Test
    - Ran test_dlf_catalog locally in generated-output and comparison modes.
    - Ran 209 focused FE unit tests with zero failures or errors.
    - Ran Connector SPI tests and packaged Iceberg/Paimon connectors with Maven install.
    - Ran the full FE build and FE Checkstyle validation.
- Behavior changed: Yes. DLF aliases, endpoint inference, connection checks, read-only DDL validation, mixed-format filtering, namespace metadata, pool isolation, and cleanup now follow the supported contracts.
- Does this need documentation: No
### What problem does this PR solve?

Issue Number: None

Related PR: apache#67545

Problem Summary: Follow-up review found that DLF table listing still needed bounded metadata filtering, Iceberg base catalog properties were not retained, one token alias was not masked statically, public-endpoint boolean parsing diverged between metadata and storage, Paimon connectivity checks did not exercise DLF and storage, mixed-case DLF OSS-HDFS endpoints were misconverted, and CREATE TABLE preflight ordering and plugin classloading were incomplete. This change fixes those contracts and preserves IF NOT EXISTS no-op behavior.

### Release note

Complete DLF validation, connectivity, metadata listing, credential masking, and CREATE TABLE compatibility for Iceberg and Paimon.

### Check List (For Author)

- Test: Regression test and Unit Test
    - Ran the focused Iceberg, Paimon, filesystem, plugin, DDL-routing, and CTAS unit tests.
    - Ran test_dlf_catalog locally: 1 suite, 0 failed, 0 fatal.
    - Ran Maven install for Iceberg and Paimon connectors.
    - Ran the full FE build and FE Checkstyle validation.
- Behavior changed: Yes. DLF connection validation, metadata batching, endpoint parsing, masking, and DDL preflight now enforce the supported contracts.
- Does this need documentation: No
### What problem does this PR solve?

Issue Number: None

Related PR: apache#67545

Problem Summary: In an OSS-HDFS-only catalog, plain oss:// bucket paths were classified as native OSS because the path itself did not contain an oss-dls endpoint. Native OSS was intentionally absent from the catalog adapter map, so URI normalization failed before scans; retaining only the adapter selection would also lose the Jindo/HDFS identity at the connector string boundary. Fall back to the selected OSS-HDFS adapter when native OSS is absent and embed its configured endpoint in normalized plain bucket URIs so data and deletion-vector paths remain FILE_HDFS downstream.

### Release note

Fix DLF-backed OSS-HDFS scans for plain oss:// bucket paths.

### Check List (For Author)

- Test: Unit Test and Regression test
    - DefaultConnectorContextNormalizeUriTest and OssHdfsPropertiesTest
    - external_table_p0/test_dlf_catalog
- Behavior changed: Yes. Plain oss:// paths in OSS-HDFS-only catalogs are normalized through Jindo and routed as FILE_HDFS.
- Does this need documentation: No
### What problem does this PR solve?

Issue Number: None

Related PR: apache#67545

Problem Summary: OSS-HDFS normalization appended the selected DLS endpoint to already qualified native OSS authorities, producing an invalid bucket name. It also preserved mixed-case DLS authorities that downstream file-type dispatch did not recognize, while the Iceberg DLF connectivity probe bypassed storage normalization. Extract the real bucket from qualified OSS authorities, rebuild the canonical DLS authority through the selected storage binding, and use that binding for Iceberg probe locations.

### Release note

Normalize qualified native OSS and OSS-HDFS paths before DLF scan, write, and connectivity dispatch.

### Check List (For Author)

- Test: Unit Test and Regression test
    - OssHdfsPropertiesTest, DefaultConnectorContextNormalizeUriTest, and IcebergConnectorTestConnectionTest
    - external_table_p0/test_dlf_catalog
- Behavior changed: Yes. Qualified OSS authorities are canonicalized through the selected OSS-HDFS endpoint, including mixed-case inputs.
- Does this need documentation: No
@Gabriel39
Gabriel39 force-pushed the fix/restore-dlf-catalog-support branch from 5993f0e to 272bed6 Compare September 7, 2026 06:58
@Gabriel39

Copy link
Copy Markdown
Contributor Author

run buildall

@Gabriel39

Copy link
Copy Markdown
Contributor Author

/review

@Gabriel39 Gabriel39 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed the qualified OSS normalization and DLF connectivity probe findings.

@github-actions

github-actions Bot commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Codex automated review failed and did not complete.

Error: Your access token could not be refreshed because your refresh token was already used. Please log out and sign in again.
Workflow run: https://github.com/apache/doris/actions/runs/34093255014

Please inspect the workflow logs and rerun the review after the underlying issue is resolved.

@hello-stephen

Copy link
Copy Markdown
Contributor
TPC-H: Total hot run time: 16706 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpch-tools
Tpch sf100 test result on commit 272bed6882024bc3d591bba6826762f2d3576617, data reload: false

------ Round 1 ----------------------------------
============================================
q1	17555	3104	3088	3088
q2	2106	279	229	229
q3	10209	884	512	512
q4	4664	245	200	200
q5	7686	588	388	388
q6	141	115	93	93
q7	524	504	386	386
q8	9234	834	932	834
q9	3437	2381	2347	2347
q10	6499	857	713	713
q11	405	195	180	180
q12	618	256	200	200
q13	18112	1525	1172	1172
q14	164	153	141	141
q15	q16	453	401	362	362
q17	1376	885	811	811
q18	3102	2268	2208	2208
q19	1275	847	784	784
q20	374	277	203	203
q21	5604	1630	1879	1630
q22	330	270	225	225
Total cold run time: 93868 ms
Total hot run time: 16706 ms

----- Round 2, with runtime_filter_mode=off -----
============================================
q1	3443	3434	3380	3380
q2	516	425	364	364
q3	2207	2220	2151	2151
q4	1195	1182	910	910
q5	2144	2135	2117	2117
q6	173	117	87	87
q7	1000	970	879	879
q8	1606	1424	1414	1414
q9	3148	3105	3100	3100
q10	1856	1795	1616	1616
q11	363	278	258	258
q12	455	432	341	341
q13	1490	1550	1148	1148
q14	167	168	170	168
q15	q16	398	400	356	356
q17	3585	3294	3242	3242
q18	4823	4393	4749	4393
q19	861	874	881	874
q20	988	964	811	811
q21	3876	3175	3306	3175
q22	399	344	325	325
Total cold run time: 34693 ms
Total hot run time: 31109 ms

@hello-stephen

Copy link
Copy Markdown
Contributor
TPC-DS: Total hot run time: 82402 ms
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/tpcds-tools
TPC-DS sf100 test result on commit 272bed6882024bc3d591bba6826762f2d3576617, data reload: false

query5	4247	416	334	334
query6	377	145	123	123
query7	4960	438	226	226
query8	289	138	118	118
query9	8685	2857	2908	2857
query10	390	225	183	183
query11	5396	1012	918	918
query12	113	69	71	69
query13	1205	446	322	322
query14	6156	2239	2122	2122
query14_1	1989	1989	2000	1989
query15	175	133	117	117
query16	887	376	303	303
query17	794	479	392	392
query18	2345	335	238	238
query19	174	141	121	121
query20	70	75	79	75
query21	212	109	92	92
query22	5316	5441	5378	5378
query23	6677	6182	6070	6070
query23_1	6213	6088	6236	6088
query24	7297	1131	757	757
query24_1	770	791	787	787
query25	438	314	263	263
query26	1217	245	128	128
query27	2776	434	257	257
query28	4695	1509	1492	1492
query29	927	461	361	361
query30	250	155	133	133
query31	814	404	331	331
query32	132	73	90	73
query33	465	227	183	183
query34	972	859	484	484
query35	407	419	357	357
query36	569	571	540	540
query37	127	85	72	72
query38	1010	858	796	796
query39	489	501	462	462
query39_1	482	466	453	453
query40	205	93	79	79
query41	59	57	59	57
query42	74	73	72	72
query43	246	246	213	213
query44	1032	542	556	542
query45	116	110	131	110
query46	807	872	515	515
query47	777	768	693	693
query48	298	308	232	232
query49	526	234	194	194
query50	761	269	199	199
query51	8515	8639	8186	8186
query52	96	71	64	64
query53	202	209	145	145
query54	227	177	170	170
query55	75	60	56	56
query56	191	171	182	171
query57	691	676	639	639
query58	198	163	163	163
query59	1260	1235	1093	1093
query60	238	219	170	170
query61	137	115	139	115
query62	387	201	203	201
query63	175	148	143	143
query64	2638	674	679	674
query65	1651	1580	1559	1559
query66	1768	256	203	203
query67	9767	9700	9603	9603
query68	3027	1205	797	797
query69	355	231	188	188
query70	688	616	626	616
query71	259	181	164	164
query72	2317	1723	1539	1539
query73	652	588	325	325
query74	2005	1233	1132	1132
query75	1176	1092	978	978
query76	2368	753	559	559
query77	264	265	217	217
query78	3869	3664	3222	3222
query79	2808	879	578	578
query80	1589	323	284	284
query81	514	156	134	134
query82	644	122	100	100
query83	275	215	192	192
query84	296	115	88	88
query85	833	363	300	300
query86	468	176	171	171
query87	1010	978	898	898
query88	3011	2106	2133	2106
query89	293	196	176	176
query90	2080	134	129	129
query91	132	116	98	98
query92	94	71	75	71
query93	2051	1063	658	658
query94	650	256	225	225
query95	518	335	239	239
query96	780	594	263	263
query97	1053	1073	983	983
query98	181	135	142	135
query99	418	346	310	310
Total cold run time: 179695 ms
Total hot run time: 82402 ms

@hello-stephen

Copy link
Copy Markdown
Contributor
ClickBench: Total hot run time: 14.55 s
machine: 'aliyun_ecs.c7a.8xlarge_32C64G'
scripts: https://github.com/apache/doris/tree/master/tools/clickbench-tools
ClickBench test result on commit 272bed6882024bc3d591bba6826762f2d3576617, data reload: false

query1	0.00	0.01	0.00
query2	0.08	0.04	0.04
query3	0.25	0.11	0.11
query4	1.60	0.09	0.08
query5	0.19	0.17	0.15
query6	1.26	0.69	0.68
query7	0.03	0.00	0.01
query8	0.04	0.03	0.02
query9	0.28	0.20	0.22
query10	0.36	0.34	0.35
query11	0.17	0.12	0.12
query12	0.16	0.12	0.12
query13	0.31	0.31	0.29
query14	0.45	0.44	0.44
query15	0.37	0.35	0.34
query16	0.23	0.24	0.21
query17	0.67	0.66	0.69
query18	0.16	0.16	0.18
query19	1.21	1.16	1.13
query20	0.01	0.01	0.01
query21	15.45	0.17	0.12
query22	5.07	0.04	0.04
query23	16.17	0.25	0.10
query24	3.03	0.30	0.22
query25	0.09	0.05	0.03
query26	0.82	0.17	0.13
query27	0.04	0.03	0.03
query28	3.58	0.56	0.27
query29	12.48	3.21	2.63
query30	0.25	0.11	0.13
query31	2.76	0.36	0.17
query32	3.55	0.33	0.25
query33	1.35	1.38	1.52
query34	15.40	2.17	1.76
query35	1.75	1.69	1.76
query36	0.45	0.29	0.29
query37	0.06	0.03	0.04
query38	0.05	0.03	0.03
query39	0.04	0.02	0.02
query40	0.12	0.08	0.08
query41	0.08	0.02	0.02
query42	0.03	0.02	0.03
query43	0.03	0.03	0.03
Total cold run time: 90.48 s
Total hot run time: 14.55 s

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants