[SERVER-82956] Allow calling executeCommandAgainstDatabasePrimary using CollectionRoutingInfo Created: 08/Nov/23 Updated: 23/Nov/23 |
|
| Status: | Backlog |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Allison Easton | Assignee: | Backlog - Catalog and Routing |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Assigned Teams: |
Catalog and Routing
|
| Participants: |
| Description |
|
The executeComandAgainstDatabasePrimary function takes in a CachedDatabaseInfo object in order to route the command. If the caller is using a CollectionRouter loop, though, then they have likely already passed in a CollectionRoutingInfo object to the router loop. To prevent this use case from needing to also fetch the database information from the cache, we should allow executeCommandAgainstDatabasePrimary to be called with a CollectionRoutingInfo object, since it already contains the dbPrimary and the dbVersion. |