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

add log severity and component name to the log message

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor - P4
    • Resolution: Fixed
    • None
    • 2.7.5
    • Logging
    • Server 2.7.4, Server 2.7.5
    • 0

    Description

      New format:

      Log severity is logged with a single capital letter.
      F - Fatal
      E - Error
      W - Warning
      I - Info and Debug Level 0
      D - All debug levels > 0
      Component name is logged in upper-case padded with trailing spaces to fit within 8 characters.
      Default log component is displayed with a hyphen.

      --------------

      It would be immensely useful if the mongo log would contain for each message the given log level. Currently it's almost impossible to do some automatic log querying (for example with logwatch) since you have to manually filter based on regular expressions what could possible be interesting to see. If a log level was saved with the log message, it would be possible to simply grep for 'warning' or 'error'

      Attachments

        Issue Links

          Activity

            People

              benety.goh@mongodb.com Benety Goh
              dominik Dominik Gehl
              Votes:
              12 Vote for this issue
              Watchers:
              19 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: