[SERVER-83552] Recreate create collection coordinator result with catalog cache refresh Created: 23/Nov/23  Updated: 23/Nov/23  Resolved: 23/Nov/23

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 7.3.0-rc0

Type: Bug Priority: Major - P3
Reporter: Pol Pinol Assignee: Pol Pinol
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Problem/Incident
is caused by SERVER-78918 Make `shardCollection` command shard ... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: CAR Team 2023-11-27
Participants:
Linked BF Score: 160

 Description   

In case of failure after the `commitOnShardingCatlog` at the create collection coordinator, the `_result` will not be set. We need to recreate it, so once the future is completed, the shardsvr command can retrieve correctly the response.

This `_result` is a `CreateCollectionResponse` composed of a collection version. It is not okay to call the catalog cache and get the collection version from the routing info, as it may not have the collection entry - resulting in unsharded.

The goal of this ticket is to make this call with refresh to see the most recent collection version after sharding the collection.



 Comments   
Comment by Githook User [ 23/Nov/23 ]

Author:

{'name': 'Pol Pinol Castuera', 'email': 'pol.pinol@mongodb.com', 'username': 'PolPinol'}

Message: SERVER-83552 Recreate create collection coordinator result with catalog cache refresh
Branch: master
https://github.com/mongodb/mongo/commit/0323b6fa3ccf3479a7d1af49435f7a8e2ae47184

Generated at Thu Feb 08 06:52:31 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.