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

renameCollection command `dropTarget` parameter not a bool in oplog

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 3.0.1
    • Component/s: Replication
    • None
    • Replication
    • ALL

      A rename collection, run from the shell, such as:
      db.test.renameCollection("test2", true)
      Will result in an oplog entry that contains:

        "o": {
          "renameCollection": "XXX",
          "to": "YYY",
          "dropTarget": true
        }
      

      The following command will still drop the target collection, I assume because
      {dropTarget: true} still evalulates to true.
      db.test.renameCollection("test2", {dropTarget:true})

      But the resulting oplog entry contains:

        "o": {
          "renameCollection": "XXX",
          "to": "YYY",
          "dropTarget": {
            "dropTarget": true
         }
      

            Assignee:
            backlog-server-repl [DO NOT USE] Backlog - Replication Team
            Reporter:
            cory.mintz@mongodb.com Cory Mintz
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: