branch-4.1: [fix](paimon) Keep write cache coherent and extend coverage - #67023
Merged
yiguolei merged 2 commits intoAug 24, 2026
Merged
Conversation
Contributor
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
Member
Author
|
run buildall |
suxiaogang223
marked this pull request as ready for review
August 21, 2026 08:12
suxiaogang223
force-pushed
the
codex/paimon-write-cases
branch
from
August 21, 2026 11:24
82841f2 to
845476a
Compare
suxiaogang223
force-pushed
the
codex/paimon-write-cases
branch
from
August 21, 2026 11:25
845476a to
2268f86
Compare
Member
Author
|
run buildall |
yiguolei
approved these changes
Aug 24, 2026
This was referenced Aug 31, 2026
suxiaogang223
added a commit
to suxiaogang223/doris
that referenced
this pull request
Sep 3, 2026
### What problem does this PR solve? Issue Number: close apache#65086 Related PR: apache#67023 Problem Summary: Doris and Paimon maintain separate table caches. After a Doris metadata-cache miss, Paimon CachingCatalog could return the same stale table handle, leaving writes planned with outdated bucket, path, or table options. Invalidate the inner Paimon entry before every outer-cache reload and verify the invalidate-before-get ordering. ### Release note Ensure refreshed Paimon writes use current table metadata. ### Check List (For Author) - Test: Unit Test - Added cache reload ordering coverage; FE checkstyle passed. Final compilation and test execution are deferred until all forward-port picks are complete. - Behavior changed: Yes, Paimon table reloads no longer reuse stale inner-cache entries. - Does this need documentation: No
suxiaogang223
added a commit
to suxiaogang223/doris
that referenced
this pull request
Sep 3, 2026
### What problem does this PR solve? Issue Number: close apache#65086 Related PR: apache#65868, apache#66325, apache#67023, apache#67085 Problem Summary: Forward-port the final branch-4.1 Paimon write regression matrix to master, including append and primary-key modes, bucket routing, transactions, schema evolution, row-level DML, Variant V2, snapshot references, writer lifecycle, cache coherence, and stabilized external paths. Generated golden outputs are preserved byte-for-byte from branch-4.1. ### Release note None ### Check List (For Author) - Test: Regression test - Test cases and generated expected outputs were forward-ported; execution is deferred until the final integrated validation. - Behavior changed: No - Does this need documentation: No
suxiaogang223
added a commit
to suxiaogang223/doris
that referenced
this pull request
Sep 3, 2026
### What problem does this PR solve? Issue Number: close apache#65086 Related PR: apache#67023 Problem Summary: The forward-ported Paimon table cache coherence test uses List to record catalog calls but did not import java.util.List, causing FE test compilation to fail. Add the missing import. ### Release note None ### Check List (For Author) - Test: Manual test - Maven checkstyle validation for the Paimon connector - Behavior changed: No - Does this need documentation: No
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
external_table_p0/paimon/writeCachingCatalogbefore reloading it after a Doris cache miss.outfilesWhy
Doris currently has its own Paimon table metacache on top of Paimon's
CachingCatalog. Invalidating only the Doris cache could still make the loader receive a staleTablefrom the underlying Paimon cache. As a result, writes after external metadata changes could continue using outdated bucket, path, or table options.This change keeps the existing Doris cache boundary, documents why both cache layers exist, and makes a Doris cache reload invalidate the corresponding Paimon table entry first.
Testing
source ./custom_env.sh && ./build.sh --fesource ./custom_env.sh && ./run-fe-ut.sh --run org.apache.doris.datasource.paimon.PaimonExternalMetaCacheTest,org.apache.doris.datasource.paimon.PaimonExternalTableTest.outverification after the cache fix:test_paimon_write_bucket_modestest_paimon_write_sequence_grouptest_paimon_write_deletion_vectortest_paimon_write_external_pathsgit diff --check