-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
None
A mongoc_server_stream_t should not be reused after calling mongoc_cluster_run_command_monitored on with the stream.
In two situations, the stream will disconnect and be invalidated:
When that happens, the server_stream for that operation is no longer valid. But we do not always account that correctly.
_mongoc_write_opmsg (incorrectly) always ends unordered bulk operations on error because of CDRIVER-3305. Once that is resolved, it will need to handle the case of an invalidated server stream.
_mongoc_write_opquery only sets must_stop to true for what it deems is a network error (of which, that check might not be quite right if error labels were applied). But it does not handle the case of a "not master" or "node is recovering" error causing a disconnect.
- clones
-
CDRIVER-3306 Do not assume non-empty server reply implies stream is still valid
- Closed
- has to be done before
-
CDRIVER-3305 OP_MSG unordered bulk writes should not stop upon first error
- Closed
- related to
-
CDRIVER-3239 Driver aborts during OP_MSG bulk write if command fails mid batch
- Closed