Uploaded image for project: 'Ruby Driver'
  1. Ruby Driver
  2. RUBY-692

Update logic for when to send $readPreference to mongos

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

      We need to update our logic around when to send $readPreference to mongos.

      The logic should be:

      @client.mongos? && !primary? && (!secondary_preferred? || has_tags?)

      This is the relevant line of code:
      https://github.com/mongodb/mongo-ruby-driver/blob/1.x-stable/lib/mongo/cursor.rb#L668

            Assignee:
            brandon.black@10gen.com Brandon Black
            Reporter:
            emily.stolfo Emily Stolfo
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: