Skip to content

[To dev/1.3] Fix stale aligned field merge in PriorityMergeReader look-ahead (#19399) - #19440

Merged
ColinLeeo merged 1 commit into
apache:dev/1.3from
samyak-jain-dev:cp_19399_dev_1_3
Nov 29, 2026
Merged

ColinLeeo merged 1 commit into
apache:dev/1.3from
samyak-jain-dev:cp_19399_dev_1_3

Conversation

@samyak-jain-dev

Copy link
Copy Markdown
Contributor

Cherry-pick of #19399 (96a0c6d390) to dev/1.3.

Description

Fixes the stale aligned field merge bug in PriorityMergeReader look-ahead (originally reported in #19392 and fixed on master in #19399):

  • Removes the premature fillNullValue(topNext, e.getTimeValuePair()) call from the look-ahead path in PriorityMergeReader.updateHeap().
  • Tracks aligned row completeness while building each vector via AlignedPointReader (TsBlockAlignedRowPointReader, AlignedTVListIterator, MultiAlignedTVListIterator), cached lazily via Element.alignedReader with the hasOverlap and topNext != null guards in PriorityMergeReader.
  • Adapts the end-to-end integration test from IoTDBAlignedSeriesQueryTableIT (table model on master) to IoTDBAlignedSeriesQueryIT#partialUpdateMergeAcrossMultipleFlushesTest (tree model on dev/1.3), isolated in root.merge_lookahead_db with FLUSH root.merge_lookahead_db.

Verification

  • Unit tests (AlignedPriorityMergeReaderTest, PriorityMergeReaderTest, *AlignedTVList*Test, *SeriesScan*Test): 98/98 passed (AlignedPriorityMergeReaderTest: 9/9, PriorityMergeReaderTest: 4/4)
  • Integration test (IoTDBAlignedSeriesQueryIT#partialUpdateMergeAcrossMultipleFlushesTest with -P SimpleIT -P with-integration-tests): 1/1 passed (Apache RAT: 0 unapproved)

@ColinLeeo

Copy link
Copy Markdown
Collaborator

LGTM

@ColinLeeo
ColinLeeo merged commit 1eee40d into apache:dev/1.3 Nov 29, 2026
16 checks passed
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