[SERVER-31232] remove retrying on stale shardVersion errors from cluster_aggregate.cpp Created: 22/Sep/17  Updated: 06/Dec/22  Resolved: 03/Oct/18

Status: Closed
Project: Core Server
Component/s: Aggregation Framework, Sharding
Affects Version/s: 3.5.13
Fix Version/s: None

Type: Task Priority: Major - P3
Reporter: Esha Maharishi (Inactive) 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:
Depends
depends on SERVER-30025 for sharded read with empty query, ta... Closed
Duplicate
duplicates SERVER-34695 Move aggregation retry logic to comma... Closed
Assigned Teams:
Sharding
Participants:

 Description   

SERVER-30025 will make the scatterGather*() methods throw a StaleConfigException on seeing a stale shardVersion error in a response from a shard.

This StaleConfigException is caught at the top of mongos in generic command processing, and the command gets retried from the beginning.

So, a command need not intercept stale shardVersion errors and perform any complicated retry logic itself.

This will fix a bug in aggregation, where if a sharded collection is dropped and recreated as a view, the view definition response was not handled by the aggregation code on mongos.



 Comments   
Comment by Esha Maharishi (Inactive) [ 03/Oct/18 ]

Great, closing as a dupe

Comment by Nicholas Zolnierz [ 03/Oct/18 ]

esha.maharishi yep this was done as part of SERVER-34695, I don't believe there are any lingering spots where we handle stale version exceptions in the agg layer. Sorry didn't realize this ticket existed at the time of creating SERVER-34695.

Comment by Esha Maharishi (Inactive) [ 03/Oct/18 ]

Maybe nicholas.zolnierz or charlie.swanson can confirm - I agree at least some of the stale version exceptions are now bubbled up to the top-level retry loop, but I'm not sure if there are any branches in agg that still catch them.

Comment by David Storch [ 03/Oct/18 ]

esha.maharishi, if I'm not mistaken, this work has been completed under a different ticket.

Generated at Thu Feb 08 04:26:23 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.