-
Type: Task
-
Resolution: Unresolved
-
Priority: Minor - P4
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Query Optimization
In PYTHON-2520 we are adding requireApiVersion support to other topologies in mongo-orchestration, the library we use for creating server test scenarios in driver testing.
For the new feature, we set requireApiVersion as the last step in initialization, and then ensure that any clients created thereafter have a serverApi set. For standalone and sharded cluster routers, it works as expected, and the python test suite passes against the resulting topology.
For replica sets, we are seeing a different behavior. If we do not wait 1-2 seconds after the replica set has finished initializing, then any write operation with w>1 against the replica set times out. If we do wait 1-2 seconds, then we see that an index creation shows the same behavior. We tried setting requireApiVersion on just the primary, and also on the primary and secondary.
For now, we can expand our test matrix in drivers to use requireApiVersion for sharded clusters, but we would also like to be able to test with replica sets.