[SERVER-36203] Unify error codes returned by mongod for requests with autocommit:false outside a transaction Created: 19/Jul/18 Updated: 06/Dec/22 Resolved: 15/Aug/18 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Jack Mulrow | Assignee: | [DO NOT USE] Backlog - Sharding Team |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Assigned Teams: |
Sharding
|
||||||||
| Participants: | |||||||||
| Description |
|
Currently, if mongod receives a request with autocommit:false and a txnId (txnNumber/lsid pair) that has not been seen yet, it will return ErrorCodes::NoSuchTransaction. If a retryable write with the same txnId was completed earlier on that session though, the request with autocommit:false would instead return ErrorCodes::InvalidOptions. Running a command with autocommit:false and a txnId is a valid combination of options and it isn't really intuitive for a retryable write to change the error code, so I think the code should always be NoSuchTransaction. |
| Comments |
| Comment by Jack Mulrow [ 15/Aug/18 ] |
|
This was incidentally fixed as part of |