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

Compact claims not to enforce unique indexes but actually does

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: 2.6.0
    • Fix Version/s: 2.7.5
    • Component/s: Index Maintenance
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL

      Description

      The claim that we don't want to enforce uniqueness in compact is made here:
      https://github.com/mongodb/mongo/blob/v2.6/src/mongo/db/structure/collection_compact.cpp#L157

      It doesn't actually work because we go directly to the index descriptor to check if dups are allowed here:
      https://github.com/mongodb/mongo/blob/v2.6/src/mongo/db/index/btree_based_access_method.cpp#L413

        Attachments

          Activity

            People

            Assignee:
            redbeard0531 Mathias Stearn
            Reporter:
            redbeard0531 Mathias Stearn
            Participants:
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: