NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
Maven Central
Maven Central, #1227 by repository stars
MongoDB appender for Log4j using the MongoDB 5 driver API.
Latest stable
2.26.1
Last release 4 months ago
01 Jul 2026
Release timing varies
gaps range from 9 days to 6 months
Nearly every release is documented
notes for 12 of 13 stable releases
Nothing withdrawn
no release was ever pulled
9 years old
14 releases · first in 2017
Drag across the ruler to compare, or tap a release to open it.
Remove deprecated org.apache.logging.log4j.core.appender.rolling.action.Duration class.
This release terminates the modularization process of Log4j Core, by moving all the code that uses optional log4j-core dependencies into new modules:
DisruptorBlockinQueue queue factory has been moved to a new log4j-conversant artifact.log4j-compress artifact.
The Gzip and Zip formats are still supported out-of-the-box.log4j-bom to always use the compatible version of the logging bridges.useFqdn configuration attribute to RFC5424 Layout. (#1740)log4j-jdbc to a new log4j-jdbc-jndi module (#1914)log4j-compress module. (#2921)DisruptorBlockingQueue plugin to new log4j-conversant module. (#2914)JAnsiTextRenderer to work without JAnsi library. (#2916)UNIX and UNIX_MILLIS (#3150)ThrowableProxy and its usages (#3047)log4j-bom.org.apache.logging.log4j.core.appender.rolling.action.Duration class.log4j-1.2-api module (#2621)log4j-iostreams module (#2630)apache/logging-parent to version `` (#2598)com.fasterxml.jackson:jackson-bom to version 2.18.1 (#3136)io.fabric8:docker-maven-plugin to version 0.45.1 (#3036)org.apache.commons:commons-compress to version 1.27.1 (#2870)org.apache.commons:commons-csv to version 1.12.0 (#3020)org.apache.commons:commons-dbcp2 to version 2.12.0 (#2342)org.apache.logging.log4j:log4j-api to version 2.24.1 (#3035)org.jctools:jctools-core to version 4.0.5 (#2638)org.jspecify:jspecify to version 1.0.0 (#2750)org.mongodb:bson to version 5.2.1 (#3179)org.springframework.boot:spring-boot-autoconfigure to version 3.3.5 (#3120)org.springframework.cloud:spring-cloud-context to version 4.1.4 (#2733)org.springframework:spring-framework-bom to version 6.1.14 (#3102)Your coding agent can read these notes before it upgrades. Set up the MCP server →
This patch release delivers certain fixes on top of 2.26.0 .
This patch release delivers certain fixes on top of 2.26.0.
createOnDemand behavior of RollingFileAppender to correctly defer file and directory creation until the first log event, while preserving eager creation when disabled. (#2006, #4072)MapMessage to JSON (#4163)MSGID and SD-ID fields of StructuredDataMessage to XML (#4136)equals() and/or hashCode() implementations) (#3933, #4133)ConfigurationSource when loading configuration via URL fails (#4127)KafkaAppender reporting error to error handler even after a successful retry (#4125)Deprecated withers in builder classes in favor of setters. This change improves API consistency with Log4j Core 3 and helps users adapt to the upcomin…
This minor release delivers all the fixes in the [2.25.0, 2.25.4] version range, plus some new fixes, and several other improvements and features.
ConfigurationFactory::getConfiguration method accepting multiple URIs (#3775, #3921)org.apache.logging.log4j.core.pattern.NamedInstantPattern enabling users to programmatically access named date & time patterns supported by Pattern Layout (#3789)log4j.plugin.processor.minAllowedMessageKind annotation processor option to PluginProcessor to filter diagnostic messages by severity. This allows builds that treat compiler notes as errors (e.g. Maven with -Werror) to suppress informational notes emitted during normal plugin processing. (https://github.com/apache/logging-log4j2/discussions/3380[#3380], #4063)Rfc5424LayoutBuilderScripts element have explicit names by throwing a ConfigurationException for unnamed ones. (#3176)Scripts element is placed after a ScriptRef in the configuration. (#3336)ArrayIndexOutOfBoundsException thrown by ThrowableStackTraceRenderer when the stack trace is modified concurrently (#3940, #3955)SLF4JLogger.atFatal() returning atLevel(Level.TRACE) instead of atLevel(Level.FATAL). This was causing FATAL-level log events to be silently discarded when using the fluent API through the log4j-to-slf4j bridge. (#4068, #4089)RollingRandomAccessFileManager that was being incorrectly skipped if append=true and the file didn't exist beforejvmrunargs lookup. (#3874)This patch release delivers certain fixes on top of 2.25.4
This patch release delivers certain fixes on top of 2.25.4
createOnDemand behavior of RollingFileAppender to correctly defer file and directory creation until the first log event, while preserving eager creation when disabled. (#2006, #4072)MapMessage to JSON (#4163)MSGID and SD-ID fields of StructuredDataMessage to XML (#4136)equals() and/or hashCode() implementations) (#3933, #4133)ConfigurationSource when loading configuration via URL fails (#4127)KafkaAppender reporting error to error handler even after a successful retry (#4125)This patch release delivers fixes for configuration inconsistencies and formatting issues across several layouts.
This patch release delivers fixes for configuration inconsistencies and formatting issues across several layouts.
The authoritative list of recognized configuration attributes is available in the PluginReference.
null. (#3975, #4014)Rfc5424Layout parameter names. (#4022, #4074)Throwable#toString() into account while rendering stack traces in Pattern Layout. (#3623, #4033)Loader class. (#4058, #4060)SslConfiguration factory method usage with Log4j 2.12+ API. The verifyHostname attribute is now correctly recognized. (#4061, #4075)JsonWriter. (#4080)This patch release addresses issues detailed in the changelog below. In particular, it includes an important fix for the host name verification in SSL
This patch release addresses issues detailed in the changelog below. In particular, it includes an important fix for the host name verification in SSL/TLS configuration. This is used by Socket Appender.
DefaultThreadContextMap.getCopy() performance by avoiding megamorphic calls in HashMap constructor (#3935, #3939)SslConfiguration (#3947, #3953)This patch release addresses certain minor issues detailed in the changelog.
This patch release addresses certain minor issues detailed in the changelog.
LogBuilder in Log4j API to Logback bridge (#3819, #3824)AbstractDriverManagerConnectionSource (#3828, #3831)log4j-core (#3835, #3851)Target value in Console Appender (#3852)RollingFileManager (#3068, #3872)com.google.errorprone:error_prone_annotations dependency whose version property gets erased due to flattening (#3779, #3785, #3822, #3905)Throwable converters inside nested Pattern Layout patterns when applying alwaysWriteExceptions (#3920)InstantPatternDynamicFormatter (#3930, #3932)This patch release addresses a dozen bugs in version 2.25.0 , in particular:
This patch release addresses a dozen bugs in version 2.25.0, in particular:
spotbugs-annotations to resolve Gradle build failures. (#3754)jspecify and error_prone_annotations dependencies in published POM files. (#3758, #3779)LoggerContext.start method. (#3770)-Alog4j.graalvm.groupId and -Alog4j.graalvm.artifactId arguments when building Log4j plugins. (#3771)Import-Package constraints to support Jakarta Servlet API up to version 6. (#3787)resource: protocol for configuration files by default when running on GraalVM. (#3790)log4j2.enabledThreadlocals is true. (#3792)@Nullable String[]. (#3796)PropertiesConfiguration compatibility issues with GraalVM and address additional minor reflection-related problems. (#3800)…and FastDateFormat . These are now deprecated in favor of Java’s standard DateTimeFormatter .
This minor release introduces bug fixes, behavior improvements, and complete support for GraalVM native image generation.
Log4j Core and all extension modules now include embedded
GraalVM reachability metadata,
enabling seamless generation of native images with GraalVM out of the box—no manual configuration required.
For more information, refer to our GraalVM guide.
Note
When building third-party Log4j plugins, using the new GraalVmProcessor
introduced in version 2.25.0 will automatically generate the required reachability metadata for GraalVM native images.
However, the processor will fail the build if the required log4j.graalvm.groupId and log4j.graalvm.artifactId parameters are not provided.
For detailed instructions, see Registering plugins.
Exception handling in Pattern Layout has undergone a significant rewrite.
This update resolves several bugs and ensures consistent behavior across all exception converters.
Key improvements include:
{ansi} option in exception converters has been removed.Log4j has historically provided custom date and time formatters for performance, such as FixedDateFormat and FastDateFormat.
These are now deprecated in favor of Java’s standard DateTimeFormatter.
If you encounter formatting issues after upgrading—particularly with n or x directives—you can temporarily revert to the legacy formatters by setting the log4j2.instantFormatter property to legacy.
Please report any issues via our issue tracker.
Modern Windows versions (10 and newer) provide native ANSI escape sequence support.
As a result, dependency on the outdated JAnsi 1.x library has been removed.
For details, refer to ANSI styling on Windows.
A Jakarta-compatible version of the JMS Appender is now included in the core distribution.
GraalVmProcessor annotation processor to generate GraalVM reachability metadata. (#3053)MonitorResource configuration option to support the monitoring of external files in addition to the configuration file itself. (#3074, #3501)collectionName and databaseName arguments to the MongoDB appender (#3467)JAnsiTextRenderer to work without JAnsi library. (#2916)DateTimeFormatter for date & time formatting of log event instants (#3121, #2943)SystemClock. (#3217)GcpLayout.json to improve compatibility with Google Cloud Logging (#3586)java.util.Base64 in Base64Util instead of reflection (#3686)LogEvent.toImmutable(), ReusableMessage.memento(), and remove ThrowableProxy usageThrowableProxy and all its usages (#2691, #3123)AbstractLogger.checkMessageFactory() (#2936)FixedDateTime, FastDateTime, and supporting classes (#3121)Loggers in LoggerRegistry. (#3143)RollingFileManager to reopen file on unsuccessful rollover (#2592)SSLContext instantiation for TLS (#2767)putAll() in thread context map (#2942)getLogger() compatibility in log4j-1.2-api (#3030)log4j-bom (#3066, logging-parent#265)o.a.l.Priority to Log4j 2 Level conversion (#3085)Logger.getLevel() and Logger.setLevel() (#3119)AsyncWaitStrategyFactoryConfig validation (#3159)rootLogger = LEVEL syntax (#3206)ArrayIndexOutOfBoundsException in JSON Template Layout (#3212)replacement in RegexReplacement (#3215)AsyncAppender and FailoverAppender (#3257)isFiltered() (#3300)Level converter documentation (#3359)RecyclerFactoryConverter loading in JSON Layout (#3398)InternalLoggerRegistry locking and clean up stale entries (#3399, #3430, #3681)shutdownDisable config (#2614)ArrayIndexOutOfBoundsException in StatusData#getFormattedStatus (#3562)SecurityManager (#3639)ArrayIndexOutOfBoundsException in Message.getFormattedMessage() (#3655)stderr by default (fixes regression in 2.23.0) (#3665)equals() between ReadOnlyStringMap implementations (#3669)JsonWriter{ansi} option in Pattern Layout exception converters (#3045)actions/stale to 9.1.0 (#3625)logback-core to 1.3.15 (#3354)jackson-bom to 2.19.0 (#3708)spotbugs-annotations to 4.9.3 (#3545)docker-maven-plugin to 0.46.0 (#3592)cassandra-all to 3.11.19 (#3440)commons-csv to 1.14.0 (#3559)commons-dbcp2 to 2.13.0 (#3271)commons-pool2 to 2.12.1 (#3422)kafka-clients to 3.9.1 (#3678)logging-parent to 12.1.1tomcat-juli to 10.1.30 (#2999)jetty-util to 9.4.57.v20241219 (#3377)jmdns to 3.6.1 (#3544)bson to 5.5.1 (#3722)slf4j-api to 2.0.17 (#3499)spring-cloud-context to 4.3.0 (#3700)This release fixes two minor bugs.
This release fixes two minor bugs.
ConcurrentModificationException, if multiple threads modify loggers concurrently.PropertiesUtil against property sources that call PropertiesUtil recursively.This release fixes a critical bug in Log4j API initialization code, which can cause LogManager.getLogger() to return null under certain conditions. Se
This release fixes a critical bug in Log4j API initialization code, which can cause LogManager.getLogger() to return null under certain conditions. See #3143 for details.
This release contains mainly bug fixes of problems encountered with the thread context map, logger registry and configuration reloading.
This release contains mainly bug fixes of problems encountered with the thread context map, logger registry and configuration reloading.
It also enhances integration tests to use Docker images of the most recent releases of MongoDB and Elastic Search.
LoggerRegistry to make it MessageFactory-namespaced.
This effectively allows loggers of same name, but different message factory. (#2936)putAll() in the default thread context map implementation (#2942)org.apache.logging:logging-parent to version 11.3.0Centralize initialization in the Provider class and deprecate log4j2.loggerContextFactory property.
The 2.24.0 version of Log4j API has been enhanced with changes from the 3.x branch and will be used by both Log4j 2 Core and Log4j 3 Core releases. The changes include:
ThreadContextMap.The Apache Log4j 2 website has been almost entirely rewritten to provide improved documentation and faster access to the information you need.
The JUL-to-Log4j API and Log4j 1-to-Log4j API bridges will no longer be able to modify the configuration of Log4j Core by default. If such a functionality is required, it must be explicitly enabled.
The following Log4j Core additional modules have been removed:
log4j-flume-ng
The module is no longer part of the release process and will follow its own release lifecycle.
Please manage your dependencies using log4j-bom to always use its latest version.
log4j-kubernetes
The module has been moved to the Fabric8.io Kubernetes project and follows the Fabric8.io release lifecycle.
log4j-mongodb3
The module based on MongoDB Java client version 3.x has been removed.
Please migrate to log4j-mongodb (client version 5.x) or log4j-mongodb4 (client version 4.x).
Starting in version 2.24.0, JMX support is disabled by default and can be re-enabled via the log4j2.disableJmx=false system property.
DefaultThreadContextMap implementation. (#2330)log4j-slf4j-impl and log4j-slf4j2-impl.
Users can enable it by setting the property log4j2.messageFactory to org.apache.logging.slf4j.message.ThrowableConsumingMessageFactory. (#2363)GcpLayout.json (#2498)org.apache.logging:logging-parent:11.0.0log4j-api in GraalVM without additional reachability data. (#1539)PropertiesUtil and fix Duration parser. (#1936)Provider class and deprecate log4j2.loggerContextFactory property. (#2374)log4j-kubernetes lookup. User should migrate to io.fabric8:kubernetes-log4j. (#2412)log4j2.disableJmx to be set to false to enable JMX support. (#2462)DateTimeFormatter#toString() with DateTimeFormatter#formatTo(StringBuilder) to cut down on allocations
(#2515)log4j1.compatibility is false. (#2778)log4j2.enableThreadLocals,log4j2.garbagefreeThreadContextMap and log4j2.shutdownHookEnabled
over the value of log4j.isWebapp. (#2517)log4j2.defaultStatusLevel property in Log4j Core in favor of log4j2.statusLoggerLevel (#2481)Message#getFormat() due to unclear semantics andinconsistent implementations (#2773)org.apache.logging.log4j.EventLogger for removal (#2665)org.apache.logging.log4j.core.appender.rolling.action.Duration class for removal (#2425)log4j-mongodb4 module in favor of log4j-mongodb (#2486)log4j2.messageFactory and log4j2.flowMessageFactory properties (#2505)PropertiesUtil (#2414)log4j2.debug. (#2703)%F and %file keys in Pattern Layout (#2781)JsonLayout failure under JPMS. (#2814)TruncatingBufferedWriter (#2609)ClassCastException in LMAX Disruptor 3 initialization (#2768)java.management module when JMX is disabled, which is the default (#2775)com.fasterxml.jackson:jackson-bom to version 2.17.2 (#2719)com.github.luben:zstd-jni to version 1.5.6-5 (#2901)commons-codec:commons-codec to version 1.17.1 (#2741)commons-logging:commons-logging to version 1.3.4 (#2864)github/codeql-action to version 3.25.1 (#2483)io.fabric8:docker-maven-plugin to version 0.45.0 (#2776)org.apache.cassandra:cassandra-all to version 3.11.17 (#2479)org.apache.commons:commons-compress to version 1.27.1 (#2869)org.apache.commons:commons-csv to version 1.11.0 (#2565)org.apache.commons:commons-lang3 to version 3.17.0 (#2907)org.apache.kafka:kafka-clients to version 3.8.0 (#2777)org.apache.logging:logging-parent to version 11.2.0org.eclipse.jetty:jetty-bom to version 9.4.55.v20240627 (#2709)org.jctools:jctools-core to version 4.0.5 (#2637)org.mongodb:* from 4.11.1 to 4.11.2 (#2409)org.mongodb:bson to version 5.1.3 (#2823)org.slf4j:slf4j-api to version 2.0.16 (#2829)org.springframework:spring-framework-bom to version 5.3.39 (#2840)Nothing published for this version
One column per quarter.