Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-16755

Global severity seems to overwrite component severity in some cases

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: 2.8.0-rc4
    • Fix Version/s: 2.8.0-rc5
    • Component/s: Logging
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Steps To Reproduce:

      Description

      When setting the QUERY component log level to 1, I would expect to see all QUERY messages that I would normally see at global log level 1. This doesn't seem to be the case.

      1. run mongod 2.8.0-rc4
      2. insert doc in collection: db.foo.insert({a: 1})
      3. set QUERY component log level to 1: db.setLogLevel(1, "query")
      4. make a query: db.foo.find({a: 1})

      The query does not show up in the log.

      Is my expectation wrong? I would expect this line to be logged:

      2015-01-07T22:37:20.706+1100 I QUERY    [conn3] query test.foo query: { a: 1.0 } planSummary: COLLSCAN ntoreturn:0 ntoskip:0 nscanned:0 nscannedObjects:1 keyUpdates:0 numYields:0  nreturned:1 reslen:53 0ms

      But I only see this line when I increase the global log level to 1, with

      db.setLogLevel(1)

      or any of the other means, e.g. "mongod -v" or the setParameter command.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: