In-memory reconciliation also need to restore the update chain back to the old disk image if reconciliation fail

XMLWordPrintableJSON

    • Storage Engines - Transactions
    • SE Transactions - 2026-02-27
    • 3

      With WT-15489, we change the in-memory leaf page reconciliation to allow it to free the versions we write to the disk image from the update chain. However, there is one thing we missed in __split_multi_inmem_fail.

         if (!F_ISSET(S2BT(session), WT_BTREE_IN_MEMORY))
              /* Append the onpage values back to the original update chains. */
              for (i = 0, supd = multi->supd; i < multi->supd_entries; ++i, ++supd) {
                  /*
                   * We don't need to do anything for update chains that are not restored, or restored
                   * without an onpage value.
                   */
                  if (!supd->restore || supd->onpage_upd == NULL)
                      continue;
      
                  if (supd->free_upds == NULL)
                      continue;
      
                  if (supd->ins == NULL) {
                      /* Note: supd->ins is never null for column-store. */
                      slot = WT_ROW_SLOT(orig, supd->rip);
                      upd = orig->modify->mod_row_update[slot];
                  } else
                      upd = supd->ins->upd;
      
                  WT_ASSERT(session, upd != NULL);
                  for (; upd->next != NULL; upd = upd->next)
                      ;
                  upd->next = supd->free_upds;
              }
      

      We also now need to restore the update chain back to the old disk image if the reconciliation fails.

            Assignee:
            Chenhao Qu
            Reporter:
            Chenhao Qu
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: