[SERVER-11692] Change Variables implementation in agg to not use string lookup at runtime. Created: 14/Nov/13  Updated: 11/Jul/16  Resolved: 14/Nov/13

Status: Closed
Project: Core Server
Component/s: Aggregation Framework
Affects Version/s: None
Fix Version/s: 2.5.4

Type: Improvement Priority: Major - P3
Reporter: Mathias Stearn Assignee: Mathias Stearn
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Participants:

 Comments   
Comment by Githook User [ 14/Nov/13 ]

Author:

{u'username': u'RedBeard0531', u'name': u'Mathias Stearn', u'email': u'mathias@10gen.com'}

Message: SERVER-11692 step 4: Use Variables::Id to get/set Values

This is what the past 3 commits have been building up to. Variable names are now "compiled away" and
are not used at run-time.
Branch: master
https://github.com/mongodb/mongo/commit/9f5101d6e90e1da2b76423bf2f066107639ba4e0

Comment by Githook User [ 14/Nov/13 ]

Author:

{u'username': u'RedBeard0531', u'name': u'Mathias Stearn', u'email': u'mathias@10gen.com'}

Message: SERVER-11692 step 3: Pass Variables as pointer rather than const ref.

This is just changing the function signatures and callers, not how Variables is used.
Branch: master
https://github.com/mongodb/mongo/commit/1f9ac013237d1b6ba2fa17769d6dac59e515f373

Comment by Githook User [ 14/Nov/13 ]

Author:

{u'username': u'RedBeard0531', u'name': u'Mathias Stearn', u'email': u'mathias@10gen.com'}

Message: SERVER-11692 step 2: use VariablesParseState at parse time

Now we are assigning Ids but still using names to get/set variables at run time. The main
functional change at this point is that we now error at parse time rather than run time if a user
accesses an undefined variable.
Branch: master
https://github.com/mongodb/mongo/commit/06cfa88df67067b7e8108b283a604f0e9169d0a3

Comment by Githook User [ 14/Nov/13 ]

Author:

{u'username': u'RedBeard0531', u'name': u'Mathias Stearn', u'email': u'mathias@10gen.com'}

Message: SERVER-11692 step 1: VariablesParseState plumbing

VariablesParseState isn't yet used, this just pushes it through the parsing so that it can be used
in future commits.
Branch: master
https://github.com/mongodb/mongo/commit/31eba1a06f997491189f3eeade642b02ada85627

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