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

Create index with hidden:true succeeds when a hidden:false index already exists

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.3.0-rc0
    • Affects Version/s: None
    • Component/s: Catalog
    • None
    • Catalog and Routing
    • Fully Compatible
    • ALL
    • CAR Team 2023-12-11, CAR Team 2023-12-25
    • 0
    • 1

      From looking at BF-30486 it appears that creating a hidden:true index when the same hidden:false index already exists doesn't actually report an error.

      From looking at the logs, it can be seen that on one of the shards, the index indeed got dropped successfully, but a concurrent incoming migration of a first chunk from a collection managed to re-create it with the options it had from before the drop (relevant log lines posted below).

      Because the index is now existent, the create statement (which creates it with hidden:true) just became a no-op.

      This ticket is just to improve the createIndex command to report an error in this case.

            Assignee:
            david.dominguez@mongodb.com David Dominguez Sal (Inactive)
            Reporter:
            kaloian.manassiev@mongodb.com Kaloian Manassiev
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: