This is an automated email from the ASF dual-hosted git repository. vy pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/logging-log4j-tools.git
commit 73680988f1b6b926503e73cc0a345bb7453899ee Author: Volkan Yazıcı <[email protected]> AuthorDate: Wed Jan 25 16:05:06 2023 +0100 Add tests for `ChangelogReleaser` --- .../java/org/apache/logging/log4j/ExportMojo.java | 2 +- .../java/org/apache/logging/log4j/ReleaseMojo.java | 6 +- log4j-changelog/pom.xml | 6 ++ .../changelog/exporter/ChangelogExporterArgs.java | 4 -- .../changelog/releaser/ChangelogReleaser.java | 3 +- .../changelog/releaser/ChangelogReleaserArgs.java | 27 ++++++--- .../logging/log4j/changelog/util/XmlUtils.java | 4 +- .../log4j/changelog/ChangelogReleaserTest.java | 65 ++++++++++++++++++++++ .../5-unlinked/.2.x.x/.changelog.adoc.ftl | 22 ++++++++ ...Add_getExplicitLevel_method_to_LoggerConfig.xml | 25 +++++++++ ...ConsoleListener_use_SimpleLogger_internally.xml | 25 +++++++++ ..._InstantFormatter_against_delegate_failures.xml | 26 +++++++++ .../5-unlinked/.3.x.x/.changelog.adoc.ftl | 22 ++++++++ .../.3.x.x/1220_Simplify_site_generation.xml | 25 +++++++++ .../1221_switch_from_jira_to_github_issues.xml | 25 +++++++++ ...notation_to_support_plugin_ordering_when_tw.xml | 27 +++++++++ .../5-unlinked/.changelog-entries.adoc.ftl | 48 ++++++++++++++++ .../src/test/resources/5-unlinked/.index.adoc.ftl | 22 ++++++++ .../5-unlinked/2.17.2/.changelog.adoc.ftl | 47 ++++++++++++++++ .../test/resources/5-unlinked/2.17.2/.release.xml | 21 +++++++ ...s_initialized_if_the_LoggerFactory_is_provi.xml | 26 +++++++++ ...ContextDataInjector_initialization_deadlock.xml | 25 +++++++++ ..._Spring_Boot_Lookup_requires_the_log4j_spri.xml | 25 +++++++++ .../5-unlinked/2.18.0/.changelog.adoc.ftl | 36 ++++++++++++ .../test/resources/5-unlinked/2.18.0/.release.xml | 21 +++++++ ...erStrategy_should_use_the_current_time_when.xml | 25 +++++++++ ...lloverStrategy_was_not_detecting_the_correc.xml | 25 +++++++++ ...se_Paths_get_to_avoid_circular_file_systems.xml | 25 +++++++++ .../6-released/.3.x.x/.changelog.adoc.ftl | 22 ++++++++ .../.3.x.x/1220_Simplify_site_generation.xml | 25 +++++++++ .../1221_switch_from_jira_to_github_issues.xml | 25 +++++++++ ...notation_to_support_plugin_ordering_when_tw.xml | 27 +++++++++ .../6-released/.changelog-entries.adoc.ftl | 48 ++++++++++++++++ .../src/test/resources/6-released/.index.adoc.ftl | 22 ++++++++ .../6-released/2.17.2/.changelog.adoc.ftl | 47 ++++++++++++++++ .../test/resources/6-released/2.17.2/.release.xml | 21 +++++++ ...s_initialized_if_the_LoggerFactory_is_provi.xml | 26 +++++++++ ...ContextDataInjector_initialization_deadlock.xml | 25 +++++++++ ..._Spring_Boot_Lookup_requires_the_log4j_spri.xml | 25 +++++++++ .../6-released/2.18.0/.changelog.adoc.ftl | 36 ++++++++++++ .../test/resources/6-released/2.18.0/.release.xml | 21 +++++++ ...erStrategy_should_use_the_current_time_when.xml | 25 +++++++++ ...lloverStrategy_was_not_detecting_the_correc.xml | 25 +++++++++ ...se_Paths_get_to_avoid_circular_file_systems.xml | 25 +++++++++ .../6-released/2.19.0/.changelog.adoc.ftl | 22 ++++++++ .../test/resources/6-released/2.19.0/.release.xml | 21 +++++++ ...Add_getExplicitLevel_method_to_LoggerConfig.xml | 25 +++++++++ ...ConsoleListener_use_SimpleLogger_internally.xml | 25 +++++++++ ..._InstantFormatter_against_delegate_failures.xml | 26 +++++++++ log4j-tools-parent/pom.xml | 7 +++ 50 files changed, 1215 insertions(+), 16 deletions(-) diff --git a/log4j-changelog-maven-plugin/src/main/java/org/apache/logging/log4j/ExportMojo.java b/log4j-changelog-maven-plugin/src/main/java/org/apache/logging/log4j/ExportMojo.java index 423190e..ab2cc77 100644 --- a/log4j-changelog-maven-plugin/src/main/java/org/apache/logging/log4j/ExportMojo.java +++ b/log4j-changelog-maven-plugin/src/main/java/org/apache/logging/log4j/ExportMojo.java @@ -53,7 +53,7 @@ public class ExportMojo extends AbstractMojo { private File outputDirectory; public void execute() { - ChangelogExporterArgs args = ChangelogExporterArgs.fromArgs( + ChangelogExporterArgs args = new ChangelogExporterArgs( changelogDirectory.toPath(), outputDirectory.toPath()); ChangelogExporter.performExport(args); diff --git a/log4j-changelog-maven-plugin/src/main/java/org/apache/logging/log4j/ReleaseMojo.java b/log4j-changelog-maven-plugin/src/main/java/org/apache/logging/log4j/ReleaseMojo.java index 2764fec..feb67fd 100644 --- a/log4j-changelog-maven-plugin/src/main/java/org/apache/logging/log4j/ReleaseMojo.java +++ b/log4j-changelog-maven-plugin/src/main/java/org/apache/logging/log4j/ReleaseMojo.java @@ -17,6 +17,7 @@ package org.apache.logging.log4j; import java.io.File; +import java.time.LocalDate; import org.apache.logging.log4j.changelog.releaser.ChangelogReleaser; import org.apache.logging.log4j.changelog.releaser.ChangelogReleaserArgs; @@ -52,7 +53,10 @@ public class ReleaseMojo extends AbstractMojo { private String releaseVersion; public void execute() { - ChangelogReleaserArgs args = ChangelogReleaserArgs.fromArgs(changelogDirectory.toPath(), releaseVersion); + ChangelogReleaserArgs args = new ChangelogReleaserArgs( + changelogDirectory.toPath(), + releaseVersion, + LocalDate.now()); ChangelogReleaser.performRelease(args); } diff --git a/log4j-changelog/pom.xml b/log4j-changelog/pom.xml index 53f0d77..fb4af35 100644 --- a/log4j-changelog/pom.xml +++ b/log4j-changelog/pom.xml @@ -55,6 +55,12 @@ <scope>test</scope> </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <scope>test</scope> + </dependency> + </dependencies> </project> diff --git a/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/exporter/ChangelogExporterArgs.java b/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/exporter/ChangelogExporterArgs.java index 5f25950..178eba6 100644 --- a/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/exporter/ChangelogExporterArgs.java +++ b/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/exporter/ChangelogExporterArgs.java @@ -42,8 +42,4 @@ public final class ChangelogExporterArgs { return new ChangelogExporterArgs(changelogDirectory, outputDirectory); } - public static ChangelogExporterArgs fromArgs(final Path changelogDirectory, final Path outputDirectory) { - return new ChangelogExporterArgs(changelogDirectory, outputDirectory); - } - } diff --git a/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/releaser/ChangelogReleaser.java b/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/releaser/ChangelogReleaser.java index 8d3f17e..27204a1 100644 --- a/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/releaser/ChangelogReleaser.java +++ b/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/releaser/ChangelogReleaser.java @@ -34,7 +34,8 @@ public final class ChangelogReleaser { private ChangelogReleaser() {} public static void main(final String[] mainArgs) { - performRelease(ChangelogReleaserArgs.fromSystemProperties()); + final ChangelogReleaserArgs args = ChangelogReleaserArgs.fromSystemProperties(); + performRelease(args); } public static void performRelease(final ChangelogReleaserArgs args) { diff --git a/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/releaser/ChangelogReleaserArgs.java b/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/releaser/ChangelogReleaserArgs.java index e837fe7..7951be4 100644 --- a/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/releaser/ChangelogReleaserArgs.java +++ b/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/releaser/ChangelogReleaserArgs.java @@ -17,6 +17,8 @@ package org.apache.logging.log4j.changelog.releaser; import java.nio.file.Path; +import java.time.LocalDate; +import java.util.Objects; import static org.apache.logging.log4j.changelog.util.PropertyUtils.requireNonBlankPathProperty; import static org.apache.logging.log4j.changelog.util.PropertyUtils.requireNonBlankStringProperty; @@ -32,20 +34,31 @@ public final class ChangelogReleaserArgs { final String releaseVersion; - private ChangelogReleaserArgs(final Path changelogDirectory, final String releaseVersion) { + final LocalDate releaseDate; + + public ChangelogReleaserArgs( + final Path changelogDirectory, + final String releaseVersion, + final LocalDate releaseDate) { + + // Check arguments + Objects.requireNonNull(changelogDirectory, "changelogDirectory"); + Objects.requireNonNull(releaseVersion, "releaseVersion"); + requireSemanticVersioning(releaseVersion, RELEASE_VERSION_PROPERTY_NAME); + Objects.requireNonNull(releaseDate, "releaseDate"); + + // Set fields this.changelogDirectory = changelogDirectory; this.releaseVersion = releaseVersion; + this.releaseDate = releaseDate; + } static ChangelogReleaserArgs fromSystemProperties() { final Path changelogDirectory = requireNonBlankPathProperty(CHANGELOG_DIRECTORY_PROPERTY_NAME); final String releaseVersion = requireNonBlankStringProperty(RELEASE_VERSION_PROPERTY_NAME); - requireSemanticVersioning(releaseVersion, RELEASE_VERSION_PROPERTY_NAME); - return new ChangelogReleaserArgs(changelogDirectory, releaseVersion); - } - - public static ChangelogReleaserArgs fromArgs(final Path changelogDirectory, final String releaseVersion) { - return new ChangelogReleaserArgs(changelogDirectory, releaseVersion); + final LocalDate releaseDate = LocalDate.now(); + return new ChangelogReleaserArgs(changelogDirectory, releaseVersion, releaseDate); } } diff --git a/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/util/XmlUtils.java b/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/util/XmlUtils.java index a438442..96e48c7 100644 --- a/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/util/XmlUtils.java +++ b/log4j-changelog/src/main/java/org/apache/logging/log4j/changelog/util/XmlUtils.java @@ -16,6 +16,8 @@ */ package org.apache.logging.log4j.changelog.util; +import java.io.InputStream; + import javax.xml.XMLConstants; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; @@ -23,8 +25,6 @@ import javax.xml.transform.stream.StreamSource; import javax.xml.validation.Schema; import javax.xml.validation.SchemaFactory; -import java.io.InputStream; - final class XmlUtils { static final String XML_NAMESPACE = "http://logging.apache.org/log4j/changelog"; diff --git a/log4j-changelog/src/test/java/org/apache/logging/log4j/changelog/ChangelogReleaserTest.java b/log4j-changelog/src/test/java/org/apache/logging/log4j/changelog/ChangelogReleaserTest.java new file mode 100644 index 0000000..e0e94f8 --- /dev/null +++ b/log4j-changelog/src/test/java/org/apache/logging/log4j/changelog/ChangelogReleaserTest.java @@ -0,0 +1,65 @@ +/* + * 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.changelog; + +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.time.LocalDate; + +import org.apache.logging.log4j.changelog.releaser.ChangelogReleaser; +import org.apache.logging.log4j.changelog.releaser.ChangelogReleaserArgs; + +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.io.CleanupMode; +import org.junit.jupiter.api.io.TempDir; + +import static org.apache.logging.log4j.changelog.FileTestUtils.assertDirectoryContentMatches; + +import static org.apache.commons.io.FileUtils.copyDirectory; + +class ChangelogReleaserTest { + + @Test + void output_should_match(@TempDir(cleanup = CleanupMode.ON_SUCCESS) final Path changelogDirectory) + throws Exception { + + // Clone the directory to avoid `move` operations cluttering the reference folder + copyDirectory(new File("src/test/resources/5-unlinked"), changelogDirectory.toFile()); + + // Invoke the releaser + ChangelogReleaserArgs args = new ChangelogReleaserArgs( + changelogDirectory, + "2.19.0", + LocalDate.parse("2023-01-25")); + ChangelogReleaser.performRelease(args); + + // Empty folders are not tracked by git, though created by `ChangelogReleaser`. + // Create the `.2.x.x` folder to match the actual output. + final Path expectedChangelogDirectory = Paths.get("src/test/resources/6-released"); + final Path emptyFolder = expectedChangelogDirectory.resolve(".2.x.x"); + if (!Files.exists(emptyFolder)) { + Files.createDirectories(emptyFolder); + } + + // Compare the output + assertDirectoryContentMatches(changelogDirectory, expectedChangelogDirectory); + + } + +} diff --git a/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/.changelog.adoc.ftl b/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/.changelog.adoc.ftl new file mode 100644 index 0000000..55dd1ed --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/.changelog.adoc.ftl @@ -0,0 +1,22 @@ +//// + 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 + + https://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. +//// + += ${release.version}<#if release.date?has_content> (${release.date})</#if> + +Changes staged for the next 2.x.x version that is yet to be released. + +<#include "../.changelog-entries.adoc.ftl"> diff --git a/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/LOG4J2-3572_Add_getExplicitLevel_method_to_LoggerConfig.xml b/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/LOG4J2-3572_Add_getExplicitLevel_method_to_LoggerConfig.xml new file mode 100644 index 0000000..b135ac2 --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/LOG4J2-3572_Add_getExplicitLevel_method_to_LoggerConfig.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="changed"> + <issue id="LOG4J2-3572" link="https://issues.apache.org/jira/browse/LOG4J2-3572"/> + <author id="rgoers"/> + <description format="asciidoc">Add `getExplicitLevel` method to `LoggerConfig`</description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/LOG4J2-3584_Make_StatusConsoleListener_use_SimpleLogger_internally.xml b/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/LOG4J2-3584_Make_StatusConsoleListener_use_SimpleLogger_internally.xml new file mode 100644 index 0000000..7902947 --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/LOG4J2-3584_Make_StatusConsoleListener_use_SimpleLogger_internally.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="fixed"> + <issue id="LOG4J2-3584" link="https://issues.apache.org/jira/browse/LOG4J2-3584"/> + <author id="vy"/> + <description format="asciidoc">Make `StatusConsoleListener` use `SimpleLogger` internally</description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/LOG4J2-3614_Harden_InstantFormatter_against_delegate_failures.xml b/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/LOG4J2-3614_Harden_InstantFormatter_against_delegate_failures.xml new file mode 100644 index 0000000..34111cf --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/.2.x.x/LOG4J2-3614_Harden_InstantFormatter_against_delegate_failures.xml @@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="fixed"> + <issue id="LOG4J2-3614" link="https://issues.apache.org/jira/browse/LOG4J2-3614"/> + <author id="vy"/> + <author name="strainu"/> + <description format="asciidoc">Harden `InstantFormatter` against delegate failures</description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/.changelog.adoc.ftl b/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/.changelog.adoc.ftl new file mode 100644 index 0000000..b2d69db --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/.changelog.adoc.ftl @@ -0,0 +1,22 @@ +//// + 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 + + https://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. +//// + += ${release.version}<#if release.date?has_content> (${release.date})</#if> + +Changes staged for the next 3.x.x version that is yet to be released. + +<#include "../.changelog-entries.adoc.ftl"> diff --git a/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/1220_Simplify_site_generation.xml b/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/1220_Simplify_site_generation.xml new file mode 100644 index 0000000..81f353c --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/1220_Simplify_site_generation.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="changed"> + <issue id="1220" link="https://github.com/apache/logging-log4j2/pull/1220"/> + <author id="vy"/> + <description format="asciidoc">Simplify Maven `site` phase and align it with the one in `release-2.x` branch</description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/1221_switch_from_jira_to_github_issues.xml b/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/1221_switch_from_jira_to_github_issues.xml new file mode 100644 index 0000000..333a109 --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/1221_switch_from_jira_to_github_issues.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="changed"> + <issue id="1221" link="https://github.com/apache/logging-log4j2/pull/1221"/> + <author id="vy"/> + <description format="asciidoc">Switch the issue tracker from https://issues.apache.org/jira/browse/LOG4J2[JIRA] to https://github.com/apache/logging-log4j2/issues[GitHub Issues]</description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/LOG4J2-857_Add_Ordered_annotation_to_support_plugin_ordering_when_tw.xml b/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/LOG4J2-857_Add_Ordered_annotation_to_support_plugin_ordering_when_tw.xml new file mode 100644 index 0000000..ce50aa7 --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/.3.x.x/LOG4J2-857_Add_Ordered_annotation_to_support_plugin_ordering_when_tw.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="added"> + <issue id="LOG4J2-857" link="https://issues.apache.org/jira/browse/LOG4J2-857"/> + <author id="mattsicker"/> + <description format="asciidoc"> + Add `@Ordered` annotation to support plugin ordering when two or more plugins within the same category have the same case-insensitive name + </description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/.changelog-entries.adoc.ftl b/log4j-changelog/src/test/resources/5-unlinked/.changelog-entries.adoc.ftl new file mode 100644 index 0000000..a8c18e8 --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/.changelog-entries.adoc.ftl @@ -0,0 +1,48 @@ +<#-- + 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 + + https://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. +--> +<#if entriesByType?size gt 0>== Changes +<#list entriesByType as entryType, entries> + +== ${entryType?capitalize} + +<#list entries as entry> +* ${entry.description.text?replace("\\s+", " ", "r")} (for <@compress single_line=true> +<#list entry.issues as issue>${issue.link}[${issue.id}]<#if issue?has_next>, </#if></#list> by +<#list entry.authors as author> +<@compress single_line=true> +<#if !author.id?has_content>${author.name} +<#elseif author.id == "rgoers">Ralph Goers +<#elseif author.id == "ggregory">Gary Gregory +<#elseif author.id == "sdeboy">Scott Deboy +<#elseif author.id == "rpopma">Remko Popma +<#elseif author.id == "nickwilliams">Nick Williams +<#elseif author.id == "mattsicker">Matt Sicker +<#elseif author.id == "bbrouwer">Bruce Brouwer +<#elseif author.id == "rgupta">Raman Gupta +<#elseif author.id == "mikes">Mikael Ståldal +<#elseif author.id == "ckozak">Carter Kozak +<#elseif author.id == "vy">Volkan Yazıcı +<#elseif author.id == "rgrabowski">Ron Grabowski +<#elseif author.id == "pkarwasz">Piotr P. Karwasz +<#else>`${author.id}` +</#if> +</@compress><#if author?has_next>, </#if> +</#list> +</@compress>) +</#list> +</#list> +</#if> diff --git a/log4j-changelog/src/test/resources/5-unlinked/.index.adoc.ftl b/log4j-changelog/src/test/resources/5-unlinked/.index.adoc.ftl new file mode 100644 index 0000000..e6e82ba --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/.index.adoc.ftl @@ -0,0 +1,22 @@ +//// + 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 + + https://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. +//// + += Release changelogs + +<#list releases as release> +* xref:${release.changelogFileName}[${release.version}]<#if release.date?has_content> (${release.date})</#if> +</#list> diff --git a/log4j-changelog/src/test/resources/5-unlinked/2.17.2/.changelog.adoc.ftl b/log4j-changelog/src/test/resources/5-unlinked/2.17.2/.changelog.adoc.ftl new file mode 100644 index 0000000..d32f334 --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/2.17.2/.changelog.adoc.ftl @@ -0,0 +1,47 @@ +//// + 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 + + https://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. +//// + += ${release.version}<#if release.date?has_content> (${release.date})</#if> + +This release contains the changes noted below: + +* Over 50 improvements and fixes to the Log4j 1.x support. +Continued testing has shown it is a suitable replacement for Log4j 1.x in most cases. +* Scripting now requires a system property be specified naming the languages the user wishes to allow. +The scripting engine will not load if the property isn't set. +* By default, the only remote protocol allowed for loading configuration files is HTTPS. +Users can specify a system property to allow others or prevent remote loading entirely. +* Variable resolution has been modified so that only properties defined as properties in the configuration file can be recursive. +All other Lookups are now non-recursive. +This addresses issues users were having resolving lookups specified in property definitions for use in the `RoutingAppender` and `RollingFileAppender` due to restrictions put in place in 2.17.1. +* Many other fixes and improvements. + +Due to a break in compatibility in the SLF4J binding, Log4j now ships with two versions of the SLF4J to Log4j adapters. +`log4j-slf4j-impl` should be used with SLF4J 1.7.x and earlier and `log4j-slf4j18-impl` should be used with SLF4J 1.8.x and later. +SLF4J-2.0.0 alpha releases are not fully supported. +See https://issues.apache.org/jira/browse/LOG4J2-2975[LOG4J2-2975] and https://jira.qos.ch/browse/SLF4J-511[SLF4J-511]. + +The Log4j 2.17.2 API, as well as many core components, maintains binary compatibility with previous releases. + +Apache Log4j 2.17.2 requires a minimum of Java 8 to build and run. +Log4j 2.12.4 is the last release to support Java 7. +Log4j 2.3.2 is the last release to support Java 6. +Java 6 and Java 7 are no longer supported by the Log4j team. + +For complete information on Apache Log4j 2, including instructions on how to submit bug reports, patches, or suggestions for improvement, see http://logging.apache.org/log4j/2.x/[the Apache Log4j 2 website]. + +<#include "../.changelog-entries.adoc.ftl"> diff --git a/log4j-changelog/src/test/resources/5-unlinked/2.17.2/.release.xml b/log4j-changelog/src/test/resources/5-unlinked/2.17.2/.release.xml new file mode 100644 index 0000000..b46393f --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/2.17.2/.release.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<release xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + date="2022-02-23" version="2.17.2"/> diff --git a/log4j-changelog/src/test/resources/5-unlinked/2.17.2/LOG4J2-3304_Flag_LogManager_as_initialized_if_the_LoggerFactory_is_provi.xml b/log4j-changelog/src/test/resources/5-unlinked/2.17.2/LOG4J2-3304_Flag_LogManager_as_initialized_if_the_LoggerFactory_is_provi.xml new file mode 100644 index 0000000..242b03e --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/2.17.2/LOG4J2-3304_Flag_LogManager_as_initialized_if_the_LoggerFactory_is_provi.xml @@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="fixed"> + <issue id="LOG4J2-3304" link="https://issues.apache.org/jira/browse/LOG4J2-3304"/> + <author id="rgoers"/> + <author name="francis-FY"/> + <description format="asciidoc">Flag `LogManager` as initialized if the `LoggerFactory` is provided as a property</description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/2.17.2/LOG4J2-3333_Fix_ThreadContextDataInjector_initialization_deadlock.xml b/log4j-changelog/src/test/resources/5-unlinked/2.17.2/LOG4J2-3333_Fix_ThreadContextDataInjector_initialization_deadlock.xml new file mode 100644 index 0000000..cb4ea04 --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/2.17.2/LOG4J2-3333_Fix_ThreadContextDataInjector_initialization_deadlock.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="removed"> + <issue id="LOG4J2-3333" link="https://issues.apache.org/jira/browse/LOG4J2-3333"/> + <author id="ckozak"/> + <description format="asciidoc">Fix `ThreadContextDataInjector` initialization deadlock</description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/2.17.2/LOG4J2-3405_Document_that_the_Spring_Boot_Lookup_requires_the_log4j_spri.xml b/log4j-changelog/src/test/resources/5-unlinked/2.17.2/LOG4J2-3405_Document_that_the_Spring_Boot_Lookup_requires_the_log4j_spri.xml new file mode 100644 index 0000000..6b213cb --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/2.17.2/LOG4J2-3405_Document_that_the_Spring_Boot_Lookup_requires_the_log4j_spri.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="removed"> + <issue id="LOG4J2-3405" link="https://issues.apache.org/jira/browse/LOG4J2-3405"/> + <author id="rgoers"/> + <description format="asciidoc">Document that the Spring Boot Lookup requires the `log4j-spring-boot` dependency</description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/2.18.0/.changelog.adoc.ftl b/log4j-changelog/src/test/resources/5-unlinked/2.18.0/.changelog.adoc.ftl new file mode 100644 index 0000000..5fa0ffa --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/2.18.0/.changelog.adoc.ftl @@ -0,0 +1,36 @@ +//// + 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 + + https://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. +//// + += ${release.version}<#if release.date?has_content> (${release.date})</#if> + +This release primarily contains bug fixes and minor enhancements. + +Due to a break in compatibility in the SLF4J binding, Log4j now ships with two versions of the SLF4J to Log4j adapters. +`log4j-slf4j-impl` should be used with SLF4J 1.7.x and earlier and `log4j-slf4j18-impl` should be used with SLF4J 1.8.x and later. +SLF4J-2.0.0 alpha releases are not fully supported. +See https://issues.apache.org/jira/browse/LOG4J2-2975[LOG4J2-2975] and https://jira.qos.ch/browse/SLF4J-511[SLF4J-511]. + +The Log4j 2.18.0 API, as well as many core components, maintains binary compatibility with previous releases. + +Apache Log4j 2.18.0 requires a minimum of Java 8 to build and run. +Log4j 2.12.4 is the last release to support Java 7. +Log4j 2.3.2 is the last release to support Java 6. +Java 6 and Java 7 are no longer supported by the Log4j team. + +For complete information on Apache Log4j 2, including instructions on how to submit bug reports, patches, or suggestions for improvement, see http://logging.apache.org/log4j/2.x/[the Apache Log4j 2 website]. + +<#include "../.changelog-entries.adoc.ftl"> diff --git a/log4j-changelog/src/test/resources/5-unlinked/2.18.0/.release.xml b/log4j-changelog/src/test/resources/5-unlinked/2.18.0/.release.xml new file mode 100644 index 0000000..2f7068a --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/2.18.0/.release.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<release xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + date="2022-06-28" version="2.18.0"/> diff --git a/log4j-changelog/src/test/resources/5-unlinked/2.18.0/LOG4J2-3339_DirectWriteRolloverStrategy_should_use_the_current_time_when.xml b/log4j-changelog/src/test/resources/5-unlinked/2.18.0/LOG4J2-3339_DirectWriteRolloverStrategy_should_use_the_current_time_when.xml new file mode 100644 index 0000000..8490b36 --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/2.18.0/LOG4J2-3339_DirectWriteRolloverStrategy_should_use_the_current_time_when.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="fixed"> + <issue id="LOG4J2-3339" link="https://issues.apache.org/jira/browse/LOG4J2-3339"/> + <author id="rgoers"/> + <description format="asciidoc">`DirectWriteRolloverStrategy` should use the current time when creating files</description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/2.18.0/LOG4J2-3490_The_DirectWriteRolloverStrategy_was_not_detecting_the_correc.xml b/log4j-changelog/src/test/resources/5-unlinked/2.18.0/LOG4J2-3490_The_DirectWriteRolloverStrategy_was_not_detecting_the_correc.xml new file mode 100644 index 0000000..c60d17b --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/2.18.0/LOG4J2-3490_The_DirectWriteRolloverStrategy_was_not_detecting_the_correc.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="removed"> + <issue id="LOG4J2-3490" link="https://issues.apache.org/jira/browse/LOG4J2-3490"/> + <author id="rgoers"/> + <description format="asciidoc">The `DirectWriteRolloverStrategy` was not detecting the correct index to use during startup</description> +</entry> diff --git a/log4j-changelog/src/test/resources/5-unlinked/2.18.0/LOG4J2-3527_Don_t_use_Paths_get_to_avoid_circular_file_systems.xml b/log4j-changelog/src/test/resources/5-unlinked/2.18.0/LOG4J2-3527_Don_t_use_Paths_get_to_avoid_circular_file_systems.xml new file mode 100644 index 0000000..d7e296b --- /dev/null +++ b/log4j-changelog/src/test/resources/5-unlinked/2.18.0/LOG4J2-3527_Don_t_use_Paths_get_to_avoid_circular_file_systems.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="added"> + <issue id="LOG4J2-3527" link="https://issues.apache.org/jira/browse/LOG4J2-3527"/> + <author id="rgoers"/> + <description format="asciidoc">Don't use `Paths.get()` to avoid circular file systems</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/.3.x.x/.changelog.adoc.ftl b/log4j-changelog/src/test/resources/6-released/.3.x.x/.changelog.adoc.ftl new file mode 100644 index 0000000..b2d69db --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/.3.x.x/.changelog.adoc.ftl @@ -0,0 +1,22 @@ +//// + 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 + + https://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. +//// + += ${release.version}<#if release.date?has_content> (${release.date})</#if> + +Changes staged for the next 3.x.x version that is yet to be released. + +<#include "../.changelog-entries.adoc.ftl"> diff --git a/log4j-changelog/src/test/resources/6-released/.3.x.x/1220_Simplify_site_generation.xml b/log4j-changelog/src/test/resources/6-released/.3.x.x/1220_Simplify_site_generation.xml new file mode 100644 index 0000000..81f353c --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/.3.x.x/1220_Simplify_site_generation.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="changed"> + <issue id="1220" link="https://github.com/apache/logging-log4j2/pull/1220"/> + <author id="vy"/> + <description format="asciidoc">Simplify Maven `site` phase and align it with the one in `release-2.x` branch</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/.3.x.x/1221_switch_from_jira_to_github_issues.xml b/log4j-changelog/src/test/resources/6-released/.3.x.x/1221_switch_from_jira_to_github_issues.xml new file mode 100644 index 0000000..333a109 --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/.3.x.x/1221_switch_from_jira_to_github_issues.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="changed"> + <issue id="1221" link="https://github.com/apache/logging-log4j2/pull/1221"/> + <author id="vy"/> + <description format="asciidoc">Switch the issue tracker from https://issues.apache.org/jira/browse/LOG4J2[JIRA] to https://github.com/apache/logging-log4j2/issues[GitHub Issues]</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/.3.x.x/LOG4J2-857_Add_Ordered_annotation_to_support_plugin_ordering_when_tw.xml b/log4j-changelog/src/test/resources/6-released/.3.x.x/LOG4J2-857_Add_Ordered_annotation_to_support_plugin_ordering_when_tw.xml new file mode 100644 index 0000000..ce50aa7 --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/.3.x.x/LOG4J2-857_Add_Ordered_annotation_to_support_plugin_ordering_when_tw.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="added"> + <issue id="LOG4J2-857" link="https://issues.apache.org/jira/browse/LOG4J2-857"/> + <author id="mattsicker"/> + <description format="asciidoc"> + Add `@Ordered` annotation to support plugin ordering when two or more plugins within the same category have the same case-insensitive name + </description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/.changelog-entries.adoc.ftl b/log4j-changelog/src/test/resources/6-released/.changelog-entries.adoc.ftl new file mode 100644 index 0000000..a8c18e8 --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/.changelog-entries.adoc.ftl @@ -0,0 +1,48 @@ +<#-- + 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 + + https://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. +--> +<#if entriesByType?size gt 0>== Changes +<#list entriesByType as entryType, entries> + +== ${entryType?capitalize} + +<#list entries as entry> +* ${entry.description.text?replace("\\s+", " ", "r")} (for <@compress single_line=true> +<#list entry.issues as issue>${issue.link}[${issue.id}]<#if issue?has_next>, </#if></#list> by +<#list entry.authors as author> +<@compress single_line=true> +<#if !author.id?has_content>${author.name} +<#elseif author.id == "rgoers">Ralph Goers +<#elseif author.id == "ggregory">Gary Gregory +<#elseif author.id == "sdeboy">Scott Deboy +<#elseif author.id == "rpopma">Remko Popma +<#elseif author.id == "nickwilliams">Nick Williams +<#elseif author.id == "mattsicker">Matt Sicker +<#elseif author.id == "bbrouwer">Bruce Brouwer +<#elseif author.id == "rgupta">Raman Gupta +<#elseif author.id == "mikes">Mikael Ståldal +<#elseif author.id == "ckozak">Carter Kozak +<#elseif author.id == "vy">Volkan Yazıcı +<#elseif author.id == "rgrabowski">Ron Grabowski +<#elseif author.id == "pkarwasz">Piotr P. Karwasz +<#else>`${author.id}` +</#if> +</@compress><#if author?has_next>, </#if> +</#list> +</@compress>) +</#list> +</#list> +</#if> diff --git a/log4j-changelog/src/test/resources/6-released/.index.adoc.ftl b/log4j-changelog/src/test/resources/6-released/.index.adoc.ftl new file mode 100644 index 0000000..e6e82ba --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/.index.adoc.ftl @@ -0,0 +1,22 @@ +//// + 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 + + https://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. +//// + += Release changelogs + +<#list releases as release> +* xref:${release.changelogFileName}[${release.version}]<#if release.date?has_content> (${release.date})</#if> +</#list> diff --git a/log4j-changelog/src/test/resources/6-released/2.17.2/.changelog.adoc.ftl b/log4j-changelog/src/test/resources/6-released/2.17.2/.changelog.adoc.ftl new file mode 100644 index 0000000..d32f334 --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.17.2/.changelog.adoc.ftl @@ -0,0 +1,47 @@ +//// + 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 + + https://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. +//// + += ${release.version}<#if release.date?has_content> (${release.date})</#if> + +This release contains the changes noted below: + +* Over 50 improvements and fixes to the Log4j 1.x support. +Continued testing has shown it is a suitable replacement for Log4j 1.x in most cases. +* Scripting now requires a system property be specified naming the languages the user wishes to allow. +The scripting engine will not load if the property isn't set. +* By default, the only remote protocol allowed for loading configuration files is HTTPS. +Users can specify a system property to allow others or prevent remote loading entirely. +* Variable resolution has been modified so that only properties defined as properties in the configuration file can be recursive. +All other Lookups are now non-recursive. +This addresses issues users were having resolving lookups specified in property definitions for use in the `RoutingAppender` and `RollingFileAppender` due to restrictions put in place in 2.17.1. +* Many other fixes and improvements. + +Due to a break in compatibility in the SLF4J binding, Log4j now ships with two versions of the SLF4J to Log4j adapters. +`log4j-slf4j-impl` should be used with SLF4J 1.7.x and earlier and `log4j-slf4j18-impl` should be used with SLF4J 1.8.x and later. +SLF4J-2.0.0 alpha releases are not fully supported. +See https://issues.apache.org/jira/browse/LOG4J2-2975[LOG4J2-2975] and https://jira.qos.ch/browse/SLF4J-511[SLF4J-511]. + +The Log4j 2.17.2 API, as well as many core components, maintains binary compatibility with previous releases. + +Apache Log4j 2.17.2 requires a minimum of Java 8 to build and run. +Log4j 2.12.4 is the last release to support Java 7. +Log4j 2.3.2 is the last release to support Java 6. +Java 6 and Java 7 are no longer supported by the Log4j team. + +For complete information on Apache Log4j 2, including instructions on how to submit bug reports, patches, or suggestions for improvement, see http://logging.apache.org/log4j/2.x/[the Apache Log4j 2 website]. + +<#include "../.changelog-entries.adoc.ftl"> diff --git a/log4j-changelog/src/test/resources/6-released/2.17.2/.release.xml b/log4j-changelog/src/test/resources/6-released/2.17.2/.release.xml new file mode 100644 index 0000000..b46393f --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.17.2/.release.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<release xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + date="2022-02-23" version="2.17.2"/> diff --git a/log4j-changelog/src/test/resources/6-released/2.17.2/LOG4J2-3304_Flag_LogManager_as_initialized_if_the_LoggerFactory_is_provi.xml b/log4j-changelog/src/test/resources/6-released/2.17.2/LOG4J2-3304_Flag_LogManager_as_initialized_if_the_LoggerFactory_is_provi.xml new file mode 100644 index 0000000..242b03e --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.17.2/LOG4J2-3304_Flag_LogManager_as_initialized_if_the_LoggerFactory_is_provi.xml @@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="fixed"> + <issue id="LOG4J2-3304" link="https://issues.apache.org/jira/browse/LOG4J2-3304"/> + <author id="rgoers"/> + <author name="francis-FY"/> + <description format="asciidoc">Flag `LogManager` as initialized if the `LoggerFactory` is provided as a property</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/2.17.2/LOG4J2-3333_Fix_ThreadContextDataInjector_initialization_deadlock.xml b/log4j-changelog/src/test/resources/6-released/2.17.2/LOG4J2-3333_Fix_ThreadContextDataInjector_initialization_deadlock.xml new file mode 100644 index 0000000..cb4ea04 --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.17.2/LOG4J2-3333_Fix_ThreadContextDataInjector_initialization_deadlock.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="removed"> + <issue id="LOG4J2-3333" link="https://issues.apache.org/jira/browse/LOG4J2-3333"/> + <author id="ckozak"/> + <description format="asciidoc">Fix `ThreadContextDataInjector` initialization deadlock</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/2.17.2/LOG4J2-3405_Document_that_the_Spring_Boot_Lookup_requires_the_log4j_spri.xml b/log4j-changelog/src/test/resources/6-released/2.17.2/LOG4J2-3405_Document_that_the_Spring_Boot_Lookup_requires_the_log4j_spri.xml new file mode 100644 index 0000000..6b213cb --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.17.2/LOG4J2-3405_Document_that_the_Spring_Boot_Lookup_requires_the_log4j_spri.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="removed"> + <issue id="LOG4J2-3405" link="https://issues.apache.org/jira/browse/LOG4J2-3405"/> + <author id="rgoers"/> + <description format="asciidoc">Document that the Spring Boot Lookup requires the `log4j-spring-boot` dependency</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/2.18.0/.changelog.adoc.ftl b/log4j-changelog/src/test/resources/6-released/2.18.0/.changelog.adoc.ftl new file mode 100644 index 0000000..5fa0ffa --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.18.0/.changelog.adoc.ftl @@ -0,0 +1,36 @@ +//// + 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 + + https://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. +//// + += ${release.version}<#if release.date?has_content> (${release.date})</#if> + +This release primarily contains bug fixes and minor enhancements. + +Due to a break in compatibility in the SLF4J binding, Log4j now ships with two versions of the SLF4J to Log4j adapters. +`log4j-slf4j-impl` should be used with SLF4J 1.7.x and earlier and `log4j-slf4j18-impl` should be used with SLF4J 1.8.x and later. +SLF4J-2.0.0 alpha releases are not fully supported. +See https://issues.apache.org/jira/browse/LOG4J2-2975[LOG4J2-2975] and https://jira.qos.ch/browse/SLF4J-511[SLF4J-511]. + +The Log4j 2.18.0 API, as well as many core components, maintains binary compatibility with previous releases. + +Apache Log4j 2.18.0 requires a minimum of Java 8 to build and run. +Log4j 2.12.4 is the last release to support Java 7. +Log4j 2.3.2 is the last release to support Java 6. +Java 6 and Java 7 are no longer supported by the Log4j team. + +For complete information on Apache Log4j 2, including instructions on how to submit bug reports, patches, or suggestions for improvement, see http://logging.apache.org/log4j/2.x/[the Apache Log4j 2 website]. + +<#include "../.changelog-entries.adoc.ftl"> diff --git a/log4j-changelog/src/test/resources/6-released/2.18.0/.release.xml b/log4j-changelog/src/test/resources/6-released/2.18.0/.release.xml new file mode 100644 index 0000000..2f7068a --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.18.0/.release.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<release xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + date="2022-06-28" version="2.18.0"/> diff --git a/log4j-changelog/src/test/resources/6-released/2.18.0/LOG4J2-3339_DirectWriteRolloverStrategy_should_use_the_current_time_when.xml b/log4j-changelog/src/test/resources/6-released/2.18.0/LOG4J2-3339_DirectWriteRolloverStrategy_should_use_the_current_time_when.xml new file mode 100644 index 0000000..8490b36 --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.18.0/LOG4J2-3339_DirectWriteRolloverStrategy_should_use_the_current_time_when.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="fixed"> + <issue id="LOG4J2-3339" link="https://issues.apache.org/jira/browse/LOG4J2-3339"/> + <author id="rgoers"/> + <description format="asciidoc">`DirectWriteRolloverStrategy` should use the current time when creating files</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/2.18.0/LOG4J2-3490_The_DirectWriteRolloverStrategy_was_not_detecting_the_correc.xml b/log4j-changelog/src/test/resources/6-released/2.18.0/LOG4J2-3490_The_DirectWriteRolloverStrategy_was_not_detecting_the_correc.xml new file mode 100644 index 0000000..c60d17b --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.18.0/LOG4J2-3490_The_DirectWriteRolloverStrategy_was_not_detecting_the_correc.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="removed"> + <issue id="LOG4J2-3490" link="https://issues.apache.org/jira/browse/LOG4J2-3490"/> + <author id="rgoers"/> + <description format="asciidoc">The `DirectWriteRolloverStrategy` was not detecting the correct index to use during startup</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/2.18.0/LOG4J2-3527_Don_t_use_Paths_get_to_avoid_circular_file_systems.xml b/log4j-changelog/src/test/resources/6-released/2.18.0/LOG4J2-3527_Don_t_use_Paths_get_to_avoid_circular_file_systems.xml new file mode 100644 index 0000000..d7e296b --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.18.0/LOG4J2-3527_Don_t_use_Paths_get_to_avoid_circular_file_systems.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="added"> + <issue id="LOG4J2-3527" link="https://issues.apache.org/jira/browse/LOG4J2-3527"/> + <author id="rgoers"/> + <description format="asciidoc">Don't use `Paths.get()` to avoid circular file systems</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/2.19.0/.changelog.adoc.ftl b/log4j-changelog/src/test/resources/6-released/2.19.0/.changelog.adoc.ftl new file mode 100644 index 0000000..55dd1ed --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.19.0/.changelog.adoc.ftl @@ -0,0 +1,22 @@ +//// + 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 + + https://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. +//// + += ${release.version}<#if release.date?has_content> (${release.date})</#if> + +Changes staged for the next 2.x.x version that is yet to be released. + +<#include "../.changelog-entries.adoc.ftl"> diff --git a/log4j-changelog/src/test/resources/6-released/2.19.0/.release.xml b/log4j-changelog/src/test/resources/6-released/2.19.0/.release.xml new file mode 100644 index 0000000..ab394aa --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.19.0/.release.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<release xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + date="2023-01-25" version="2.19.0"/> diff --git a/log4j-changelog/src/test/resources/6-released/2.19.0/LOG4J2-3572_Add_getExplicitLevel_method_to_LoggerConfig.xml b/log4j-changelog/src/test/resources/6-released/2.19.0/LOG4J2-3572_Add_getExplicitLevel_method_to_LoggerConfig.xml new file mode 100644 index 0000000..b135ac2 --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.19.0/LOG4J2-3572_Add_getExplicitLevel_method_to_LoggerConfig.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="changed"> + <issue id="LOG4J2-3572" link="https://issues.apache.org/jira/browse/LOG4J2-3572"/> + <author id="rgoers"/> + <description format="asciidoc">Add `getExplicitLevel` method to `LoggerConfig`</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/2.19.0/LOG4J2-3584_Make_StatusConsoleListener_use_SimpleLogger_internally.xml b/log4j-changelog/src/test/resources/6-released/2.19.0/LOG4J2-3584_Make_StatusConsoleListener_use_SimpleLogger_internally.xml new file mode 100644 index 0000000..7902947 --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.19.0/LOG4J2-3584_Make_StatusConsoleListener_use_SimpleLogger_internally.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="fixed"> + <issue id="LOG4J2-3584" link="https://issues.apache.org/jira/browse/LOG4J2-3584"/> + <author id="vy"/> + <description format="asciidoc">Make `StatusConsoleListener` use `SimpleLogger` internally</description> +</entry> diff --git a/log4j-changelog/src/test/resources/6-released/2.19.0/LOG4J2-3614_Harden_InstantFormatter_against_delegate_failures.xml b/log4j-changelog/src/test/resources/6-released/2.19.0/LOG4J2-3614_Harden_InstantFormatter_against_delegate_failures.xml new file mode 100644 index 0000000..34111cf --- /dev/null +++ b/log4j-changelog/src/test/resources/6-released/2.19.0/LOG4J2-3614_Harden_InstantFormatter_against_delegate_failures.xml @@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + 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 + + https://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. +--> +<entry xmlns="http://logging.apache.org/log4j/changelog" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://logging.apache.org/log4j/changelog https://logging.apache.org/log4j/changelog-0.1.0.xsd" + type="fixed"> + <issue id="LOG4J2-3614" link="https://issues.apache.org/jira/browse/LOG4J2-3614"/> + <author id="vy"/> + <author name="strainu"/> + <description format="asciidoc">Harden `InstantFormatter` against delegate failures</description> +</entry> diff --git a/log4j-tools-parent/pom.xml b/log4j-tools-parent/pom.xml index c2dbf46..7370dfe 100644 --- a/log4j-tools-parent/pom.xml +++ b/log4j-tools-parent/pom.xml @@ -53,6 +53,7 @@ <!-- dependency versions --> <assertj.version>3.24.0</assertj.version> + <commons-io.version>2.11.0</commons-io.version> <freemarker.version>2.3.32</freemarker.version> <junit.version>5.9.2</junit.version> <maven-plugin.version>3.7.1</maven-plugin.version> @@ -76,6 +77,12 @@ <version>${assertj.version}</version> </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>${commons-io.version}</version> + </dependency> + <dependency> <groupId>org.freemarker</groupId> <artifactId>freemarker</artifactId>
