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

DBClientWithCommands::ensureIndex() doesn't report errors

    XMLWordPrintableJSON

Details

    • Fully Compatible
    • ALL

    Description

      Observed while writing a unit test for SERVER-23096. You can call DBDirectClient::ensureIndex() twice with the same keys, but once passing true for 'unique' and once passing false, and both calls to ensureIndex() return success.

      When running the createIndexes command it correctly errors with an IndexOptionsConflict error.

      Attachments

        Activity

          People

            rassi J Rassi
            spencer@mongodb.com Spencer Brody (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: