[SERVER-5722] Support a 'sort' field in ops array for JS Benchmarking Harness Created: 30/Apr/12 Updated: 18/Mar/21 Resolved: 09/Mar/21 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Testing Infrastructure |
| Affects Version/s: | None |
| Fix Version/s: | 4.9.0, 4.4.5, 4.0.24, 3.6.24, 4.2.14 |
| Type: | New Feature | Priority: | Trivial - P5 |
| Reporter: | A. Jesse Jiryu Davis | Assignee: | Ian Boros |
| Resolution: | Done | Votes: | 2 |
| Labels: | benchRun, neweng, tig-benchrun | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||||||
| Backport Requested: |
v4.4, v4.2, v4.0, v3.6
|
||||||||||||||||||||
| Sprint: | Query Execution 2021-03-22 | ||||||||||||||||||||
| Participants: | |||||||||||||||||||||
| Description |
|
benchRun supports limit, skip, and batchSize, but not sort: http://www.mongodb.org/display/DOCS/JS+Benchmarking+Harness https://github.com/mongodb/mongo/blob/master/src/mongo/scripting/bench.cpp#L455 |
| Comments |
| Comment by Githook User [ 10/Mar/21 ] | |||
|
Author: {'name': 'Ian Boros', 'email': 'ian.boros@mongodb.com', 'username': 'puppyofkosh'}Message: | |||
| Comment by Githook User [ 10/Mar/21 ] | |||
|
Author: {'name': 'Ian Boros', 'email': 'ian.boros@mongodb.com', 'username': 'puppyofkosh'}Message: | |||
| Comment by Githook User [ 10/Mar/21 ] | |||
|
Author: {'name': 'Ian Boros', 'email': 'ian.boros@mongodb.com', 'username': 'puppyofkosh'}Message: | |||
| Comment by Githook User [ 10/Mar/21 ] | |||
|
Author: {'name': 'Ian Boros', 'email': 'ian.boros@mongodb.com', 'username': 'puppyofkosh'}Message: | |||
| Comment by Ian Boros [ 09/Mar/21 ] | |||
|
david.daly The changes to mongo-perf that I intend to make rely on supporting this 'sort' field. So I believe we'll have to backport this all the way. I've looked into this, and it seems like applying my change will be pretty straightforward (though not just a git cherry-pick). | |||
| Comment by Githook User [ 08/Mar/21 ] | |||
|
Author: {'name': 'Ian Boros', 'email': 'ian.boros@mongodb.com', 'username': 'puppyofkosh'}Message: | |||
| Comment by David Daly [ 02/Oct/17 ] | |||
|
Updating the link I put before to tie it to a commit. I said it would fit here. | |||
| Comment by David Storch [ 18/Nov/16 ] | |||
|
david.daly, yep, that sounds right to me. | |||
| Comment by David Daly [ 18/Nov/16 ] | |||
|
david.storch kyle.suarez Would the addition fit here (that's FindOne. Also for find) for the readCmd path, and create something similar to our current work around for the non readCmd path? | |||
| Comment by Kyle Suarez [ 17/Nov/16 ] | |||
|
Having this would be especially helpful for the views project. They require --readCmd true to work properly, so we cannot apply a views passthrough to existing query tests that rely on the $query example that Dan mentioned, since that's not supported in read commands. | |||
| Comment by David Storch [ 07/Oct/16 ] | |||
|
Despite the workaround above for legacy OP_QUERY find, my reading of the shell's implementation of benchRun in the master branch suggests that neither a "sort" nor an "orderby" field is supported when find command is enabled via the readCmd option. It would be useful to support this option in a general way for both find command and legacy OP_QUERY, so I am re-opening this ticket for consideration by the performance infrastructure team. | |||
| Comment by Daniel Pasette (Inactive) [ 18/Jun/15 ] | |||
|
You can add a sort by adding an orderBy clause into the query document.
|