Make createIndexes command reply idempotent compliant

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Catalog and Routing
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The reply of the createIndexes command is not idempotent because it returns information regarding the status of the cluster previous of the execution of the command. In particular:

      • createIndexes.createdCollectionAutomatically
        • If true, then the collection didn't exist and was created in the process of creating the index.
      • createIndexes.numIndexesBefore
        • The number of indexes at the start of the command.
      • createIndexes.numIndexesAfter
        • The number of indexes at the end of the command.
      • createIndexes.note
        • This note is returned if an existing index or indexes already exist. This indicates that the index was not created or changed.

      In order to make the command truly idempotent, we should stop adding this information in the reply of the command.

            Assignee:
            Unassigned
            Reporter:
            Tommaso Tocci
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: