Skip to content

GODRIVER-1981 Sync new transactions tests #652

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 29, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 49 additions & 0 deletions data/transactions/unified/mongos-unpin.json
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,55 @@
}
]
},
{
"description": "unpin after non-transient error on abort",
"operations": [
{
"name": "startTransaction",
"object": "session0"
},
{
"name": "insertOne",
"object": "collection0",
"arguments": {
"document": {
"x": 1
},
"session": "session0"
}
},
{
"name": "targetedFailPoint",
"object": "testRunner",
"arguments": {
"session": "session0",
"failPoint": {
"configureFailPoint": "failCommand",
"mode": {
"times": 1
},
"data": {
"failCommands": [
"abortTransaction"
],
"errorCode": 91
}
}
}
},
{
"name": "abortTransaction",
"object": "session0"
},
{
"name": "assertSessionUnpinned",
"object": "testRunner",
"arguments": {
"session": "session0"
}
}
]
},
{
"description": "unpin when a new transaction is started",
"operations": [
Expand Down
17 changes: 17 additions & 0 deletions data/transactions/unified/mongos-unpin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,23 @@ tests:
- *abortTransaction
- *assertNoPinnedServer

- description: unpin after non-transient error on abort
operations:
- *startTransaction
- *insertOne
- name: targetedFailPoint
object: testRunner
arguments:
session: *session0
failPoint:
configureFailPoint: failCommand
mode: { times: 1 }
data:
failCommands: [ abortTransaction ]
errorCode: 91 # ShutdownInProgress
- *abortTransaction
- *assertNoPinnedServer

- description: unpin when a new transaction is started
operations:
- *startTransaction
Expand Down