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

tiered storage: lock the file handle array in the block manager

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major - P3
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: Backlog
    • Component/s: None
    • Labels:
      None

      Description

      The block manager has a file handle array, which dynamically grows.  As such, it needs to be locked, there are TODOs in the code.

      As long as we're there, we can make other improvements.  Eventually, we'll want to close handles that are idle, and when we do, potentially signal to the (storage source|tiered layer) that the underlying file is "evictable" from the cache (or perhaps closing the handle is the signal).

      In any event it seems that associated with each WT_FH in the array should be a reference count and a "last use timestamp".  On each open, the reference count is incremented, on each close it is decremented.  If it reaches 0, the last use timestamp is set.  A sweep can occasionally run to close "old" file handles.  And the array should not be 0-based, but based off of a variable, so it doesn't grow without bound, it will be shifted as needed.  Locking will facilitate dynamic opening of individual objects as well (right now we load up all the objects when we open a file).

        Attachments

          Activity

            People

            Assignee:
            backlog-server-storage-engines Backlog - Storage Engines Team
            Reporter:
            donald.anderson Donald Anderson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated: