Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix behavior of FileStorage.restore when provided wrong prev_txn #397

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from

Commits on Feb 14, 2024

  1. FileStorage: support restore with a prev_txn not existing in storage

    According to restore comment:
    
    > the prev_txn should be considered just a hint, and is ignored if the
    > transaction doesn't exist.
    
    instead, this was raising an UndoError.
    perrinjerome committed Feb 14, 2024
    Configuration menu
    Copy the full SHA
    7bef1b6 View commit details
    Browse the repository at this point in the history
  2. FileStorage: fix a potential error when restore is called with wrong …

    …txn_prev
    
    if restore is called with an existing txn_prev that does not contain
    the oid, the "8-byte redundant transaction length -8" and the beginning
    of the next transaction was read as a data record.
    
    The condition to stop was incorrect as discussed in [1], in practice
    this error would only happens when restore is passed a bad txn_prev so
    this should not be a problem in normal conditions because we are
    supposed to find the data record for that oid.
    
    [1] #395 (comment)
    perrinjerome committed Feb 14, 2024
    Configuration menu
    Copy the full SHA
    ee1b0b9 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    4592bd8 View commit details
    Browse the repository at this point in the history