find_and_modify failed when read from secondary

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Major - P3
    • 1.8.2
    • Affects Version/s: 1.7.0
    • Component/s: None
    • Environment:
      MongoDB 2.2.0
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Mongo::OperationFailure (Database command 'findandmodify' failed: (errmsg: 'not master'; note: 'from execCommand'; ok: '0.0').)

      when

      @con = Mongo::ReplSetConnection.new(['localhost:27017','localhost:27018'], :read => :secondary)

      The driver should run the query on a primary.

            Assignee:
            Tyler Brock (Inactive)
            Reporter:
            Yutaro Dozen
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: