[SERVER-27576] MongoDB 3.4 'mongo' shell quit() not working Created: 04/Jan/17 Updated: 08/Jan/24 Resolved: 12/Jan/17 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Shell |
| Affects Version/s: | 3.4.0, 3.4.1 |
| Fix Version/s: | 3.4.2, 3.5.2 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Tim Vaillancourt | Assignee: | Jonathan Reams |
| Resolution: | Done | Votes: | 1 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||||||
| Operating System: | ALL | ||||||||||||||||||||
| Backport Requested: |
v3.4
|
||||||||||||||||||||
| Steps To Reproduce: |
|
||||||||||||||||||||
| Sprint: | Platforms 2017-01-23 | ||||||||||||||||||||
| Participants: | |||||||||||||||||||||
| Description |
|
Hey guys, Hopefully this isn't a duplicate. On MongoDB 3.4.0 and 3.4.1 I am noticing the 'quit()' shell function no longer works. The function still exists in the shell but does nothing. I have confirmed this does not occur when using the 3.2.11 'mongo' shell. I have reproduced this with several server versions and the problem seems to be unrelated to the server version. Issue repro using 3.4.1 'mongo' shell (had to CTRL+C to quit the shell):
To compare, 3.2.11 is working as expected:
And 3.0 is working too:
|
| Comments |
| Comment by Githook User [ 18/Jan/17 ] |
|
Author: {u'username': u'jbreams', u'name': u'Jonathan Reams', u'email': u'jbreams@mongodb.com'}Message: (cherry picked from commit f3d5da919580d6ab7a332fab604b056451994af3) |
| Comment by Githook User [ 12/Jan/17 ] |
|
Author: {u'username': u'jbreams', u'name': u'Jonathan Reams', u'email': u'jbreams@mongodb.com'}Message: |
| Comment by Jonathan Reams [ 09/Jan/17 ] |
|
I talked to mira.carey@mongodb.com about this, and we were checking the quickExit flag in the proxyscope because we need to be able to free the implscope before calling quickExit to satisfy the ASAN. |
| Comment by Jonathan Reams [ 06/Jan/17 ] |
|
I dug into this a bit, and it seems that the reason is that we depend on the ProxyScope to actually check whether a quit has been requested and then call quickExit, and in 3.4 we stopped using a ProxyScope for the shell's main javascript scope. I'm not sure why we don't just quick exit from within the quit() function and do this dance of setting flags and checking them later. |
| Comment by Eric Milkie [ 04/Jan/17 ] |
|
Thanks for reporting this – the quit command is indeed broken! For a workaround (other than using an older shell version), you can use CTRL-C, CTRL-D, or the "exit" command. |