Return proper BulkWriteResult after a retryable write succeeds. Reduce retryable writes test suite time from 90 to 30 seconds by reducing the heartbeat interval.
135 lines
2.5 KiB
JSON
135 lines
2.5 KiB
JSON
{
|
|
"data": [
|
|
{
|
|
"_id": 1,
|
|
"x": 11
|
|
}
|
|
],
|
|
"minServerVersion": "3.99",
|
|
"tests": [
|
|
{
|
|
"description": "InsertMany succeeds after PrimarySteppedDown",
|
|
"clientOptions": {
|
|
"retryWrites": true
|
|
},
|
|
"failPoint": {
|
|
"configureFailPoint": "failCommand",
|
|
"mode": {
|
|
"times": 1
|
|
},
|
|
"data": {
|
|
"failCommands": [
|
|
"insert"
|
|
],
|
|
"errorCode": 189
|
|
}
|
|
},
|
|
"operation": {
|
|
"name": "insertMany",
|
|
"arguments": {
|
|
"documents": [
|
|
{
|
|
"_id": 2,
|
|
"x": 22
|
|
},
|
|
{
|
|
"_id": 3,
|
|
"x": 33
|
|
}
|
|
],
|
|
"options": {
|
|
"ordered": true
|
|
}
|
|
}
|
|
},
|
|
"outcome": {
|
|
"result": {
|
|
"insertedIds": {
|
|
"0": 2,
|
|
"1": 3
|
|
}
|
|
},
|
|
"collection": {
|
|
"data": [
|
|
{
|
|
"_id": 1,
|
|
"x": 11
|
|
},
|
|
{
|
|
"_id": 2,
|
|
"x": 22
|
|
},
|
|
{
|
|
"_id": 3,
|
|
"x": 33
|
|
}
|
|
]
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"description": "InsertMany succeeds after WriteConcernError ShutdownInProgress",
|
|
"clientOptions": {
|
|
"retryWrites": true
|
|
},
|
|
"failPoint": {
|
|
"configureFailPoint": "failCommand",
|
|
"mode": {
|
|
"times": 1
|
|
},
|
|
"data": {
|
|
"failCommands": [
|
|
"insert"
|
|
],
|
|
"writeConcernError": {
|
|
"code": 91,
|
|
"errmsg": "Replication is being shut down"
|
|
}
|
|
}
|
|
},
|
|
"operation": {
|
|
"name": "insertMany",
|
|
"arguments": {
|
|
"documents": [
|
|
{
|
|
"_id": 2,
|
|
"x": 22
|
|
},
|
|
{
|
|
"_id": 3,
|
|
"x": 33
|
|
}
|
|
],
|
|
"options": {
|
|
"ordered": true
|
|
}
|
|
}
|
|
},
|
|
"outcome": {
|
|
"result": {
|
|
"insertedIds": {
|
|
"0": 2,
|
|
"1": 3
|
|
}
|
|
},
|
|
"collection": {
|
|
"data": [
|
|
{
|
|
"_id": 1,
|
|
"x": 11
|
|
},
|
|
{
|
|
"_id": 2,
|
|
"x": 22
|
|
},
|
|
{
|
|
"_id": 3,
|
|
"x": 33
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|