From 13364a28fb401b78ef7d74f477dae8b3b5b04865 Mon Sep 17 00:00:00 2001 From: "A. Jesse Jiryu Davis" Date: Fri, 4 Aug 2017 09:48:00 -0400 Subject: [PATCH] Sync "secondary with mismatched me" spec test --- ...int_from_secondary_with_mismatched_me.json | 62 +++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 test/discovery_and_monitoring/rs/primary_hint_from_secondary_with_mismatched_me.json diff --git a/test/discovery_and_monitoring/rs/primary_hint_from_secondary_with_mismatched_me.json b/test/discovery_and_monitoring/rs/primary_hint_from_secondary_with_mismatched_me.json new file mode 100644 index 000000000..ace569317 --- /dev/null +++ b/test/discovery_and_monitoring/rs/primary_hint_from_secondary_with_mismatched_me.json @@ -0,0 +1,62 @@ +{ + "description": "Secondary with mismatched 'me' tells us who the primary is", + "uri": "mongodb://a/?replicaSet=rs", + "phases": [ + { + "responses": [ + [ + "a:27017", + { + "ok": 1, + "ismaster": false, + "secondary": true, + "me": "c:27017", + "hosts": [ + "b:27017" + ], + "setName": "rs", + "primary": "b:27017" + } + ] + ], + "outcome": { + "servers": { + "b:27017": { + "type": "PossiblePrimary", + "setName": null + } + }, + "topologyType": "ReplicaSetNoPrimary", + "logicalSessionTimeoutMinutes": null, + "setName": "rs" + } + }, + { + "responses": [ + [ + "b:27017", + { + "ok": 1, + "ismaster": true, + "me": "b:27017", + "hosts": [ + "b:27017" + ], + "setName": "rs" + } + ] + ], + "outcome": { + "servers": { + "b:27017": { + "type": "RSPrimary", + "setName": "rs" + } + }, + "topologyType": "ReplicaSetWithPrimary", + "logicalSessionTimeoutMinutes": null, + "setName": "rs" + } + } + ] +}