[SERVER-53679] No-op for filling in destined recipient for insert oplog entries adds overhead on shardsvrs not running resharding Created: 09/Jan/21  Updated: 29/Oct/23  Resolved: 22/Mar/21

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

Type: Bug Priority: Major - P3
Reporter: Max Hirschhorn Assignee: Janna Golden
Resolution: Fixed Votes: 0
Labels: PM-234-M3, PM-234-T-oplog-fetch
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Problem/Incident
is caused by SERVER-49822 Add destined recipient to oplog entri... Closed
Related
related to SERVER-57666 Convert getDestinedRecipient() in res... Closed
related to SERVER-58918 Replace getDestinedRecipient() in the... Closed
related to SERVER-75787 remove std::function reference from r... Closed
is related to SERVER-53678 No-op for filling in destined recipie... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Sharding 2021-02-22, Sharding 2021-03-08, Sharding 2021-03-22, Sharding 2021-04-05
Participants:
Linked BF Score: 0
Story Points: 1

 Description   

Splitting this off from SERVER-53678 because the change is more involved.

getDestinedRecipient() is called by OpObserverImpl for all write operations and returns boost::none when there isn't an ongoing resharding operation. Making it so CollectionShardingState::get() and CollectionShardingState::getCollectionDescription() are only called once for each OpObserverImpl::onInserts() call (all of the inserts are to the same collection) would likely address this performance regression. It may be worth noting that OpObserverShardingImpl::shardObserveInsertOp() calls CollectionShardingRuntime::get() once per document being inserted too so addressing both interfaces could be a net performance win.



 Comments   
Comment by Githook User [ 22/Mar/21 ]

Author:

{'name': 'jannaerin', 'email': 'golden.janna@gmail.com', 'username': 'jannaerin'}

Message: SERVER-53679 No-op for filling in destined recipient for insert oplog entries adds overhead on shardsvrs not running resharding
Branch: master
https://github.com/mongodb/mongo/commit/f25c2c9cfbb0e4ae20cd080b3b79a505308db175

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