[SERVER-46105] Allow new collection creation inside prepared transactions. Created: 12/Feb/20 Updated: 08/Nov/23 |
|
| Status: | Backlog |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Maria van Keulen | Assignee: | Backlog - Catalog and Routing |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||
| Assigned Teams: |
Catalog and Routing
|
||||||||||||||||||||
| Sprint: | Execution Team 2021-01-11, Execution EMEA Team 2023-08-07, Execution EMEA Team 2023-08-21, Execution EMEA Team 2023-09-04, Execution EMEA Team 2023-09-18, Execution EMEA Team 2023-10-02, Execution EMEA Team 2023-10-16, Execution EMEA Team 2023-10-30 | ||||||||||||||||||||
| Participants: | |||||||||||||||||||||
| Description |
|
|
| Comments |
| Comment by Josef Ahmad [ 14/Sep/23 ] | ||
|
I am marking this ticket as dependent on SERVER-81037, which is a placeholder for a proposal to migrate most of the catalog concurrency control to the storage engine. | ||
| Comment by Josef Ahmad [ 30/Aug/23 ] | ||
|
After consulting with gregory.wlodarek@mongodb.com, it turns out that creating a collection inside a prepared transaction needs additional local catalog work. Today, the catalog only detects conflicting uncommitted catalog updates for unprepared transactions. For prepared transactions, the conflict detection must happen at prepare time rather than at commit time; that also requires handling prepare conflicts with concurrent uncommitted catalog updates, which I'm unsure the catalog is capable of today. | ||
| Comment by Josef Ahmad [ 28/Jul/23 ] | ||
|
I managed to POC an initial cut of implicit collection creation, modulo createIndexes support which needs a redesign of the concurrency model on secondaries. | ||
| Comment by Josef Ahmad [ 27/Jul/23 ] | ||
|
I may have jumped the gun. The issue on secondaries described in | ||
| Comment by Josef Ahmad [ 26/Jul/23 ] | ||
|
I've experimented with removing the guard rails that prevent an end user from implicitly creating a collection in a distributed transaction, and I was able to create the collection implicitly. It looks like we've (perhaps inadvertently) resolved the issue described in
The evergreen patch is green, except for the tests that verified that implicit collection creation in distributed transactions is disallowed. The feature needs comprehensive validation coverage, and more work will likely surface. | ||
| Comment by Eric Milkie [ 13/Feb/20 ] | ||
|
We will consider backporting this work to 4.4 |