[SERVER-10159] Evaluate performance of new update framework and first pass optimization Created: 10/Jul/13  Updated: 11/Jul/16  Resolved: 29/Jan/14

Status: Closed
Project: Core Server
Component/s: Internal Code, Write Ops
Affects Version/s: None
Fix Version/s: 2.5.5

Type: Task Priority: Major - P3
Reporter: Alberto Lerner Assignee: Andy Schwerin
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: File mms.js     File mms_array.js     File trivial_inc.js    
Issue Links:
Related
related to SERVER-10357 An update $push with sort is slower t... Closed
is related to SERVER-10595 Replicating many array operations is ... Closed
Backwards Compatibility: Fully Compatible
Participants:

 Description   

Profile the new framework against the existing and adjust performance to at least the same level, if necessary.



 Comments   
Comment by Githook User [ 12/Feb/14 ]

Author:

{u'username': u'andy10gen', u'name': u'Andy Schwerin', u'email': u'schwerin@10gen.com'}

Message: SERVER-10159 Remove extraneous NamespaceString in instance.cpp.
Branch: master
https://github.com/mongodb/mongo/commit/df79d68a7fec7032361146acdc1abfb85e26de22

Comment by Andrew Morrow (Inactive) [ 28/Jan/14 ]

Attached is the array version of mms.js.

Comment by Githook User [ 22/Jan/14 ]

Author:

{u'username': u'andy10gen', u'name': u'Andy Schwerin', u'email': u'schwerin@10gen.com'}

Message: SERVER-10159 Avoid constructing a CanonicalQuery for IdHackRunner or id-hack updates.

Neither the IdHackRunner nor id-hack updates need a canonical query. This change avoids
constructing them, providing some moderate performance improvement for id-hack updates. Simple,
shallow updates, like incrementing a top-level counter in a small document see an improvement of
5-6k ops per second, or around 4.5-6% over master (which constructs canonical queries outside the
write lock for these updates). For more complicated updates in a write-only workload, the
performance improvement drops off with the complexity of the update.
Branch: master
https://github.com/mongodb/mongo/commit/544f130753c04b83397ff156cca873273c7977f2

Comment by Githook User [ 17/Jan/14 ]

Author:

{u'username': u'andy10gen', u'name': u'Andy Schwerin', u'email': u'schwerin@10gen.com'}

Message: SERVER-10159 In receivedUpdate, parse CanonicalQuery outside DB Write lock.
Branch: master
https://github.com/mongodb/mongo/commit/1fa665f79dcc84eacbfe1f0a0cebcd75a93d4aa4

Comment by Githook User [ 07/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Only do rematch for positional data when necessary
Branch: master
https://github.com/mongodb/mongo/commit/8b57f45b149b9df8ed2e9d7f74bf5d33a650cd5c

Comment by Githook User [ 07/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Use StringMap to avoid string copies when finding a collection
Branch: master
https://github.com/mongodb/mongo/commit/f4c05fbb804842a449e8131784069c2757ab2b23

Comment by Githook User [ 05/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Only track doc locations on a multi update
Branch: master
https://github.com/mongodb/mongo/commit/c8c1dfc29da5f2232f17865fb4cb0d94ed1da2da

Comment by Githook User [ 05/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Re-use Collection and index data structures rather than re-acquiring or copying
Branch: master
https://github.com/mongodb/mongo/commit/1d0ac3e882c6323fc99fb98c861629caf8e3918e

Comment by Githook User [ 05/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Store the FieldRef for _id in a file static to avoid a dynamic allocation
Branch: master
https://github.com/mongodb/mongo/commit/344b86426595713e32fefa2e5a627988b04529fb

Comment by Githook User [ 05/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Also cache field name lengths for leaf elements
Branch: master
https://github.com/mongodb/mongo/commit/7829e62e06559b75c6121e0486d4f1769f4dbfa6

Comment by Githook User [ 05/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Do slightly less work when resetting or destroying a mutable Document
Branch: master
https://github.com/mongodb/mongo/commit/a1ebb6624c8b17438f84392638639d874a789392

Comment by Githook User [ 05/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Size internal document data structures appropriately to common use cases
Branch: master
https://github.com/mongodb/mongo/commit/42dce2cb1debd7c6b73aba01d9e038c41726a530

Comment by Githook User [ 05/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Hoist document construction above write lock by storing in driver
Branch: master
https://github.com/mongodb/mongo/commit/cc350cdb65f90070ee45b83cf27d47a610a55b08

Comment by Githook User [ 02/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Don't validate and normalize an empty sort
Branch: master
https://github.com/mongodb/mongo/commit/b71af1bc88e0ee2bab90d1f2a7400dc65649e087

Comment by Githook User [ 02/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Be more efficient with runner registration
Branch: master
https://github.com/mongodb/mongo/commit/44abf68eeab7e40557fc3e2358030584d34163ac

Comment by Githook User [ 02/Jan/14 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Keep runner registration management on the stack when possible
Branch: master
https://github.com/mongodb/mongo/commit/da176cb44bbfcaff5c1cbd59d8866f3cf7cc791d

Comment by Githook User [ 17/Dec/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Cache field name lengths in mutable elements
Branch: master
https://github.com/mongodb/mongo/commit/d73db8af612528d5dff98f0112a24edf36c085e6

Comment by Andrew Morrow (Inactive) [ 11/Oct/13 ]

Moved out of SERVER-6399 to its own task. The exit criteria for this ticket are as follows:

  • Implement all known performance regressions as tests in mongoperf.
  • Get known performance regressions to parity or better.
Comment by auto [ 25/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Avoid forming past end iterator when reserializing
Branch: master
https://github.com/mongodb/mongo/commit/7f9402ad7a5d5c741636f04ce1dbdf48b076d65a

Comment by auto [ 25/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Don't perform update field conflict detection when no conflict is possible
Branch: master
https://github.com/mongodb/mongo/commit/2f23c6ecb941d94fa7705475f47634ee57205e82

Comment by auto [ 25/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Improve the efficiency of constructing new ElementRep structures
Branch: master
https://github.com/mongodb/mongo/commit/03095b15c71886456ac46a315ea03614bb7aced4

Comment by auto [ 25/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Re-serialize and cache dotted form in FieldRef on request
Branch: master
https://github.com/mongodb/mongo/commit/4616eae3efe8301ac12574bfc7c6d54338b58bd7

Comment by auto [ 24/Sep/13 ]

Author:

{u'username': u'alerner', u'name': u'Alberto Lerner', u'email': u'alerner@10gen.com'}

Message: SERVER-10159 Embed some number of ElementReps in the Document.
Branch: master
https://github.com/mongodb/mongo/commit/e87726c246e50c05739bbb8f8ccfbb43384397ea

Comment by auto [ 23/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Don't rewrite document if all mods are no-ops.
Branch: master
https://github.com/mongodb/mongo/commit/234f50a33cd6d2a2e0a30c4b1bddb1c7de176799

Comment by auto [ 20/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Don't 'done' the BSONObjBuilder right before we call its destructor
Branch: master
https://github.com/mongodb/mongo/commit/46221d91b40b62d60182e389c2e4fcf7b3c75118

Comment by auto [ 13/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Fix invalid dereference of end iterator while parsing invalid field names
Branch: master
https://github.com/mongodb/mongo/commit/2110a136ef89f761928014364acef203d1feca4e

Comment by auto [ 12/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Don't declare storage for static integral constants

This should work, but MSVC was getting multiple definition errors when linking element.o and
document.o. I think MSVC is wrong here, but since we don't ever take the address of these
constants, we can get away without declaring storage.
Branch: master
https://github.com/mongodb/mongo/commit/767a1420151cd6749c6a402e71ba19a326fbd2d1

Comment by auto [ 12/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Expand universe of types eligible for in-place update

Eligibility criteria are that type be a leaf type, non-deprecated, carries payload data (e.g
not null or undefined), and is not structurally complex (e.g. code with scope), and has some
likelihood of sharing layout.
Branch: master
https://github.com/mongodb/mongo/commit/8ac3b7789b45edf72516834426119da565edbfac

Comment by auto [ 12/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Retain concatenated dotted path and return it that way when possible.
Branch: master
https://github.com/mongodb/mongo/commit/917adade854b8301e5956d37093db02b1a248070

Comment by auto [ 12/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Always obtain BSONElement field names as StringData
Branch: master
https://github.com/mongodb/mongo/commit/a6177c60770d8612bf13118b72be2ecdcd23f0fc

Comment by auto [ 12/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Don't acquire rep just to check type when resolving
Branch: master
https://github.com/mongodb/mongo/commit/f1d9169054bbc24e4823761049211ab307417875

Comment by auto [ 12/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Elements never have null Document pointers
Branch: master
https://github.com/mongodb/mongo/commit/8abc4f2f2562bc10bbebfe32c9afadf8d1da3707

Comment by auto [ 12/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Inline Element::OK and Document::end; they are called often
Branch: master
https://github.com/mongodb/mongo/commit/19e7f781a2b76e523344a3fe1d55987fd5c96395

Comment by auto [ 12/Sep/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Reuse damage vector across object updates
Branch: master
https://github.com/mongodb/mongo/commit/0d6d7f72126ab8924d44ea1bfa7d647dd05ddd6c

Comment by auto [ 07/Aug/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Hoist modifier parsing out of the write lock for update
Branch: master
https://github.com/mongodb/mongo/commit/d11c7e78d447882b05e993ce60e311e9db959087

Comment by auto [ 01/Aug/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 Re-use Document objects during update loop and logging
Branch: master
https://github.com/mongodb/mongo/commit/51af8d67570b33fa5d5b4d36b18215535d38dd85

Comment by auto [ 23/Jul/13 ]

Author:

{u'username': u'acmorrow', u'name': u'Andrew Morrow', u'email': u'acm@10gen.com'}

Message: SERVER-10159 SERVER-10275 Simplify field name and in-place update support in mutable
Branch: master
https://github.com/mongodb/mongo/commit/32ecefa73b82c45dd40701cbd64275fbfed11e4c

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