I upgraded my MongoDB cluster from 4.4 to 5 a time ago. I was using custom write concern that is defined via getLastErrorModes and as by pointing tags like:
customconcern:
{ x: 1, y: 2}
I have a 5 node cluster and 1 is arbiter.
Node tags are like
node 1 (primary)
x: 1
y: 1
node 2: (secondary)
x: 2
y:2
node 3: (secondary)
x: 1
y: 4
node 4: (secondary)
x: 2
y: 5
node: 5 (arbiter)
The clients are using the custom write concern and they are updating their connections ettings with w: customconcern
It was fine when i shutdown node 2 and node 4, clients were still able to work without issuing any problems.
After 5 upgrade, i realized that getLastErrorModes is not working as expected. Since i have 2 data nodes up which satisfies the custom write concern, the clients are hanged and timeout at mongodb. If i just start one of the down nodes, things started to work.
So i checked the change log, documentation. Maybe i am missing something about defining custom write concern or 5.0.26 changes.
Will be happy if someone has a clue.