ExportXMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Reconciliation
    • Storage Engines - Transactions
    • 8,755.679
    • StorEng - Defined Pipeline
    • 8

      Problem

      Checkpoint cleanup can reclaim a whole obsolete page, but cannot reclaim individual obsolete records by removing that page. The existing time aggregate records the newest durable stop timestamp for any deleted key, so a partially deleted page can make cleanup read internal pages even when no descendant leaf can be reclaimed as a whole.

      The original aggregate contains:

          wt_timestamp_t newest_start_durable_ts; /* default value: WT_TS_NONE */
          wt_timestamp_t newest_stop_durable_ts;  /* default value: WT_TS_NONE */
      
          wt_timestamp_t oldest_start_ts; /* default value: WT_TS_NONE */
          uint64_t newest_txn;            /* default value: WT_TXN_NONE */
          wt_timestamp_t newest_stop_ts;  /* default value: WT_TS_MAX */
          uint64_t newest_stop_txn;       /* default value: WT_TXN_MAX */
      
          uint8_t prepare;
      

      The start and stop durable timestamps are used by rollback to stable to identify unstable data. The stop durable timestamp is also used by checkpoint cleanup to find obsolete pages.

      Scope of this ticket

      • Repurpose the aggregate to track newest_durable_ts, the maximum durable timestamp across starts and stops, and newest_page_stop_durable_ts, the stop bound for fully deleted pages. A leaf has a page-stop bound only when it is fully deleted; internal addresses retain a bound for fully deleted descendants even when other descendants contain live keys.
      • Use the page-stop bound in checkpoint cleanup so it can skip unnecessary reads, while retaining the existing obsolete-time-window cleanup path.
      • Include reconciliation split handling, the stop-visibility guard, checkpoint metadata and eligibility handling, and related unit, functional, and compatibility coverage. These changes remain together so this ticket can land independently.
      • Keep the on-disk address-cell encoding unchanged. Write and read compatible checkpoint metadata; the agreed downgrade target is MongoDB 9.0.

      Implementation: WiredTiger PR #10662.

      Follow-up and landing order

      WT-19141 is a separate follow-up, implemented by PR #15150. It adds checkpoint-cleanup page-read statistics and partial, mixed, and full-delete regression coverage. It depends on this ticket and is not required for this ticket to land. Land #10662 first, then #15150, with one landed commit per ticket.

      The standalone checkpoint-cleanup benchmark is not included in either PR.

            Assignee:
            Haribabu Kommi
            Reporter:
            Haribabu Kommi
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated: