bobhan1 opened a new pull request, #69719:
URL: https://github.com/apache/doris/pull/69719

   ### What problem does this PR solve?
   
   Cloud MOW sequence tables can lose a delete-sign row during base compaction 
before delayed lower-sequence writes arrive. For example, removing a 
sequence=100 delete sign immediately allows a later sequence=90 write to enter.
   
   Add the mutable, nonnegative BE configuration 
`sequence_delete_sign_retention_version_gap` for cloud MOW tables with a 
row-level sequence column. Default `0` preserves immediate pruning.
   
   - Snapshot the local CloudTablet maximum published version under the 
existing metadata lock. Prune a delete-sign row only when that version minus 
the row's original version reaches the configured gap.
   - Reuse `__DORIS_VERSION_COL__`, preserve it through compaction, and share 
the retention filter between horizontal and vertical readers. Include VERSION 
in the vertical key group without making it a sort key.
   - Keep delete signs with missing or unknown original versions 
conservatively. Sequence comparison continues to use the existing ingestion 
semantics.
   - Shared-nothing and MOR tables retain their existing behavior, as do query 
and checksum filtering. No new storage or wire format is introduced.
   
   ### Release note
   
   Add `sequence_delete_sign_retention_version_gap` (default `0`) to delay 
physical deletion of sequence delete-sign rows in cloud MOW tables by a 
published-version gap.
   
   ### Validation
   
   - 54 ASAN BE tests passed: `./run-be-ut.sh --run 
--filter='SequenceDeleteSignRetentionTest.*:TabletReaderTest.*:CloudCompactionTest.*'
 -j100`. The retention fixture uses CloudTablet and covers the exact gap 
boundary, version/configuration snapshots, legacy VERSION handling, default 
behavior and shared-nothing exclusion.
   - Cloud 1 FE + 1 ASAN BE regression passed: `./run-regression-test.sh --run 
--conf <private-cloud-config> -d compaction -s 
test_sequence_delete_sign_retention_version_gap -runMode cloud` (1 suite, 0 
failed, 0 skipped). Covers horizontal/vertical cumulative, base and full 
compaction, original VERSION preservation, retention and exact expiry, and 
lower-sequence writes before/after physical cleanup.
   - ASAN BE build passed: `./build.sh --be -j100`.
   - clang-format 16, build hygiene and whitespace checks passed.
   
   ### Check List (For Author)
   
   - Test
     - [x] Unit Test
     - [x] Regression test
   - Behavior changed:
     - [x] Yes, for cloud MOW sequence tables when the new configuration is 
positive. Default `0` preserves immediate pruning.
   - Does this need documentation?
     - [x] No.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to