[SERVER-6861] pipeline parser allows multiple pipeline stage fields in a stage spec object, uses the last one only instead of triggering a parse error Created: 27/Aug/12 Updated: 11/Jul/16 Resolved: 10/Sep/12 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Aggregation Framework, Usability |
| Affects Version/s: | None |
| Fix Version/s: | 2.3.0 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Aaron Staple | Assignee: | Aaron Staple |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||
| Operating System: | ALL | ||||
| Participants: | |||||
| Description |
|
Observed behavior: If multiple pipeline stages are specified in a single object (eg. { $project: { ... }, $sort:{ ... }}, the last one is used and earlier ones are dropped. Expected behavior: Only one pipeline stage spec is allowed in a pipeline spec object. Otherwise a parse error is triggered. Currently multiple pipeline stages are properly specified as separate objects within an array (eg. [ { $project: { ... } }, { $sort:{ ... }} ] ). Test
|
| Comments |
| Comment by auto [ 09/Sep/12 ] |
|
Author: {u'date': u'2012-09-09T14:07:03-07:00', u'email': u'aaron@10gen.com', u'name': u'Aaron'}Message: SERVER- |
| Comment by Aaron Staple [ 27/Aug/12 ] |
|
This is a usability concern, as someone can easily mess up and write their aggregation spec incorrectly. And they won't get an error. |