[SERVER-34078] Add appendAtClusterTime to MutableDocument type Created: 22/Mar/18  Updated: 06/Dec/22  Resolved: 10/Apr/18

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

Type: Task Priority: Major - P3
Reporter: Misha Tyulenev Assignee: [DO NOT USE] Backlog - Sharding Team
Resolution: Duplicate Votes: 0
Labels: todo_in_code
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Sharding
Sprint: Sharding 2018-04-23
Participants:

 Description   

Needed to avoid BSONObj extra copy.



 Comments   
Comment by Randolph Tan [ 23/Mar/18 ]

Not sure about your exact use case, but if your BSONObj is not const, you can use this constructor to avoid extra copying:

https://github.com/mongodb/mongo/blob/4ca974b2165d74c3a9bdc4a765d445f23aaa2664/src/mongo/bson/bsonobjbuilder.h#L155

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