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

Allow deletion of local files from tiered tables while table is open

    • Type: Icon: Technical Debt Technical Debt
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • WT11.3.0, 7.3.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Storage Engines

      As part of WT-10462, we stopped allowing local files to be deleted from an open tiered table. Specifically, when we queue a work item to delete the local file, it will always find the file "in use" while the table is open.

      WT-10838 will let us determine when a file is not in use by tracking the number of active read requests to each WT_BLOCK. We can use this to allow deletion of files that have been copied to object storage. 

      There are two likely approaches:

      1. Periodically check to see of the file is idle, and if so delete the local file allowing future reads to be handled by the copy in object storage
      2. Proactively switch to reading from object storage instead of the local file. At some point we stop issuing new reads to the WT_BLOCK for the local file and set a flag indicating that when the read count goes to zero it should be deleted. During this time new reads to that objectID would go to a new WT_BLOCK backed by the cloud object.

            Assignee:
            donald.anderson@mongodb.com Donald Anderson
            Reporter:
            keith.smith@mongodb.com Keith Smith
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: