Skip to content

Preserve record-lock holder versions across explicit transaction retries #3487

Closed

Description

@kriszyp

A held-record write inside an explicit transaction() can be re-stamped during a conflict retry. DatabaseTransaction.save() preserves a TransactionWrite across retries, while the record lock's holder stamp is used to order the write against prior versions. If the retry changes that version, the holder's ordering can differ between attempts and may no longer match the version the caller first staged.

Add a regression that forces an explicit transaction conflict after the lock-backed write is staged, then verify the retry preserves the intended holder version and persists the expected record. Keep this scoped to explicit-transaction retry semantics; ordinary lock admission and ImmediateTransaction writes are covered separately by harper#3248.

Review-Deferral: 1ccfcee6af535072 severity=minor category=data-integrity

Activity

  1. added theissue type on Oct 23, 2026
  2. self-assigned this
    on Oct 26, 2026
  3. added a commit that references this issue on Oct 28, 2026
    59b42fa
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

Fields

Priority

P2

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions