Uploaded image for project: 'Drivers'
  1. Drivers
  2. DRIVERS-132

Use createIndexes command when available

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • None
    • None

    Description

      Drivers should use the new createIndexes command when it is available. As with DRIVERS-103, drivers should call the createIndexes command, and if the command is not found, fall back to the old behavior:

      try
          db.runCommand({'createIndexes': ...})
      catch error
          if error code == 59 or error code == Null
              <fallback to existing code for backward compatibility>
          else
              re-raise error

      For drivers that are already getting the server version by calling buildInfo, the build version can be used as an alternative approach.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              barrie Barrie Segal
              Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: