[SERVER-18505] MapReduce scope variables do not get cleaned up Created: 16/May/15 Updated: 17/May/15 Resolved: 17/May/15 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | MapReduce |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Jeroen Ooms [X] | Assignee: | Unassigned |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Operating System: | ALL | ||||||||
| Steps To Reproduce: | //some random data ) //error //success db.test.mapReduce(function(){foo == true} , function(){}, {out: {inline:1}, scope:{foo:true}}) //succeeds , function(){}, {out:{inline:1}}) |
||||||||
| Participants: | |||||||||
| Description |
|
It looks like any variables that are passed as part of the MapReduce 'scope' argument will linger around forever on the server, potentially affecting any future MapReduce commands. Is this intended behavior? I was under the impression that MapReduce functions were implemented as closures around the scoped environment, which would naturally clean the variables once they go out of scope. |
| Comments |
| Comment by J Rassi [ 17/May/15 ] | |||||||||||
|
Hi, Thanks for the report. This is a known issue, described in I'm closing this ticket as duplicate. ~ Jason Rassi | |||||||||||
| Comment by Jeroen Ooms [X] [ 16/May/15 ] | |||||||||||
|
Jira messed up the markup. Below the example:
|