Uploaded image for project: 'OpenShift Logging'
  1. OpenShift Logging
  2. LOG-5907

Add Trace log level in vector config

XMLWordPrintable

    • Improvement
    • False
    • None
    • False
    • NEW
    • NEW
    • Release Note Not Required
    • Log Collection - Sprint 258

      Add Trace log level in vector config, As by default we don't have Trace level configured in default config of vector.

      if !exists(.level) {
          .level = "default"
          if match!(.message, r'Warning|WARN|^W[0-9]+|level=warn|Value:warn|"level":"warn"|<warn>') {
            .level = "warn"
          } else if match!(.message, r'Error|ERROR|^E[0-9]+|level=error|Value:error|"level":"error"|<error>') {
            .level = "error"
          } else if match!(.message, r'Critical|CRITICAL|^C[0-9]+|level=critical|Value:critical|"level":"critical"|<critical>') {
            .level = "critical"
          } else if match!(.message, r'Debug|DEBUG|^D[0-9]+|level=debug|Value:debug|"level":"debug"|<debug>') {
            .level = "debug"
          } else if match!(.message, r'Notice|NOTICE|^N[0-9]+|level=notice|Value:notice|"level":"notice"|<notice>') {
            .level = "notice"
          } else if match!(.message, r'Alert|ALERT|^A[0-9]+|level=alert|Value:alert|"level":"alert"|<alert>') {
            .level = "alert"
          } else if match!(.message, r'Emergency|EMERGENCY|^EM[0-9]+|level=emergency|Value:emergency|"level":"emergency"|<emergency>') {
            .level = "emergency"
          } else if match!(.message, r'(?i)\b(?:info)\b|^I[0-9]+|level=info|Value:info|"level":"info"|<info>') {
            .level = "info"
              }
        }

       

       

      Due to the Trace log not getting the Trace log level in the logging. 

      11:43:55.614 [http-nio-0.0.0.0-8081-exec-9] TRACE o.s.w.s.m.m.a.RequestMappingHandlerAdapter - Applying default cacheSeconds=-1
      11:43:55.614 [http-nio-0.0.0.0-8081-exec-9] TRACE o.s.web.servlet.DispatcherServlet - No view rendering, null ModelAndView returned.

       

       

              vparfono Vitalii Parfonov
              rhn-support-kirpatil Kiran Patil
              Anping Li Anping Li
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: