Logback Changelog

What's new in Logback 1.1.3

Mar 25, 2015
  • All logback modules now require JDK 1.6 instead of previously JDK 1.5. This change was put to consultation on the logback mailing lists with no objections raised.
  • Fixed FileAppender's prudent mode so that it properly recovers from IO Errors (LOGBACK-1046)
  • Irrelevant or internal stack trace lines can now be omitted. Pull request provided by Tomasz Nurkiewicz (LOGBACK-540).
  • AccessEvent now creates a copy of request attributes when its prepareForDeferredProcessing() method is called. This makes attributes visible even if an appender uses a background thread to process events. (LOGBACK-1033)
  • All threads opened by ch.qos.logback.core.util.ExecutorServiceUtil#THREAD_FACTORY are now daemons, which fixes an application hang on shutdown when LoggerContext#stop() is not called (LOGBACK-929). Note that daemon threads are abruptly terminated by the JVM, which may cause undesirable results, such as corrupted files written by the FileAppender. It is still highly recommended for the application to call LoggerContext#stop() (e.g., in a shutdown hook) to gracefully shutdown appenders.
  • Fixed an issue with RollingFileAppender where the first rollover file could be unintentionally deleted, depending on the specified filename pattern (LOGBACK-894).
  • Fixed an issue with TeeHttpServletResponse where the system default encoding would be used instead of the response encoding when constructing a new writer (LOGBACK-1023).
  • Fixed ConfigurationDelegate.groovy to allow any appender that implements AppenderAttachable, which supports third-party appenders, such as reactor-logback's AsyncAppender (LOGBACK-1008)
  • Added support for specifying the callstack depth range in the PatternLayout. For example, �ller{1..2} displays the first two calls in the callstack.
  • Added HTTP request method to MDCInsertingServletFilter.
  • Fixed time-zone dependent code in RollingCalendarTest. (LOGBACK-116)
  • Simplified connection logic of SocketApender to reduce multi-threading overhead and unnecessary instantiation of SocketConnector objects.
  • Fixed race condition in SMTPAppenderBase causing missing or duplicate emails. (LOGBACK-909)
  • Fixed an issue with FileAppender in prudent mode, where an interrupt could prevent further access to the file (LOGBACK-875).
  • Fixed IllegalStateException when multiple threads write files to same directory (LOGBACK-128).
  • Changed queue consumption strategy in AbstractSocketAppender from "take" to "peek/remove" in order to avoid losing an event on each socket connection break. Zero is now a deprecated queue size. A queue size of one should be taken instead to indicate synchronous processing. (LOGBACK-977)
  • RequestLogImpl now has an overridable configure method to allow extending implementations to configure it via methods other than the logback-access.xml file.
  • Fixed a bug in AccessEvent which could cause any AsyncAppender based appender to corrupt the request headers, request parameters, or response headers, before logging.
  • SQL scripts to setup your logback database are now provided as JAR resources (LOGBACK-948).
  • Threads created internally by logback are now named logback-n, where n is an integer. For the first thread n is set to 1, for each successive thread n is incremented by 1.
  • Added max runtime parameter to AsyncAppender to allow the appender to flush events, up to a maximum delay, during a stop of the LoggerContext. This can be used to ensure that all queued events are flushed.
  • Added new configuration element shutdownHook to allow the user to specify a ShutdownHook implementation that will stop the Logback context upon JVM exit.
  • BasicStatusManager now prevents adding more than one instance of OnConsoleStatusListener as a status listener. This fixes LOGBACK-976.
  • TimeBasedRollingPolicy now accepts a time zone in its %d conversion pattern. (LOGBACK-611)
  • It is now possible to configure the character encoding used by SyslogAppender to encode messages using the setCharset() method. This fixes LOGBACK-732

New in Logback 1.0.13 (Oct 22, 2013)

  • In logback-access MANIFEST file, imports of Jetty and Tomcat are now optional. This fixes LOGBACK-300 reported by Christian Brensing who also provided the appropriate pull request.
  • Logback will now correctly parses variables with a default separator string nested within accolades, e.g. "{a:-b}". Such strings resemble variable references but lack the $ prefix, e.g "${a:-b}". This fixes LOGBACK-859 reported by Yoni Moses.
  • In InterpretationContext class replaced code using JDK 1.6 API with code using JDK 1.5. This fixes LOGBACK-860 reported by Bas Stoker.
  • Updated the "org.fusesource.jansi:jansi" dependency to version 1.9.

New in Logback 1.0.1 (Mar 12, 2012)

  • etting the debug attribute to true in the element now registers a OnConsoleStatusListener with the StatusManager. Thus, problems occurring during the lifetime of your application, well after logback is initialized, can be reported when the debug attribute is set. This behavior is closer to what users expect.
  • Added new property the cleanHistoryOnStart to TimeBasedRollingPolicy. By setting this property to true, history removal will work as expected even in the case of short lived applications. This fixes LBCORE-226 reported by Bruce E. Irving.
  • It is now possible to specify multiple %d tokens in the file name pattern of TimeBasedRollingPolicy. Auxiliary %d tokens must be marked as such by passing the AUX paramater. This feature was requested in LBCORE-242 by Thomas Corte.
  • Logback now supports suppressed exceptions introduced in Java 7. This fixes LBCLASSIC-276.
  • SMTPAppender clears the relevant cyclic buffer before asynchronous transmission. This corrects LBCLASSIC-221 as reported by Chris Cheshire.
  • SiftingAppender will consider stale and consequently remove nested appenders which are closed or improperly started. This caters for the use case described in LBCLASSIC-316 by Guus Bloemsma.
  • RequestLogImpl can now lookup for the logback-access configuration file as a class path resource. This feature was requested in LBACCESS-26 by Marshall Pierce.
  • Updated the Janino dependency to version 2.5.16. In addition, the code checking for the availability of Janino on the class path was updated to take Janino 2.6 into account, thus fixing LBCORE-210.

New in Logback 0.9.24 (Aug 4, 2010)

  • Fixed NullPointerException thrown by MDCBasedDiscriminator in case the MDC map is null.
  • Fixed issue with SizeAndTimeBasedFNATP in presence of application stop/restart and non-null file proprety. This issue was reported by Tom Liu in LBCORE-131.