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

Avoid lookaside instantiation for faster reads

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 3.6.3, 3.7.2, WT3.1.0
    • Affects Version/s: None
    • Component/s: None
    • Storage 2017-12-18, Storage 2018-01-01, Storage 2018-01-15
    • v3.6

      Once a page is evicted with lookaside entries, instantiating it is expensive because there are multiple reads from the lookaside table, then the lookaside entries are removed.

      For reads with a recent snapshot / timestamp, the on-disk versions of data may be sufficient to get correct results without instantiating entries from the lookaside table.

      A possible solution would be to add a new WT_REF state, WT_REF_MEM_LOOKASIDE, for an in-memory page that has lookaside entries. Reads of a WT_REF_LOOKASIDE page check if lookaside entries are required, and if so do full instantiation. If lookaside entries are not required for the read, just the page image is read and the state set to WT_REF_MEM_LOOKASIDE.

      Reads of such a page check ref->page_las to determine whether lookaside entries are required for correctness. If so, the page is instantiated and transitions to WT_REF_MEM. Any updates to the page must also do a full instantiation.

            Assignee:
            sue.loverso@mongodb.com Susan LoVerso
            Reporter:
            michael.cahill@mongodb.com Michael Cahill (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: