vy commented on code in PR #3045:
URL: https://github.com/apache/logging-log4j2/pull/3045#discussion_r1793337694


##########
log4j-core-test/src/test/java/org/apache/logging/log4j/core/layout/PatternLayoutDefaultExceptionHandlerTest.java:
##########
@@ -0,0 +1,66 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to you under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.logging.log4j.core.layout;
+
+import static org.assertj.core.api.Assertions.assertThat;
+
+import org.apache.logging.log4j.core.Layout;
+import org.apache.logging.log4j.core.LogEvent;
+import org.apache.logging.log4j.core.config.Configuration;
+import org.apache.logging.log4j.core.config.NullConfiguration;
+import org.apache.logging.log4j.core.impl.Log4jLogEvent;
+import org.assertj.core.api.AbstractStringAssert;
+import org.junit.jupiter.api.Test;
+
+class PatternLayoutDefaultExceptionHandlerTest {
+
+    private static final Configuration CONFIG = new NullConfiguration();
+
+    private static final Exception EXCEPTION = new RuntimeException("foo");
+
+    @Test
+    void default_exception_handler_should_be_provided() {
+        final String threadName = Thread.currentThread().getName();
+        final String exceptionClassName = 
EXCEPTION.getClass().getCanonicalName();
+        final String exceptionMessage = EXCEPTION.getMessage();
+        final String firstLine = String.format("%s%n%s: %s", threadName, 
exceptionClassName, exceptionMessage);
+        assertThatPatternEncodes("%t", true).startsWith(firstLine);

Review Comment:
   Fixed in d7d46be7d022e4f1821dcd39e52b84844d7d2e92.



##########
src/changelog/.2.x.x/.release-notes.adoc.ftl:
##########
@@ -20,14 +20,21 @@
 
 <#if release.date?has_content>Release date:: ${release.date}</#if>
 
-This releases contains ...
+This minor release contains bug fixes, behavioral improvements, and a 
fully-fledged support for the GraalVM native image generation.
 
+[#release-notes-2-25-0-graalvm]
 === GraalVM reachability metadata
 
-Log4j Core and all its extension modules have been enhanced with embedded
+Log4j Core and all its extension modules have been enriched with embedded
 https://www.graalvm.org/latest/reference-manual/native-image/metadata/[GraalVM 
reachability metadata].
-This will allow the generation of GraalVM native images out-of-the-box, 
without any additional step necessary.
+This allows the generation of GraalVM native images out-of-the-box without any 
additional steps.
+See our xref:graalvm.adoc[GraalVM guide] for details.
 
-See our xref:graalvm.adoc[GraalVM guide] for more details.
+[#release-notes-2-25-0-PL-ex]
+=== Exception handling in Pattern Layout
+
+Exception handling in Pattern Layout went through a major rewrite.
+This effectively helped with fixing some bugs by matching the feature parity 
of all exception converters.
+Additionally, rendered stack traces are ensured to be prefixed with a newline, 
which used to be a whitespace in earlier versions.

Review Comment:
   Fixed in 28a8325413ae8fd923d3174a080271cfb92625ad.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to