[SERVER-55662] Retry NotPrimaryError and ShutdownError categories when commiting in the new create collection path Created: 31/Mar/21  Updated: 29/Oct/23  Resolved: 01/Apr/21

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

Type: Improvement Priority: Major - P3
Reporter: Marcos José Grillo Ramirez Assignee: Marcos José Grillo Ramirez
Resolution: Fixed Votes: 0
Labels: PM-1965-Milestone-1
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by SERVER-55656 Prevent early destruction of sharding... Closed
Backwards Compatibility: Fully Compatible
Sprint: Sharding 2021-04-05
Participants:

 Description   

On the new create collection path if we find a NotPrimaryError or a ShutdownError category we bubble up the exception to the router, however, given the fact that we're working on the DDLCoordinator and we're handling this behavior on the completion of the operation, it is better to handle it locally on the _commit function, leveraging that we made the writes to the config server idempotent operations. We could for example use a retryable write, or simply adding a loop to always retry if the response is an error of any of the mentioned categories.



 Comments   
Comment by Githook User [ 01/Apr/21 ]

Author:

{'name': 'Marcos José Grillo Ramirez', 'email': 'marcos.grillo@mongodb.com', 'username': 'm4nti5'}

Message: SERVER-55662 Retry writes to config server on step down errors in create collection coordinator
Branch: master
https://github.com/mongodb/mongo/commit/3e395a015ace4e23ab1e9a1d9a2515a7b082933e

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