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

On a sharded cluster, nearest or hedged reads may not be routed to a near shard replica.

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 4.4.1, 4.7.0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Minor Change
    • ALL
    • v4.4
    • Hide

      I've attached a javascript test that logs the RTTs over the course of 20 pings. It shows 0 RTT reliably despite a failCommand fail point that should prevent that.

      Show
      I've attached a javascript test that logs the RTTs over the course of 20 pings. It shows 0 RTT reliably despite a failCommand fail point that should prevent that.
    • 44

       

      Issue Status as of July 28, 2020

      ISSUE SUMMARY

      Due to an issue with reporting the round-trip time (RTT) of replica set members, on mongoS, "nearest" read preference and hedged reads do not determine the eligible nodes based on localThresholdMs.

      USER IMPACT

      On a sharded cluster, nearest reads or hedged reads are not necessarily routed to a near shard replica (that is, within 15ms round-trip time). These reads are instead dispatched to an arbitrary node, which can be more remote.

      WORKAROUNDS

      Installations with distributed sharded clusters that rely on read preference "nearest" should not upgrade to 4.4.0. Instead, upgrade to 4.4.1.

      AFFECTED VERSIONS

      This affects version 4.4.0.

      FIX VERSION

      This issue is corrected in MongoDB 4.4.1.

       

      Original Description

      When looking a substantial RTT for non-colocated hosts, I'm seeing clean .8 factor decreases on ping intervals which trends towards 0. I see that the factor is .2 from here. My conclusion is we're passing in RTT=0 for each update after the first.

        1. rsm_heartbeat.js
          1 kB
          Benjamin Caimano
        2. Screen Shot 2020-07-17 at 13.09.39.png
          35 kB
          Benjamin Caimano

            Assignee:
            lamont.nelson@mongodb.com Lamont Nelson
            Reporter:
            ben.caimano@mongodb.com Benjamin Caimano (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            13 Start watching this issue

              Created:
              Updated:
              Resolved: