Skip to content

Backport to branch(3.17) : Fix index-based Get/Scan to filter out results whose index key no longer matches after lazy recovery rollback#3503

Merged
brfrn169 merged 1 commit into
3.17from
3.17-pull-3488
Apr 14, 2026
Merged

Backport to branch(3.17) : Fix index-based Get/Scan to filter out results whose index key no longer matches after lazy recovery rollback#3503
brfrn169 merged 1 commit into
3.17from
3.17-pull-3488

Conversation

@feeblefakie

Copy link
Copy Markdown
Member

This is an automated backport of the following:

Please merge this PR after all checks have passed.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces logic to filter out results after a lazy recovery (rollback) if the index column value no longer matches the queried index key. It also updates the snapshot caching mechanism to prevent caching a record as absent when it was actually filtered out due to an index key mismatch or conjunctions. Comprehensive unit and integration tests have been added to verify these changes. One review comment suggests improving the robustness of the resultMatchesIndexKey method to avoid a potential IndexOutOfBoundsException if assertions are disabled.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces logic to filter out results in index-based read and scan operations when a record is rolled back during lazy recovery and its index column value no longer matches the query. It also includes a fix to prevent incorrect caching of empty results in the transaction snapshot in these cases. Comprehensive unit and integration tests have been added to verify the filtering behavior across different transaction states and isolation levels. I have no feedback to provide.

@brfrn169 brfrn169 merged commit f712fa6 into 3.17 Apr 14, 2026
14 checks passed
@brfrn169 brfrn169 deleted the 3.17-pull-3488 branch April 14, 2026 06:39
brfrn169 added a commit that referenced this pull request Apr 28, 2026
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