Skip to content

PSMDB-2023 Abandon snapshot after catalog reopen in FCBIS storage switch#1770

Merged
igorsol merged 1 commit intorelease-8.0.20-8from
psmdb-2023
Mar 25, 2026
Merged

PSMDB-2023 Abandon snapshot after catalog reopen in FCBIS storage switch#1770
igorsol merged 1 commit intorelease-8.0.20-8from
psmdb-2023

Conversation

@igorsol
Copy link
Copy Markdown

@igorsol igorsol commented Mar 25, 2026

SERVER-108364 added allowOneUntimestampedWrite() to _updateMinValidDocument which invariants if recovery unit is active.
openCatalogAfterStorageChange() can leave the RU active, so callers that subsequently invoke setMinValid() hit the invariant. Abandon the snapshot before returning from _switchStorageLocation to ensure the RU is inactive.

SERVER-108364 added allowOneUntimestampedWrite() to _updateMinValidDocument
which invariants if recovery unit is active.
openCatalogAfterStorageChange() can leave the RU active, so callers that
subsequently invoke setMinValid() hit the invariant. Abandon the snapshot
before returning from _switchStorageLocation to ensure the RU is inactive.
@github-actions
Copy link
Copy Markdown

Backport Policy Overview

@igorsol, This branch (v8.0) is a production release branch and does not accept direct PRs.
All changes must flow through the corresponding staging branch (v8.0-staging), where they are tested and validated before being promoted into v8.0 by the Server Release team.

Next step: Please re-open this PR against v8.0-staging.

Please reach out in #server-release if you have any questions.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR prevents setMinValid() callers from hitting an invariant after an FCBIS storage location switch by ensuring the OperationContext’s RecoveryUnit is no longer in an active snapshot/WT transaction state after openCatalogAfterStorageChange().

Changes:

  • Abandon the current recovery unit snapshot after catalog::openCatalogAfterStorageChange(opCtx) in _switchStorageLocation().
  • Add an explanatory comment describing why the snapshot must be abandoned before subsequent setMinValid() calls.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@igorsol igorsol changed the base branch from v8.0 to release-8.0.20-8 March 25, 2026 11:40
@igorsol igorsol requested review from ktrushin and plebioda March 25, 2026 11:47
@igorsol igorsol merged commit 5f8e208 into release-8.0.20-8 Mar 25, 2026
9 of 10 checks passed
@igorsol igorsol deleted the psmdb-2023 branch March 25, 2026 12:01
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.

5 participants