[SERVER-11125] setProfilingLevel() does not accept zero for slowms parameter Created: 10/Oct/13 Updated: 11/Jul/16 Resolved: 10/Oct/13 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Shell |
| Affects Version/s: | None |
| Fix Version/s: | 2.5.3 |
| Type: | Bug | Priority: | Minor - P4 |
| Reporter: | Benety Goh | Assignee: | Benety Goh |
| Resolution: | Done | Votes: | 0 |
| Labels: | performance, profiling, stats | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||
| Operating System: | ALL | ||||||||||||||||
| Steps To Reproduce: | Start up mongod with default profiling values. > db.getProfilingStatus() { "was" : 1, "slowms" : 100 }The result from db.getProfilingStatus() should be { "was" : 1, "slowms" : 0 } |
||||||||||||||||
| Participants: | |||||||||||||||||
| Description |
|
mongod accepts --slowms=0 but the shell command db.setProfiliingLevel(level, slowms) does not. Can we fix the shell command to support slowms=0? Also, are negative values supported for slowms? This would allow the server to log all queries. |
| Comments |
| Comment by auto [ 10/Oct/13 ] |
|
Author: {u'username': u'benety', u'name': u'Benety Goh', u'email': u'benety@mongodb.com'}Message: |
| Comment by Scott Hernandez (Inactive) [ 10/Oct/13 ] |
|
after chatting I see that the issue is a bit conflated since slowms is used for both logging and database profiling (to system.profile collection) but the current javascript helper simply won't allow putting the value to 0 without calling the command manually ( {profile:lvl, slowms:0}). |
| Comment by Scott Hernandez (Inactive) [ 10/Oct/13 ] |
|
If this is to set slowms outside of the db profiling then I think we want a new helper or overload. |
| Comment by Benety Goh [ 10/Oct/13 ] |
|
I should clarify that this is to allow the mongod process to log all queries (assuming the user is aware of the performance hit). |
| Comment by Scott Hernandez (Inactive) [ 10/Oct/13 ] |
|
Level 2 logs all operations. slowms=0 should not do this (it should really be disallowed in the command line opt) http://docs.mongodb.org/manual/tutorial/manage-the-database-profiler/#profiling-levels |