When we query mongos 3.2 or 3.4 with a read preference and read concern, the command should be assembled like:
{
"$query": {
"find": "test", "filter": {}, "readConcern": {"level": "majority"}
},
"$readPreference": {
"mode": "secondary"
}
}
However, the driver sends:
{
"$query": {
"find": "test", "filter": {}, "readConcern": {"level": "majority"}
},
"$readPreference": {
"mode": "secondary"
},
"readConcern": {"level": "majority"}
}
mongos apparently ignores the outer readConcern.