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

Make findAndModify behave as expected

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Duplicate
    • Affects Version/s: 2.0.1
    • Fix Version/s: None
    • Component/s: Write Ops
    • Environment:
      any
    • Backwards Compatibility:
      Fully Compatible

      Description

      as it works today findAndModify calls lastError and returns a getLastError object as part of the command. However this does not work for replicasets as there is no possibility to to pass w and wtimeout to the command so the drivers have to execute a lastError command again after the findAndModify. So my question is can we 1 let findAndModify take w and associated parameters or 2 remove the lastError call as part of findAndModify to make it work as insert, update and remove ?

      I would prefer option 1 as it does not break backward compatibility.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned
              Reporter:
              christkv Christian Amor Kvalheim
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: