1{
2 "runOn": [
3 {
4 "minServerVersion": "4.0",
5 "topology": [
6 "single",
7 "replicaset"
8 ]
9 },
10 {
11 "minServerVersion": "4.1.7",
12 "topology": [
13 "sharded",
14 "load-balanced"
15 ]
16 }
17 ],
18 "database_name": "retryable-reads-tests",
19 "collection_name": "coll",
20 "data": [],
21 "tests": [
22 {
23 "description": "ListIndexes succeeds after InterruptedAtShutdown",
24 "failPoint": {
25 "configureFailPoint": "failCommand",
26 "mode": {
27 "times": 1
28 },
29 "data": {
30 "failCommands": [
31 "listIndexes"
32 ],
33 "errorCode": 11600
34 }
35 },
36 "operations": [
37 {
38 "name": "listIndexes",
39 "object": "collection"
40 }
41 ],
42 "expectations": [
43 {
44 "command_started_event": {
45 "command": {
46 "listIndexes": "coll"
47 },
48 "database_name": "retryable-reads-tests"
49 }
50 },
51 {
52 "command_started_event": {
53 "command": {
54 "listIndexes": "coll"
55 },
56 "database_name": "retryable-reads-tests"
57 }
58 }
59 ]
60 },
61 {
62 "description": "ListIndexes succeeds after InterruptedDueToReplStateChange",
63 "failPoint": {
64 "configureFailPoint": "failCommand",
65 "mode": {
66 "times": 1
67 },
68 "data": {
69 "failCommands": [
70 "listIndexes"
71 ],
72 "errorCode": 11602
73 }
74 },
75 "operations": [
76 {
77 "name": "listIndexes",
78 "object": "collection"
79 }
80 ],
81 "expectations": [
82 {
83 "command_started_event": {
84 "command": {
85 "listIndexes": "coll"
86 },
87 "database_name": "retryable-reads-tests"
88 }
89 },
90 {
91 "command_started_event": {
92 "command": {
93 "listIndexes": "coll"
94 },
95 "database_name": "retryable-reads-tests"
96 }
97 }
98 ]
99 },
100 {
101 "description": "ListIndexes succeeds after NotWritablePrimary",
102 "failPoint": {
103 "configureFailPoint": "failCommand",
104 "mode": {
105 "times": 1
106 },
107 "data": {
108 "failCommands": [
109 "listIndexes"
110 ],
111 "errorCode": 10107
112 }
113 },
114 "operations": [
115 {
116 "name": "listIndexes",
117 "object": "collection"
118 }
119 ],
120 "expectations": [
121 {
122 "command_started_event": {
123 "command": {
124 "listIndexes": "coll"
125 },
126 "database_name": "retryable-reads-tests"
127 }
128 },
129 {
130 "command_started_event": {
131 "command": {
132 "listIndexes": "coll"
133 },
134 "database_name": "retryable-reads-tests"
135 }
136 }
137 ]
138 },
139 {
140 "description": "ListIndexes succeeds after NotPrimaryNoSecondaryOk",
141 "failPoint": {
142 "configureFailPoint": "failCommand",
143 "mode": {
144 "times": 1
145 },
146 "data": {
147 "failCommands": [
148 "listIndexes"
149 ],
150 "errorCode": 13435
151 }
152 },
153 "operations": [
154 {
155 "name": "listIndexes",
156 "object": "collection"
157 }
158 ],
159 "expectations": [
160 {
161 "command_started_event": {
162 "command": {
163 "listIndexes": "coll"
164 },
165 "database_name": "retryable-reads-tests"
166 }
167 },
168 {
169 "command_started_event": {
170 "command": {
171 "listIndexes": "coll"
172 },
173 "database_name": "retryable-reads-tests"
174 }
175 }
176 ]
177 },
178 {
179 "description": "ListIndexes succeeds after NotPrimaryOrSecondary",
180 "failPoint": {
181 "configureFailPoint": "failCommand",
182 "mode": {
183 "times": 1
184 },
185 "data": {
186 "failCommands": [
187 "listIndexes"
188 ],
189 "errorCode": 13436
190 }
191 },
192 "operations": [
193 {
194 "name": "listIndexes",
195 "object": "collection"
196 }
197 ],
198 "expectations": [
199 {
200 "command_started_event": {
201 "command": {
202 "listIndexes": "coll"
203 },
204 "database_name": "retryable-reads-tests"
205 }
206 },
207 {
208 "command_started_event": {
209 "command": {
210 "listIndexes": "coll"
211 },
212 "database_name": "retryable-reads-tests"
213 }
214 }
215 ]
216 },
217 {
218 "description": "ListIndexes succeeds after PrimarySteppedDown",
219 "failPoint": {
220 "configureFailPoint": "failCommand",
221 "mode": {
222 "times": 1
223 },
224 "data": {
225 "failCommands": [
226 "listIndexes"
227 ],
228 "errorCode": 189
229 }
230 },
231 "operations": [
232 {
233 "name": "listIndexes",
234 "object": "collection"
235 }
236 ],
237 "expectations": [
238 {
239 "command_started_event": {
240 "command": {
241 "listIndexes": "coll"
242 },
243 "database_name": "retryable-reads-tests"
244 }
245 },
246 {
247 "command_started_event": {
248 "command": {
249 "listIndexes": "coll"
250 },
251 "database_name": "retryable-reads-tests"
252 }
253 }
254 ]
255 },
256 {
257 "description": "ListIndexes succeeds after ShutdownInProgress",
258 "failPoint": {
259 "configureFailPoint": "failCommand",
260 "mode": {
261 "times": 1
262 },
263 "data": {
264 "failCommands": [
265 "listIndexes"
266 ],
267 "errorCode": 91
268 }
269 },
270 "operations": [
271 {
272 "name": "listIndexes",
273 "object": "collection"
274 }
275 ],
276 "expectations": [
277 {
278 "command_started_event": {
279 "command": {
280 "listIndexes": "coll"
281 },
282 "database_name": "retryable-reads-tests"
283 }
284 },
285 {
286 "command_started_event": {
287 "command": {
288 "listIndexes": "coll"
289 },
290 "database_name": "retryable-reads-tests"
291 }
292 }
293 ]
294 },
295 {
296 "description": "ListIndexes succeeds after HostNotFound",
297 "failPoint": {
298 "configureFailPoint": "failCommand",
299 "mode": {
300 "times": 1
301 },
302 "data": {
303 "failCommands": [
304 "listIndexes"
305 ],
306 "errorCode": 7
307 }
308 },
309 "operations": [
310 {
311 "name": "listIndexes",
312 "object": "collection"
313 }
314 ],
315 "expectations": [
316 {
317 "command_started_event": {
318 "command": {
319 "listIndexes": "coll"
320 },
321 "database_name": "retryable-reads-tests"
322 }
323 },
324 {
325 "command_started_event": {
326 "command": {
327 "listIndexes": "coll"
328 },
329 "database_name": "retryable-reads-tests"
330 }
331 }
332 ]
333 },
334 {
335 "description": "ListIndexes succeeds after HostUnreachable",
336 "failPoint": {
337 "configureFailPoint": "failCommand",
338 "mode": {
339 "times": 1
340 },
341 "data": {
342 "failCommands": [
343 "listIndexes"
344 ],
345 "errorCode": 6
346 }
347 },
348 "operations": [
349 {
350 "name": "listIndexes",
351 "object": "collection"
352 }
353 ],
354 "expectations": [
355 {
356 "command_started_event": {
357 "command": {
358 "listIndexes": "coll"
359 },
360 "database_name": "retryable-reads-tests"
361 }
362 },
363 {
364 "command_started_event": {
365 "command": {
366 "listIndexes": "coll"
367 },
368 "database_name": "retryable-reads-tests"
369 }
370 }
371 ]
372 },
373 {
374 "description": "ListIndexes succeeds after NetworkTimeout",
375 "failPoint": {
376 "configureFailPoint": "failCommand",
377 "mode": {
378 "times": 1
379 },
380 "data": {
381 "failCommands": [
382 "listIndexes"
383 ],
384 "errorCode": 89
385 }
386 },
387 "operations": [
388 {
389 "name": "listIndexes",
390 "object": "collection"
391 }
392 ],
393 "expectations": [
394 {
395 "command_started_event": {
396 "command": {
397 "listIndexes": "coll"
398 },
399 "database_name": "retryable-reads-tests"
400 }
401 },
402 {
403 "command_started_event": {
404 "command": {
405 "listIndexes": "coll"
406 },
407 "database_name": "retryable-reads-tests"
408 }
409 }
410 ]
411 },
412 {
413 "description": "ListIndexes succeeds after SocketException",
414 "failPoint": {
415 "configureFailPoint": "failCommand",
416 "mode": {
417 "times": 1
418 },
419 "data": {
420 "failCommands": [
421 "listIndexes"
422 ],
423 "errorCode": 9001
424 }
425 },
426 "operations": [
427 {
428 "name": "listIndexes",
429 "object": "collection"
430 }
431 ],
432 "expectations": [
433 {
434 "command_started_event": {
435 "command": {
436 "listIndexes": "coll"
437 },
438 "database_name": "retryable-reads-tests"
439 }
440 },
441 {
442 "command_started_event": {
443 "command": {
444 "listIndexes": "coll"
445 },
446 "database_name": "retryable-reads-tests"
447 }
448 }
449 ]
450 },
451 {
452 "description": "ListIndexes fails after two NotWritablePrimary errors",
453 "failPoint": {
454 "configureFailPoint": "failCommand",
455 "mode": {
456 "times": 2
457 },
458 "data": {
459 "failCommands": [
460 "listIndexes"
461 ],
462 "errorCode": 10107
463 }
464 },
465 "operations": [
466 {
467 "name": "listIndexes",
468 "object": "collection",
469 "error": true
470 }
471 ],
472 "expectations": [
473 {
474 "command_started_event": {
475 "command": {
476 "listIndexes": "coll"
477 },
478 "database_name": "retryable-reads-tests"
479 }
480 },
481 {
482 "command_started_event": {
483 "command": {
484 "listIndexes": "coll"
485 },
486 "database_name": "retryable-reads-tests"
487 }
488 }
489 ]
490 },
491 {
492 "description": "ListIndexes fails after NotWritablePrimary when retryReads is false",
493 "clientOptions": {
494 "retryReads": false
495 },
496 "failPoint": {
497 "configureFailPoint": "failCommand",
498 "mode": {
499 "times": 1
500 },
501 "data": {
502 "failCommands": [
503 "listIndexes"
504 ],
505 "errorCode": 10107
506 }
507 },
508 "operations": [
509 {
510 "name": "listIndexes",
511 "object": "collection",
512 "error": true
513 }
514 ],
515 "expectations": [
516 {
517 "command_started_event": {
518 "command": {
519 "listIndexes": "coll"
520 },
521 "database_name": "retryable-reads-tests"
522 }
523 }
524 ]
525 }
526 ]
527}
View as plain text