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

Allow query filter for compact operation

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Major - P3
    • Resolution: Won't Fix
    • None
    • None
    • MMAPv1, Storage
    • None
    • Storage Execution

    Description

      MongoDB provides a compact operation for removing (or re-allocating) padding for all cases in a collection. We have a use-case where it would be nice to compact a collection, but not to re-allocate padding for a select subset of the documents. This subset is easily described by a query.

      This feature would be a simple additional field to the compact operation. For example, the docs might include:

      field: spec
      type: object
      description: A MongoDB query indicating which records to be compacted.

      And the docs might state, "If a spec is provided, docs that don't match the spec may be moved but will retain their current padding (allocation size on disk)."

      Attachments

        Issue Links

          Activity

            People

              backlog-server-execution Backlog - Storage Execution Team
              jason.coombs@yougov.com Jason R. Coombs
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: