Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-80120

Add the new compaction "freeSpaceTargetMB" option to the compact API

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.2.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Fully Compatible
    • 5

      The current compact command only takes in a collection name and runs compact against the collection and index tables as indicated in the existing documentation for MongoDB 6.0. This project modifies the API while ensuring backward compatibility by adding a new field indicating the minimum space compact should be able to reclaim.

      A prototype of the API can be found below:

      db.runCommand(
          {
              compact: <collection name>,
              freeSpaceTargetMB: <number>, // Optional, minimum space available to reclaim in MB, default is 20MB.
          }
      )
      

            Assignee:
            sean.watt@mongodb.com Sean Watt
            Reporter:
            gregory.wlodarek@mongodb.com Gregory Wlodarek
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: