Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-8277

Change salvage to resolve prepared records.

      Prepared values can be found on salvaged pages, and they can exist forever as there is no mechanism for removing prepared values other than a future transaction being resolved, and in the case of salvage, there may not be any such future transaction.

      In keeping with the principle that it's better for salvage to keep data than throw it away, salvaged prepared values should be committed. The change will be to convert prepared values to ordinary updates when a salvaged page is read into memory.

      In order to make this change, we need to know on which pages this should be done, but that is relatively simple: at salvage time, enter the salvage write generation into per-table metadata. If that write generation is present, it can be compared to the page's current write generation when a page is read in; pages from before the salvage run should have any prepared values committed.

      2. It doesn't matter if this happens before or after calling RTS for recovery: the update generated will be rolled back if its transaction ID and/or timestamp make it unstable, regardless of its prepare state.

      See the discussion in WT-7637 for details.

            Assignee:
            backlog-server-storage-engines [DO NOT USE] Backlog - Storage Engines Team
            Reporter:
            keith.bostic@mongodb.com Keith Bostic (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: