[fix](fe) Preserve config for replace table binlogs - #66930
Open
goutamadwant wants to merge 1 commit into
Open
Conversation
### What problem does this PR solve? Issue Number: close apache#66571 Related PR: None Problem Summary: With database binlog disabled, a swap=false REPLACE TABLE could skip the table-level binlog after a cold-cache restart because the original table was removed before its configuration was resolved. Capture the original table binlog configuration before replacement, persist it in the operation log, and restore it for live emission, replay, garbage collection, and image recovery. Legacy logs without a snapshot keep their previous behavior. ### Release note Fix missing REPLACE TABLE binlogs when only table-level binlog is enabled and the FE binlog config cache is cold. ### Check List (For Author) - Test: Unit Test - Behavior changed: Yes. REPLACE TABLE now preserves the original table binlog configuration for emission and recovery. - Does this need documentation: No
goutamadwant
requested review from
gavinchou,
luwei16 and
mymeiyi
as code owners
August 19, 2026 06:55
Contributor
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
Open
3 tasks
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 problem does this PR solve?
Issue Number: close #66571
Related PR: None
Problem Summary:
When database-level binlog is disabled and only the original table has binlog enabled, a
swap=falseREPLACE TABLEcan skip its binlog after an FE restart or failover. The original table is removed before a coldBinlogConfigCachecan resolve its configuration.This change captures the original table's
BinlogConfigbefore replacement and persists it inReplaceTableOperationLog. Live emission, follower replay, table-level GC settings, and image recovery use that snapshot. Image recovery pre-processes one existing database region at a time before filtering table dummies, while missing databases and disabled-binlog images remain streaming. Legacy logs without a snapshot retain their previous behavior.Release note
Fix missing
REPLACE TABLEbinlogs when only table-level binlog is enabled and the FE binlog config cache is cold.Check List (For Author)
Test
Behavior changed:
REPLACE TABLEnow preserves the original table's binlog configuration for emission and recovery.Does this need documentation?
Check List (For Reviewer who merge this PR)