Skip to content

Conversation

@xuxiong1
Copy link
Contributor

@xuxiong1 xuxiong1 commented Dec 4, 2025

Description

This commit introduces a feature to read translog operations in forward order
(oldest to newest) instead of the default backward order (newest to oldest).

Changes:

  • Add index.translog.read_forward setting (default: false) in IndexSettings
  • Update MultiSnapshot to support bidirectional reading based on setting

Tests:

  • testRecoveryTrimsLocalTranslogWithReadForward (RecoveryTests)
  • testSeqNoCollisionWithReadForward (IndexLevelReplicationTests)
  • testSnapshotReadOperationForward (LocalTranslogTests)

Related Issues

Resolves #20094

Check List

  • Functionality includes testing.
  • API changes companion pull request created, if applicable.
  • Public documentation issue/PR created, if applicable.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@coderabbitai
Copy link

coderabbitai bot commented Dec 4, 2025

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions github-actions bot added enhancement Enhancement or improvement to existing feature or request Indexing:Replication Issues and PRs related to core replication framework eg segrep labels Dec 4, 2025
Signed-off-by: xuxiong1 <[email protected]>
@github-actions
Copy link
Contributor

github-actions bot commented Dec 4, 2025

❌ Gradle check result for c968213: null

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

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

Labels

enhancement Enhancement or improvement to existing feature or request Indexing:Replication Issues and PRs related to core replication framework eg segrep

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] read forward in translog

1 participant