Uploaded image for project: 'SLF4J'
  1. SLF4J
  2. SLF4J-378

Allow manual override of StaticLoggerBinder in LoggerFactory

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Core API
    • Labels:
      None

      Description

      For certain environments (unit tests in my case) it is desirable to set a fixed logging backend despite other binders being present. Therefore I propose to amend LoggerFactory to contain an optional reference to StaticLoggerBinder instance, which (when non-null) would be used instead of normal StaticLoggerBinder.getSingleton(); therefore this overriding instance could reside in different package. It would suppress checks for multiple binders as well.

        Attachments

          Activity

            People

            • Assignee:
              slf4j-dev SLF4J developers list
              Reporter:
              bbobcik Boleslav Bobcik
            • Votes:
              2 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: