This is an automated email from the ASF dual-hosted git repository. pkarwasz pushed a commit to branch release/2.25.0 in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git
commit 75061eb9d266005c871eedaeab668faa2118ce7d Author: Piotr P. Karwasz <[email protected]> AuthorDate: Fri Jun 13 19:08:55 2025 +0200 fix: Javadoc and documentation problems --- .../internal/map/UnmodifiableArrayBackedMap.java | 8 ----- src/changelog/2.25.0/.release-notes.adoc.ftl | 12 ++++++-- .../ROOT/pages/manual/appenders/message-queue.adoc | 35 ++++++++++++++++++++-- 3 files changed, 42 insertions(+), 13 deletions(-) diff --git a/log4j-api/src/main/java/org/apache/logging/log4j/internal/map/UnmodifiableArrayBackedMap.java b/log4j-api/src/main/java/org/apache/logging/log4j/internal/map/UnmodifiableArrayBackedMap.java index 45f61cefd9..2911710bd3 100644 --- a/log4j-api/src/main/java/org/apache/logging/log4j/internal/map/UnmodifiableArrayBackedMap.java +++ b/log4j-api/src/main/java/org/apache/logging/log4j/internal/map/UnmodifiableArrayBackedMap.java @@ -269,10 +269,6 @@ public class UnmodifiableArrayBackedMap extends AbstractMap<String, String> impl /** * Creates a new instance that contains the same entries as this map, plus the * new entries or updated values passed in the parameters. - * - * @param key - * @param value - * @return */ public UnmodifiableArrayBackedMap copyAndPutAll(Map<String, String> entriesToAdd) { // create a new array that can hold the maximum output size @@ -304,10 +300,6 @@ public class UnmodifiableArrayBackedMap extends AbstractMap<String, String> impl /** * Creates a new instance that contains the same entries as this map, minus the * entry with the specified key (if such an entry exists). - * - * @param key - * @param value - * @return */ public UnmodifiableArrayBackedMap copyAndRemove(String key) { int indexToRemove = -1; diff --git a/src/changelog/2.25.0/.release-notes.adoc.ftl b/src/changelog/2.25.0/.release-notes.adoc.ftl index 5780f2efe8..76b92252d7 100644 --- a/src/changelog/2.25.0/.release-notes.adoc.ftl +++ b/src/changelog/2.25.0/.release-notes.adoc.ftl @@ -30,6 +30,14 @@ https://www.graalvm.org/latest/reference-manual/native-image/metadata/[GraalVM r enabling seamless generation of native images with GraalVM out of the box—no manual configuration required. For more information, refer to our xref:graalvm.adoc[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 xref:manual/plugins.adoc#plugin-registry[Registering plugins]. +==== + [#release-notes-2-25-0-PL-ex] === Exception Handling in Pattern Layout @@ -39,7 +47,7 @@ Key improvements include: * Stack traces are now consistently prefixed with a newline instead of other whitespace. * The default exception converter has changed from xref:manual/pattern-layout.adoc#converter-exception-extended[extended] to xref:manual/pattern-layout.adoc#converter-exception[plain], offering better performance. -* Support for the `{ansi}` option in exception converters has been removed. +* Support for the `\{ansi}` option in exception converters has been removed. [#release-notes-2-25-0-instant-format] === Date & Time Formatting @@ -51,7 +59,7 @@ These are now deprecated in favor of Java’s standard https://docs.oracle.com/javase/{java-target-version}/docs/api/java/time/format/DateTimeFormatter.html[`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 xref:manual/systemproperties.adoc#log4j2.instantFormatter[`log4j2.instantFormatter`] property to `legacy`. -Please report any issues via our {logging-services-url}/support.html#issues\[issue tracker]. +Please report any issues via our {logging-services-url}/support.html#issues[issue tracker]. [#release-notes-2-25-0-windows-ansi] === ANSI Support on Windows diff --git a/src/site/antora/modules/ROOT/pages/manual/appenders/message-queue.adoc b/src/site/antora/modules/ROOT/pages/manual/appenders/message-queue.adoc index d032c53de3..2095597e39 100644 --- a/src/site/antora/modules/ROOT/pages/manual/appenders/message-queue.adoc +++ b/src/site/antora/modules/ROOT/pages/manual/appenders/message-queue.adoc @@ -424,7 +424,7 @@ This example cannot be configured using Java properties. == JMS Appender The JMS Appender sends a formatted log event to a -https://jakarta.ee/specifications/messaging/3.0/[Jakarta] or https://jakarta.ee/specifications/messaging/2.0/[Javax] Messaging API +https://jakarta.ee/specifications/messaging/3.0/[Jakarta] or https://jakarta.ee/specifications/messaging/2.0/[Java] EE Messaging API destination. [IMPORTANT] @@ -434,9 +434,38 @@ xref:manual/systemproperties.adoc#log4j2.enableJndiJms[`log4j2.enableJndiJms`] configuration property to `true`. ==== -For Jakarta, use the `JMS-Jakarta` element name in the `log4j-jakarta-jms` Maven module. +[WARNING] +===== +Starting with Log4j `2.25.0`, the correct Appender element name depends on the version of Jakarta Messaging you are using: + +* **For Jakarta Messaging 3.0 or later**, use the `JMS-Jakarta` element name. +This requires additional runtime dependencies: ++ +[tabs] +==== +Maven:: ++ +[source,xml,subs="+attributes"] +---- +<dependency> + <groupId>org.apache.logging.log4j</groupId> + <artifactId>log4j-jakarta-jms</artifactId> + <version>{log4j-core-version}</version> +</dependency> +---- -For Javax, use the `JMS-Javax` element name; the names `JMS`, `JMSQueue`, and `JMSTopic` are provided for backward compatibility. +Gradle:: ++ +[source,groovy,subs="+attributes"] +---- +runtimeOnly 'org.apache.logging.log4j:log4j-jakarta-jms:{log4j-core-version}' +---- +==== + +* **For Java Messaging or Jakarta Messaging 2.0**, use the `JMS-Javax` element name instead. + +The legacy element names `JMS`, `JMSQueue`, and `JMSTopic` are still supported for backward compatibility. +===== [#JmsAppender-attributes] .JMS Appender configuration attributes
