-
Type: Task
-
Resolution: Done
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
NODE-4557 Description
What problem are you facing?
When using Node.js driver versions >4.6.x in a configuration with readPreference: nearest and readPreferenceTags resulting in 2 eligible members to read from, the reads are unbalanced between the two members.
For example if there are 1000 queries/second in total, in drivers version <4.6.x, the first members gets ~500 queries/second and second members gets ~500 queries/second. In versions >4.6.x, the second member always is preferred, getting ~750 queries/second where the first member only gets the ~250 queries/second.
The issue seems to fix when there are 3 or more members eligible, the queries and load on all members becomes balanced.
What driver and relevant dependency versions are you using?
Node.js driver >4.6.x
Steps to reproduce?
Create a Mongo cluster setup with tags. From Node.js driver select only 2 members using readPreferenceTags and readPreference: nearest.
- is depended on by
-
NODE-4557 MongoDB reads are not balance with 2 members selected
- Closed