Skip to content

TN GetByFilter misses replacement append after merge transfer #29284

Closed

Description

@jiangxinmeng1

Problem

After inserting one row, updating it, and committing a merge that produces a new data object, TN may select the merge output row first. When the transferred tombstone removes that RowID, the lookup does not fall back to the replacement row in the appendable object.

Observed behavior:

  • GetByFilter returns not found;
  • a subsequent insert with the same primary key can pass deduplication.

Reproduction

Regression test: TestGetByFilterAfterMergeKeepsTheNewAppend in pkg/vm/engine/tae/db/test/db_test.go.

Fix

PR: #29283

The fix keeps appendable and non-appendable RowID candidates separately, applies tombstone filtering to both, and prefers the live appendable replacement row.

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

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions