Uploaded image for project: 'OpenIDM'
  1. OpenIDM
  2. OPENIDM-14479

Switching to log4J causes unresolved binding in the launcher

    Details

      Description

       

      To reproduce:

      • Remove bundle/slf4j-jdk14–1.7.21.jar
      • Copy slf4j-log4j12-1.7.21.jar and log4j-1.7.21.jar
      • Set LOGGING_CONFIG="-D log4j.configuration=file:///<path to log4j.properties>"
      • Start the server

      Whilst IDM logs correctly to the configured log4j's file, this trace shows in the console:

      SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
      SLF4J: Defaulting to no-operation (NOP) logger implementation
      SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details. 

      Any attempt to alter CLASSPATH in startup.sh ended to a severe error that impedes the logging service.

      This error does not occur in 5.0, so this seems to be a regression.

      Whilst this is a benign error [ it affects only the launcher ], it might still make users uncomfortable.

      Note that the reason to switch to a different logging framework like log4j has benefits such as:

      • Time based file rotation
      • MDC availability in the log4j config, for example, logging transaction IDs on each logging trace 

       

        Attachments

          Activity

            People

            • Assignee:
              brmiller Brendan Miller
              Reporter:
              patrickdiligent patrick diligent
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: