Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-26877

Unify logging with log4j2

    XMLWordPrintable

    Details

      Description

      Since we introduced log4j2 we want to remove usage of Apache Commons Logging and SLF4J APIs and unify all logging to use log4j2 API.

      Then, we could probably remove our dependencies to these logging API (without removing their bridges to log4j2).

      For example from :

      import org.apache.commons.logging.Log;
      import org.apache.commons.logging.LogFactory;
      [...]
      public static final Log log = LogFactory.getLog(RunConverter.class);
      

      or

      import org.slf4j.Logger;
      import org.slf4j.LoggerFactory;
      [...]
      private static final Logger LOG = LoggerFactory.getLogger(NuxeoCmisBrowserBindingServlet.class);
      

      to :

      import org.apache.logging.log4j.LogManager;
      import org.apache.logging.log4j.Logger;
      [..]
      private static final Logger log = LogManager.getLogger(BulkDownload.class);
      

      This could also be the moment to get rid of the isInfoEnabled/isDebugEnabled/isTraceEnabled calls by replacing them to lambda evaluation where it is possible.

        Attachments

          Issue Links

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved: