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

JDK14: Loggers are not serializable

    Details

    • Type: Bug
    • Status: Resolved
    • Resolution: Fixed
    • Affects Version/s: 1.6.x
    • Fix Version/s: None
    • Component/s: Implementations
    • Labels:
      None
    • Environment:

      Operating System: Windows NT
      Platform: PC

      Description

      Scenario: A web application running inside Glassfish 3.1.1.

      To avoid any external dependencies we have settled for using the JDK14 implementation to delegate logging to the web container. Works well.

      To avoid memory issues when redeploying (which happens every time a resource change) we do not use static fields for loggers but instance fields.

      Unfortunately the JDK14Adapter is not serializable which result in that the session object cannot be saved across redeployments, causing the current user to be logged out.

      The attached junit test pass when using slf4j-simple, and fail when using slf4j-jdk14.

        Attachments

          Activity

            People

            • Assignee:
              slf4j-dev SLF4J developers list
              Reporter:
              thorbjoern@gmail.com Thorbjørn Ravn Andersen
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: