You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by pk...@apache.org on 2024/01/25 15:29:29 UTC

(logging-log4j2) branch move-async-end created (now 2fb51110e0)

This is an automated email from the ASF dual-hosted git repository.

pkarwasz pushed a change to branch move-async-end
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git


      at 2fb51110e0 Fix failing tests

This branch includes the following new commits:

     new 1db3d7e7e2 Last tweaks to tests before moving async support
     new 51d86c13a7 Move async support to `log4j-async-logger`
     new 2fb51110e0 Fix failing tests

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



(logging-log4j2) 01/03: Last tweaks to tests before moving async support

Posted by pk...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

pkarwasz pushed a commit to branch move-async-end
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git

commit 1db3d7e7e23e3223b5d75fe06ae52a494db90eda
Author: Piotr P. Karwasz <pi...@karwasz.org>
AuthorDate: Thu Jan 25 10:43:00 2024 +0100

    Last tweaks to tests before moving async support
    
    A couple more tests require changes to be independent from async loggers
    and logger configurations.
    
    The `CoreContextSelectors` class is not used, so we remove it.
---
 .../log4j/core/async/AsyncLateConfigTest.java      |  52 +++++
 .../core/async/QueueFullAsyncAbstractTest.java     | 256 +++++----------------
 .../core/async/QueueFullAsyncLogger2Test.java      |   3 +-
 .../core/async/QueueFullAsyncLogger3Test.java      |   2 +-
 ...llAsyncLoggerConfigLoggingFromToStringTest.java |   2 +-
 .../core/async/QueueFullAsyncLoggerConfigTest.java |   2 +-
 ...ueueFullAsyncLoggerLoggingFromToStringTest.java |   2 +-
 .../log4j/core/async/QueueFullAsyncLoggerTest.java |   2 +-
 .../log4j/core/async/QueueFullAbstractTest.java    | 158 +------------
 .../log4j/core/test/LateConfigAbstractTest.java}   |  41 +---
 .../log4j/core/test/LateConfigAbstractTest.xml     |  57 +++++
 .../apache/logging/log4j/core/LateConfigTest.java  |  41 +---
 .../src/test/resources/perf/SimplePerfTest.bat     |  47 ----
 .../src/test/resources/perf/SimplePerfTest.sh      |  56 -----
 .../src/test/resources/perf/runResponseTm.sh       |  61 -----
 .../log4j/core/selector/CoreContextSelectors.java  |  30 ---
 log4j-csv/pom.xml                                  |   5 +
 log4j-gc-test/pom.xml                              |   5 +
 log4j-jul/pom.xml                                  |   7 +-
 log4j-perf-test/pom.xml                            |   4 +
 20 files changed, 214 insertions(+), 619 deletions(-)

diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLateConfigTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLateConfigTest.java
new file mode 100644
index 0000000000..3c4b73fff7
--- /dev/null
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLateConfigTest.java
@@ -0,0 +1,52 @@
+/*
+ * 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.async;
+
+import java.nio.file.Path;
+import java.util.stream.Stream;
+import org.apache.logging.log4j.core.impl.Log4jContextFactory;
+import org.apache.logging.log4j.core.selector.ContextSelector;
+import org.apache.logging.log4j.core.test.LateConfigAbstractTest;
+import org.apache.logging.log4j.plugins.di.ConfigurableInstanceFactory;
+import org.apache.logging.log4j.plugins.di.DI;
+import org.apache.logging.log4j.test.junit.TempLoggingDir;
+import org.apache.logging.log4j.test.junit.UsingStatusListener;
+import org.junit.jupiter.api.Tag;
+import org.junit.jupiter.params.ParameterizedTest;
+import org.junit.jupiter.params.provider.MethodSource;
+
+@Tag("functional")
+@UsingStatusListener
+public class AsyncLateConfigTest extends LateConfigAbstractTest {
+
+    @TempLoggingDir
+    private static Path loggingPath;
+
+    static Stream<Log4jContextFactory> selectors() {
+        final ConfigurableInstanceFactory instanceFactory = DI.createInitializedFactory();
+        return Stream.<ContextSelector>of(
+                        new AsyncLoggerContextSelector(instanceFactory.newChildInstanceFactory()),
+                        new BasicAsyncLoggerContextSelector(instanceFactory.newChildInstanceFactory()))
+                .map(Log4jContextFactory::new);
+    }
+
+    @ParameterizedTest(name = "reconfigure {0}")
+    @MethodSource("selectors")
+    void reconfiguration(final Log4jContextFactory factory) throws Exception {
+        testReconfiguration(factory, loggingPath);
+    }
+}
diff --git a/log4j-core-test/src/main/java/org/apache/logging/log4j/core/async/QueueFullAbstractTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncAbstractTest.java
similarity index 53%
copy from log4j-core-test/src/main/java/org/apache/logging/log4j/core/async/QueueFullAbstractTest.java
copy to log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncAbstractTest.java
index 5085f7ec4f..03ea0a04c7 100644
--- a/log4j-core-test/src/main/java/org/apache/logging/log4j/core/async/QueueFullAbstractTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncAbstractTest.java
@@ -16,149 +16,69 @@
  */
 package org.apache.logging.log4j.core.async;
 
-import static java.util.concurrent.TimeUnit.SECONDS;
 import static org.assertj.core.api.Assertions.assertThat;
 
 import com.lmax.disruptor.RingBuffer;
-import java.lang.reflect.Field;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
 import java.util.List;
 import java.util.Optional;
-import java.util.Stack;
 import java.util.concurrent.CountDownLatch;
 import java.util.stream.Collectors;
 import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.Logger;
-import org.apache.logging.log4j.core.Appender;
-import org.apache.logging.log4j.core.LogEvent;
 import org.apache.logging.log4j.core.LoggerContext;
-import org.apache.logging.log4j.core.appender.AsyncAppender;
 import org.apache.logging.log4j.core.config.Configuration;
 import org.apache.logging.log4j.core.config.LoggerConfig;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
-import org.apache.logging.log4j.core.util.Constants;
 import org.apache.logging.log4j.status.StatusData;
-import org.apache.logging.log4j.status.StatusLogger;
 import org.apache.logging.log4j.test.ListStatusListener;
-import org.apache.logging.log4j.test.junit.UsingStatusListener;
-import org.apache.logging.log4j.util.ReflectionUtil;
-import org.junit.jupiter.api.Tag;
-import org.junit.jupiter.api.Timeout;
-import org.junit.jupiter.api.Timeout.ThreadMode;
 
-/**
- * Tests queue full scenarios abstract superclass.
- */
-@Tag("async")
-@UsingStatusListener
-@Timeout(value = 5, unit = SECONDS, threadMode = ThreadMode.SEPARATE_THREAD)
-public abstract class QueueFullAbstractTest {
-    protected static boolean TRACE = Boolean.getBoolean(QueueFullAbstractTest.class.getSimpleName() + ".TRACE");
-    protected BlockingAppender blockingAppender;
-    protected Unlocker unlocker;
-
-    protected static final String APPENDER_NAME = "Blocking";
-    protected static final int BUFFER_COUNT = 128;
-    protected static final int MESSAGE_COUNT = BUFFER_COUNT + 2;
-    protected static final Logger LOGGER = StatusLogger.getLogger();
-
-    protected static class Unlocker extends Thread {
-
-        final CountDownLatch countDownLatch;
-        final BlockingAppender blockingAppender;
-
-        Unlocker(final CountDownLatch countDownLatch, final BlockingAppender blockingAppender) {
-            this.countDownLatch = countDownLatch;
-            this.blockingAppender = blockingAppender;
-        }
-
-        @Override
-        public void run() {
-            try {
-                countDownLatch.await();
-                LOGGER.info("Unlocker activated. Sleeping 500 millis before taking action...");
-                Thread.sleep(500);
-            } catch (final InterruptedException e) {
-                throw new RuntimeException(e);
-            }
-            LOGGER.info("Unlocker signalling BlockingAppender to proceed...");
-            blockingAppender.countDownLatch.countDown();
-        }
-    }
-
-    protected static class DomainObject {
-
-        private final Logger innerLogger;
-        private final Unlocker unlocker;
-        private final int count;
-
-        public DomainObject(final Logger innerLogger, final Unlocker unlocker, final int loggingCount) {
-            this.innerLogger = innerLogger;
-            this.unlocker = unlocker;
-            this.count = loggingCount;
-        }
-
-        @Override
-        public String toString() {
-            for (int i = 0; i < count; i++) {
-                LOGGER.info(
-                        "DomainObject logging message {}. Ring buffer capacity was {}, countdown latch was {}.",
-                        i,
-                        asyncRemainingCapacity(innerLogger),
-                        unlocker.countDownLatch.getCount());
-                unlocker.countDownLatch.countDown();
-                innerLogger.info("Logging in toString() #{}", i);
-            }
-            return "Who's bad?!";
-        }
-    }
+public abstract class QueueFullAsyncAbstractTest extends QueueFullAbstractTest {
 
     private ListStatusListener statusListener;
 
-    protected void testNormalQueueFullKeepsMessagesInOrder(
-            final LoggerContext ctx, final BlockingAppender blockingAppender) throws Exception {
-        checkConfig(ctx);
-        final Logger logger = ctx.getLogger(getClass());
+    protected static void assertAsyncLogger(final LoggerContext ctx, final int expectedBufferSize) {
+        assertThat(ctx).isInstanceOf(AsyncLoggerContext.class);
+        assertThat(((AsyncLoggerContext) ctx)
+                        .getAsyncLoggerDisruptor()
+                        .getRingBuffer()
+                        .getBufferSize())
+                .isEqualTo(expectedBufferSize);
 
-        blockingAppender.countDownLatch = new CountDownLatch(1);
-        final Unlocker unlocker = new Unlocker(new CountDownLatch(MESSAGE_COUNT - 1), blockingAppender);
-        unlocker.start();
-        asyncTest(logger, unlocker, blockingAppender);
-        unlocker.join();
+        final Configuration config = ctx.getConfiguration();
+        assertThat(config).isNotNull();
+        assertThat(config.getRootLogger()).isNotInstanceOf(AsyncLoggerConfig.class);
     }
 
-    protected void checkConfig(final LoggerContext ctx) throws Exception {}
+    protected static void assertAsyncLoggerConfig(final LoggerContext ctx, final int expectedBufferSize) {
+        assertThat(ctx).isNotInstanceOf(AsyncLoggerContext.class);
 
-    protected static void asyncTest(
-            final Logger logger, final Unlocker unlocker, final BlockingAppender blockingAppender) {
-        for (int i = 0; i < MESSAGE_COUNT; i++) {
-            LOGGER.info(
-                    "Test logging message {}. Ring buffer capacity was {}, countdown latch was {}.",
-                    i,
-                    asyncRemainingCapacity(logger),
-                    unlocker.countDownLatch.getCount());
-            unlocker.countDownLatch.countDown();
-            final String param = "I'm innocent";
-            logger.info("Logging innocent object #{}: {}", i, param);
-        }
-        LOGGER.info(
-                "Waiting for message delivery: blockingAppender.logEvents.count={}.",
-                blockingAppender.logEvents.size());
-        while (blockingAppender.logEvents.size() < MESSAGE_COUNT) {
-            Thread.yield();
-        }
-        LOGGER.info(
-                "All {} message have been delivered: blockingAppender.logEvents.count={}.",
-                MESSAGE_COUNT,
-                blockingAppender.logEvents.size());
+        final Configuration config = ctx.getConfiguration();
+        assertThat(config).isNotNull();
+        assertThat(config.getRootLogger()).isInstanceOf(AsyncLoggerConfig.class);
+        final DisruptorConfiguration disruptorConfig = config.getExtension(DisruptorConfiguration.class);
+        final AsyncLoggerConfigDisruptor disruptor =
+                (AsyncLoggerConfigDisruptor) disruptorConfig.getAsyncLoggerConfigDelegate();
+        assertThat(disruptor.getRingBuffer().getBufferSize()).isEqualTo(expectedBufferSize);
+    }
 
-        final Stack<String> actual = transform(blockingAppender.logEvents);
-        for (int i = 0; i < MESSAGE_COUNT; i++) {
-            assertThat(actual.pop()).isEqualTo("Logging innocent object #%d: I'm innocent", i);
+    @Override
+    protected long asyncRemainingCapacity(final Logger logger) {
+        if (logger instanceof final AsyncLogger asyncLogger) {
+            return Optional.ofNullable(asyncLogger.getAsyncLoggerDisruptor())
+                    .map(AsyncLoggerDisruptor::getRingBuffer)
+                    .map(RingBuffer::remainingCapacity)
+                    .orElse(0L);
+        } else {
+            final LoggerConfig loggerConfig = ((org.apache.logging.log4j.core.Logger) logger).get();
+            if (loggerConfig instanceof final AsyncLoggerConfig asyncLoggerConfig) {
+                return Optional.ofNullable(
+                                (AsyncLoggerConfigDisruptor) asyncLoggerConfig.getAsyncLoggerConfigDelegate())
+                        .map(AsyncLoggerConfigDisruptor::getRingBuffer)
+                        .map(RingBuffer::remainingCapacity)
+                        .orElse(0L);
+            }
         }
-        assertThat(actual).isEmpty();
+        return super.asyncRemainingCapacity(logger);
     }
 
     public void testLoggingFromToStringCausesOutOfOrderMessages(
@@ -218,90 +138,30 @@ public abstract class QueueFullAbstractTest {
         assertThat(actual).hasSize(MESSAGE_COUNT).contains(expected);
     }
 
-    static Stack<String> transform(final List<LogEvent> logEvents) {
-        final List<String> filtered = getMessages(logEvents);
-        Collections.reverse(filtered);
-        final Stack<String> result = new Stack<>();
-        result.addAll(filtered);
-        return result;
-    }
+    protected class DomainObject {
+
+        private final Logger innerLogger;
+        private final Unlocker unlocker;
+        private final int count;
 
-    static List<String> getMessages(final List<LogEvent> logEvents) {
-        final List<String> filtered = new ArrayList<>(logEvents.size());
-        for (LogEvent event : logEvents) {
-            filtered.add(event.getMessage().getFormattedMessage());
+        public DomainObject(final Logger innerLogger, final Unlocker unlocker, final int loggingCount) {
+            this.innerLogger = innerLogger;
+            this.unlocker = unlocker;
+            this.count = loggingCount;
         }
-        return filtered;
-    }
 
-    static long asyncRemainingCapacity(final Logger logger) {
-        if (logger instanceof AsyncLogger asyncLogger) {
-            return Optional.ofNullable(asyncLogger.getAsyncLoggerDisruptor())
-                    .map(AsyncLoggerDisruptor::getRingBuffer)
-                    .map(RingBuffer::remainingCapacity)
-                    .orElse(0L);
-        } else {
-            final LoggerConfig loggerConfig = ((org.apache.logging.log4j.core.Logger) logger).get();
-            if (loggerConfig instanceof AsyncLoggerConfig asyncLoggerConfig) {
-                return Optional.ofNullable(
-                                (AsyncLoggerConfigDisruptor) asyncLoggerConfig.getAsyncLoggerConfigDelegate())
-                        .map(AsyncLoggerConfigDisruptor::getRingBuffer)
-                        .map(RingBuffer::remainingCapacity)
-                        .orElse(0L);
-            } else {
-                final Appender async = loggerConfig.getAppenders().get("async");
-                if (async instanceof AsyncAppender) {
-                    return ((AsyncAppender) async).getQueueCapacity();
-                }
+        @Override
+        public String toString() {
+            for (int i = 0; i < count; i++) {
+                LOGGER.info(
+                        "DomainObject logging message {}. Ring buffer capacity was {}, countdown latch was {}.",
+                        i,
+                        asyncRemainingCapacity(innerLogger),
+                        unlocker.countDownLatch.getCount());
+                unlocker.countDownLatch.countDown();
+                innerLogger.info("Logging in toString() #{}", i);
             }
+            return "Who's bad?!";
         }
-        throw new IllegalStateException("Neither Async Loggers nor AsyncAppender are configured");
-    }
-
-    protected static Field field(final Class<?> c, final String name) throws NoSuchFieldException {
-        final Field f = c.getDeclaredField(name);
-        ReflectionUtil.makeAccessible(f);
-        return f;
-    }
-
-    protected static void assertAsyncAppender(final LoggerContext ctx) {
-        assertThat(ctx).isNotInstanceOf(AsyncLoggerContext.class);
-
-        final Configuration config = ctx.getConfiguration();
-        assertThat(config).isNotNull();
-        assertThat(config.getRootLogger()).isNotInstanceOf(AsyncLoggerConfig.class);
-
-        final Collection<Appender> appenders =
-                config.getRootLogger().getAppenders().values();
-        assertThat(appenders).hasSize(1).allMatch(AsyncAppender.class::isInstance);
-    }
-
-    protected static void assertAsyncLogger(final LoggerContext ctx, final int expectedBufferSize) {
-        assertThat(ctx).isInstanceOf(AsyncLoggerContext.class);
-        assertThat(((AsyncLoggerContext) ctx)
-                        .getAsyncLoggerDisruptor()
-                        .getRingBuffer()
-                        .getBufferSize())
-                .isEqualTo(expectedBufferSize);
-
-        final Configuration config = ctx.getConfiguration();
-        assertThat(config).isNotNull();
-        assertThat(config.getRootLogger()).isNotInstanceOf(AsyncLoggerConfig.class);
-    }
-
-    protected static void assertAsyncLoggerConfig(final LoggerContext ctx, final int expectedBufferSize) {
-        assertThat(ctx).isNotInstanceOf(AsyncLoggerContext.class);
-
-        final Configuration config = ctx.getConfiguration();
-        assertThat(config).isNotNull();
-        assertThat(config.getRootLogger()).isInstanceOf(AsyncLoggerConfig.class);
-        final DisruptorConfiguration disruptorConfig = config.getExtension(DisruptorConfiguration.class);
-        final AsyncLoggerConfigDisruptor disruptor =
-                (AsyncLoggerConfigDisruptor) disruptorConfig.getAsyncLoggerConfigDelegate();
-        assertThat(disruptor.getRingBuffer().getBufferSize()).isEqualTo(expectedBufferSize);
-    }
-
-    protected static void assertFormatMessagesInBackground() {
-        assertThat(Constants.FORMAT_MESSAGES_IN_BACKGROUND).isTrue();
     }
 }
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger2Test.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger2Test.java
index beda3aa982..962ac5fb74 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger2Test.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger2Test.java
@@ -24,11 +24,10 @@ import org.apache.logging.log4j.test.junit.SetTestProperty;
  * is immutable.
  */
 @SetTestProperty(key = "AsyncLogger.formatMsg", value = "true")
-public class QueueFullAsyncLogger2Test extends QueueFullAsyncLoggerTest {
+public class QueueFullAsyncLogger2Test extends QueueFullAsyncAbstractTest {
 
     @Override
     protected void checkConfig(final LoggerContext ctx) {
-        super.checkConfig(ctx);
         assertFormatMessagesInBackground();
     }
 }
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger3Test.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger3Test.java
index 1df420b8d7..8debb4b435 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger3Test.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger3Test.java
@@ -41,7 +41,7 @@ import org.junit.jupiter.api.Timeout;
 @SetTestProperty(key = "AsyncLogger.ringBufferSize", value = "128")
 @SetTestProperty(key = "AsyncLogger.formatMsg", value = "true")
 @SetTestProperty(key = "AsyncLogger.queueFullPolicy", value = "Discard")
-public class QueueFullAsyncLogger3Test extends QueueFullAbstractTest {
+public class QueueFullAsyncLogger3Test extends QueueFullAsyncAbstractTest {
 
     @Override
     protected void checkConfig(final LoggerContext ctx) {
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToStringTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToStringTest.java
index cdeec6a0f5..e9d78fa638 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToStringTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToStringTest.java
@@ -31,7 +31,7 @@ import org.junit.jupiter.api.Test;
  */
 @SetTestProperty(key = "Web.isWebApp", value = "false")
 @SetTestProperty(key = "AsyncLoggerConfig.ringBufferSize", value = "128")
-public class QueueFullAsyncLoggerConfigLoggingFromToStringTest extends QueueFullAbstractTest {
+public class QueueFullAsyncLoggerConfigLoggingFromToStringTest extends QueueFullAsyncAbstractTest {
 
     @Override
     @Test
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigTest.java
index 76eaa471dd..feb04be22e 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigTest.java
@@ -27,7 +27,7 @@ import org.junit.jupiter.api.Test;
  * Tests queue full scenarios with AsyncLoggers in configuration.
  */
 @SetTestProperty(key = "AsyncLoggerConfig.ringBufferSize", value = "128")
-public class QueueFullAsyncLoggerConfigTest extends QueueFullAbstractTest {
+public class QueueFullAsyncLoggerConfigTest extends QueueFullAsyncAbstractTest {
 
     @Override
     @Test
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerLoggingFromToStringTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerLoggingFromToStringTest.java
index 49e3e125b8..e58bd1a7ab 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerLoggingFromToStringTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerLoggingFromToStringTest.java
@@ -30,7 +30,7 @@ import org.junit.jupiter.api.Test;
         key = "LoggerContext.selector",
         value = "org.apache.logging.log4j.core.async.AsyncLoggerContextSelector")
 @SetTestProperty(key = "AsyncLogger.ringBufferSize", value = "128")
-public class QueueFullAsyncLoggerLoggingFromToStringTest extends QueueFullAbstractTest {
+public class QueueFullAsyncLoggerLoggingFromToStringTest extends QueueFullAsyncAbstractTest {
 
     @Override
     @Test
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerTest.java
index 064517ae63..0c2e41a316 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerTest.java
@@ -30,7 +30,7 @@ import org.junit.jupiter.api.Test;
         key = "LoggerContext.selector",
         value = "org.apache.logging.log4j.core.async.AsyncLoggerContextSelector")
 @SetTestProperty(key = "AsyncLogger.ringBufferSize", value = "128")
-public class QueueFullAsyncLoggerTest extends QueueFullAbstractTest {
+public class QueueFullAsyncLoggerTest extends QueueFullAsyncAbstractTest {
 
     @Override
     @Test
diff --git a/log4j-core-test/src/main/java/org/apache/logging/log4j/core/async/QueueFullAbstractTest.java b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/async/QueueFullAbstractTest.java
index 5085f7ec4f..f6ea81eb13 100644
--- a/log4j-core-test/src/main/java/org/apache/logging/log4j/core/async/QueueFullAbstractTest.java
+++ b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/async/QueueFullAbstractTest.java
@@ -19,17 +19,12 @@ package org.apache.logging.log4j.core.async;
 import static java.util.concurrent.TimeUnit.SECONDS;
 import static org.assertj.core.api.Assertions.assertThat;
 
-import com.lmax.disruptor.RingBuffer;
-import java.lang.reflect.Field;
 import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Collections;
 import java.util.List;
-import java.util.Optional;
 import java.util.Stack;
 import java.util.concurrent.CountDownLatch;
-import java.util.stream.Collectors;
-import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.Logger;
 import org.apache.logging.log4j.core.Appender;
 import org.apache.logging.log4j.core.LogEvent;
@@ -39,11 +34,8 @@ import org.apache.logging.log4j.core.config.Configuration;
 import org.apache.logging.log4j.core.config.LoggerConfig;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
 import org.apache.logging.log4j.core.util.Constants;
-import org.apache.logging.log4j.status.StatusData;
 import org.apache.logging.log4j.status.StatusLogger;
-import org.apache.logging.log4j.test.ListStatusListener;
 import org.apache.logging.log4j.test.junit.UsingStatusListener;
-import org.apache.logging.log4j.util.ReflectionUtil;
 import org.junit.jupiter.api.Tag;
 import org.junit.jupiter.api.Timeout;
 import org.junit.jupiter.api.Timeout.ThreadMode;
@@ -88,35 +80,6 @@ public abstract class QueueFullAbstractTest {
         }
     }
 
-    protected static class DomainObject {
-
-        private final Logger innerLogger;
-        private final Unlocker unlocker;
-        private final int count;
-
-        public DomainObject(final Logger innerLogger, final Unlocker unlocker, final int loggingCount) {
-            this.innerLogger = innerLogger;
-            this.unlocker = unlocker;
-            this.count = loggingCount;
-        }
-
-        @Override
-        public String toString() {
-            for (int i = 0; i < count; i++) {
-                LOGGER.info(
-                        "DomainObject logging message {}. Ring buffer capacity was {}, countdown latch was {}.",
-                        i,
-                        asyncRemainingCapacity(innerLogger),
-                        unlocker.countDownLatch.getCount());
-                unlocker.countDownLatch.countDown();
-                innerLogger.info("Logging in toString() #{}", i);
-            }
-            return "Who's bad?!";
-        }
-    }
-
-    private ListStatusListener statusListener;
-
     protected void testNormalQueueFullKeepsMessagesInOrder(
             final LoggerContext ctx, final BlockingAppender blockingAppender) throws Exception {
         checkConfig(ctx);
@@ -129,10 +92,9 @@ public abstract class QueueFullAbstractTest {
         unlocker.join();
     }
 
-    protected void checkConfig(final LoggerContext ctx) throws Exception {}
+    protected abstract void checkConfig(final LoggerContext ctx) throws Exception;
 
-    protected static void asyncTest(
-            final Logger logger, final Unlocker unlocker, final BlockingAppender blockingAppender) {
+    protected void asyncTest(final Logger logger, final Unlocker unlocker, final BlockingAppender blockingAppender) {
         for (int i = 0; i < MESSAGE_COUNT; i++) {
             LOGGER.info(
                     "Test logging message {}. Ring buffer capacity was {}, countdown latch was {}.",
@@ -161,63 +123,6 @@ public abstract class QueueFullAbstractTest {
         assertThat(actual).isEmpty();
     }
 
-    public void testLoggingFromToStringCausesOutOfOrderMessages(
-            final LoggerContext ctx, final BlockingAppender blockingAppender) throws Exception {
-        checkConfig(ctx);
-        // Non-reusable messages will call `toString()` on the main thread and block it.
-        final Logger logger = ctx.getLogger(this.getClass());
-
-        blockingAppender.countDownLatch = new CountDownLatch(1);
-        final Unlocker unlocker = new Unlocker(new CountDownLatch(MESSAGE_COUNT - 1), blockingAppender);
-        unlocker.start();
-        asyncRecursiveTest(logger, unlocker, blockingAppender);
-        unlocker.join();
-    }
-
-    void asyncRecursiveTest(final Logger logger, final Unlocker unlocker, final BlockingAppender blockingAppender) {
-        for (int i = 0; i < 1; i++) {
-            LOGGER.info(
-                    "Test logging message {}. Ring buffer capacity was {}, countdown latch was {}.",
-                    i,
-                    asyncRemainingCapacity(logger),
-                    unlocker.countDownLatch.getCount());
-            unlocker.countDownLatch.countDown();
-            final DomainObject obj = new DomainObject(logger, unlocker, MESSAGE_COUNT - 1);
-            logger.info("Logging naughty object #{}: {}", i, obj);
-        }
-
-        LOGGER.info(
-                "Waiting for message delivery: blockingAppender.logEvents.count={}.",
-                blockingAppender.logEvents.size());
-        while (blockingAppender.logEvents.size() < MESSAGE_COUNT) {
-            Thread.yield();
-        }
-        LOGGER.info(
-                "All {} messages have been delivered: blockingAppender.logEvents.count={}.",
-                MESSAGE_COUNT,
-                blockingAppender.logEvents.size());
-
-        final StatusData mostRecentStatusData = statusListener
-                .findStatusData(Level.WARN)
-                .reduce((ignored, data) -> data)
-                .orElse(null);
-        assertThat(mostRecentStatusData).isNotNull();
-        assertThat(mostRecentStatusData.getLevel()).isEqualTo(Level.WARN);
-        assertThat(mostRecentStatusData.getFormattedStatus())
-                .contains("Log4j2 logged an event out of order to prevent deadlock caused by domain "
-                        + "objects logging from their toString method when the async queue is full");
-
-        final List<String> actual = blockingAppender.logEvents.stream()
-                .map(e -> e.getMessage().getFormattedMessage())
-                .collect(Collectors.toList());
-        final String[] expected = new String[MESSAGE_COUNT];
-        for (int i = 0; i < MESSAGE_COUNT - 1; i++) {
-            expected[i] = "Logging in toString() #" + i;
-        }
-        expected[MESSAGE_COUNT - 1] = "Logging naughty object #0: Who's bad?!";
-        assertThat(actual).hasSize(MESSAGE_COUNT).contains(expected);
-    }
-
     static Stack<String> transform(final List<LogEvent> logEvents) {
         final List<String> filtered = getMessages(logEvents);
         Collections.reverse(filtered);
@@ -234,73 +139,24 @@ public abstract class QueueFullAbstractTest {
         return filtered;
     }
 
-    static long asyncRemainingCapacity(final Logger logger) {
-        if (logger instanceof AsyncLogger asyncLogger) {
-            return Optional.ofNullable(asyncLogger.getAsyncLoggerDisruptor())
-                    .map(AsyncLoggerDisruptor::getRingBuffer)
-                    .map(RingBuffer::remainingCapacity)
-                    .orElse(0L);
-        } else {
-            final LoggerConfig loggerConfig = ((org.apache.logging.log4j.core.Logger) logger).get();
-            if (loggerConfig instanceof AsyncLoggerConfig asyncLoggerConfig) {
-                return Optional.ofNullable(
-                                (AsyncLoggerConfigDisruptor) asyncLoggerConfig.getAsyncLoggerConfigDelegate())
-                        .map(AsyncLoggerConfigDisruptor::getRingBuffer)
-                        .map(RingBuffer::remainingCapacity)
-                        .orElse(0L);
-            } else {
-                final Appender async = loggerConfig.getAppenders().get("async");
-                if (async instanceof AsyncAppender) {
-                    return ((AsyncAppender) async).getQueueCapacity();
-                }
-            }
+    protected long asyncRemainingCapacity(final Logger logger) {
+        final LoggerConfig loggerConfig = ((org.apache.logging.log4j.core.Logger) logger).get();
+        final Appender async = loggerConfig.getAppenders().get("async");
+        if (async instanceof AsyncAppender) {
+            return ((AsyncAppender) async).getQueueCapacity();
         }
         throw new IllegalStateException("Neither Async Loggers nor AsyncAppender are configured");
     }
 
-    protected static Field field(final Class<?> c, final String name) throws NoSuchFieldException {
-        final Field f = c.getDeclaredField(name);
-        ReflectionUtil.makeAccessible(f);
-        return f;
-    }
-
     protected static void assertAsyncAppender(final LoggerContext ctx) {
-        assertThat(ctx).isNotInstanceOf(AsyncLoggerContext.class);
-
         final Configuration config = ctx.getConfiguration();
         assertThat(config).isNotNull();
-        assertThat(config.getRootLogger()).isNotInstanceOf(AsyncLoggerConfig.class);
 
         final Collection<Appender> appenders =
                 config.getRootLogger().getAppenders().values();
         assertThat(appenders).hasSize(1).allMatch(AsyncAppender.class::isInstance);
     }
 
-    protected static void assertAsyncLogger(final LoggerContext ctx, final int expectedBufferSize) {
-        assertThat(ctx).isInstanceOf(AsyncLoggerContext.class);
-        assertThat(((AsyncLoggerContext) ctx)
-                        .getAsyncLoggerDisruptor()
-                        .getRingBuffer()
-                        .getBufferSize())
-                .isEqualTo(expectedBufferSize);
-
-        final Configuration config = ctx.getConfiguration();
-        assertThat(config).isNotNull();
-        assertThat(config.getRootLogger()).isNotInstanceOf(AsyncLoggerConfig.class);
-    }
-
-    protected static void assertAsyncLoggerConfig(final LoggerContext ctx, final int expectedBufferSize) {
-        assertThat(ctx).isNotInstanceOf(AsyncLoggerContext.class);
-
-        final Configuration config = ctx.getConfiguration();
-        assertThat(config).isNotNull();
-        assertThat(config.getRootLogger()).isInstanceOf(AsyncLoggerConfig.class);
-        final DisruptorConfiguration disruptorConfig = config.getExtension(DisruptorConfiguration.class);
-        final AsyncLoggerConfigDisruptor disruptor =
-                (AsyncLoggerConfigDisruptor) disruptorConfig.getAsyncLoggerConfigDelegate();
-        assertThat(disruptor.getRingBuffer().getBufferSize()).isEqualTo(expectedBufferSize);
-    }
-
     protected static void assertFormatMessagesInBackground() {
         assertThat(Constants.FORMAT_MESSAGES_IN_BACKGROUND).isTrue();
     }
diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/LateConfigTest.java b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/LateConfigAbstractTest.java
similarity index 56%
copy from log4j-core-test/src/test/java/org/apache/logging/log4j/core/LateConfigTest.java
copy to log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/LateConfigAbstractTest.java
index 3263ed6f25..f87bce912e 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/LateConfigTest.java
+++ b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/LateConfigAbstractTest.java
@@ -14,58 +14,33 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core;
+package org.apache.logging.log4j.core.test;
 
 import static org.assertj.core.api.Assertions.assertThat;
 import static org.junit.jupiter.api.Assertions.assertSame;
 
 import java.net.URI;
 import java.nio.file.Path;
-import java.util.stream.Stream;
-import org.apache.logging.log4j.core.async.AsyncLoggerContextSelector;
-import org.apache.logging.log4j.core.async.BasicAsyncLoggerContextSelector;
+import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.config.Configuration;
 import org.apache.logging.log4j.core.config.DefaultConfiguration;
 import org.apache.logging.log4j.core.config.xml.XmlConfiguration;
 import org.apache.logging.log4j.core.impl.Log4jContextFactory;
-import org.apache.logging.log4j.core.selector.BasicContextSelector;
-import org.apache.logging.log4j.core.selector.ClassLoaderContextSelector;
-import org.apache.logging.log4j.core.selector.ContextSelector;
-import org.apache.logging.log4j.plugins.di.ConfigurableInstanceFactory;
-import org.apache.logging.log4j.plugins.di.DI;
-import org.apache.logging.log4j.test.junit.TempLoggingDir;
-import org.junit.jupiter.api.Tag;
-import org.junit.jupiter.params.ParameterizedTest;
-import org.junit.jupiter.params.provider.MethodSource;
 
-@Tag("functional")
-public class LateConfigTest {
+public class LateConfigAbstractTest {
 
-    private static final String CONFIG = "/log4j-test1.xml";
+    private static final String CONFIG = "LateConfigAbstractTest.xml";
     // This class will be the caller of `Log4jContextFactory`
     private static final String FQCN = Log4jContextFactory.class.getName();
 
-    @TempLoggingDir
-    private static Path loggingPath;
-
-    static Stream<Log4jContextFactory> selectors() {
-        final ConfigurableInstanceFactory instanceFactory = DI.createInitializedFactory();
-        return Stream.<ContextSelector>of(
-                        new ClassLoaderContextSelector(instanceFactory.newChildInstanceFactory()),
-                        new BasicContextSelector(instanceFactory.newChildInstanceFactory()),
-                        new AsyncLoggerContextSelector(instanceFactory.newChildInstanceFactory()),
-                        new BasicAsyncLoggerContextSelector(instanceFactory.newChildInstanceFactory()))
-                .map(Log4jContextFactory::new);
-    }
-
-    @ParameterizedTest(name = "reconfigure {0}")
-    @MethodSource("selectors")
-    public void testReconfiguration(final Log4jContextFactory factory) throws Exception {
+    protected static void testReconfiguration(final Log4jContextFactory factory, final Path loggingPath)
+            throws Exception {
         try (final LoggerContext context = factory.getContext(FQCN, null, null, false)) {
             final Configuration defaultConfig = context.getConfiguration();
             assertThat(defaultConfig).isInstanceOf(DefaultConfiguration.class);
 
-            final URI configLocation = LateConfigTest.class.getResource(CONFIG).toURI();
+            final URI configLocation =
+                    LateConfigAbstractTest.class.getResource(CONFIG).toURI();
             final LoggerContext context1 = factory.getContext(FQCN, null, null, false, configLocation, null);
             assertThat(context1).isSameAs(context);
             assertThat(loggingPath.resolve("test-xml.log")).exists();
diff --git a/log4j-core-test/src/main/resources/org/apache/logging/log4j/core/test/LateConfigAbstractTest.xml b/log4j-core-test/src/main/resources/org/apache/logging/log4j/core/test/LateConfigAbstractTest.xml
new file mode 100644
index 0000000000..8233fbf38b
--- /dev/null
+++ b/log4j-core-test/src/main/resources/org/apache/logging/log4j/core/test/LateConfigAbstractTest.xml
@@ -0,0 +1,57 @@
+<?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.
+  -->
+<Configuration status="OFF" name="XMLConfigTest">
+  <Properties>
+    <Property name="filename">${test:logging.path}/test-xml.log</Property>
+  </Properties>
+  <ThresholdFilter level="debug"/>
+
+  <Appenders>
+    <Console name="STDOUT">
+      <PatternLayout pattern="%m%n"/>
+    </Console>
+    <File name="File" fileName="${filename}" bufferedIO="false">
+      <PatternLayout>
+        <Pattern>%d %p %C{1.} [%t] %m%n</Pattern>
+      </PatternLayout>
+    </File>
+    <List name="List">
+      <Filters>
+        <ThresholdFilter level="error"/>
+      </Filters>
+    </List>
+  </Appenders>
+
+  <Loggers>
+    <Logger name="org.apache.logging.log4j.test1" level="debug" additivity="false">
+        <ThreadContextMapFilter>
+          <KeyValuePair key="test" value="123"/>
+        </ThreadContextMapFilter>
+      <AppenderRef ref="STDOUT"/>
+    </Logger>
+
+    <Logger name="org.apache.logging.log4j.test2" level="debug" additivity="false">
+      <AppenderRef ref="File"/>
+    </Logger>
+
+    <Root level="error">
+      <AppenderRef ref="STDOUT"/>
+    </Root>
+  </Loggers>
+
+</Configuration>
diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/LateConfigTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/LateConfigTest.java
index 3263ed6f25..ab3a8f8fa6 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/LateConfigTest.java
+++ b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/LateConfigTest.java
@@ -16,34 +16,24 @@
  */
 package org.apache.logging.log4j.core;
 
-import static org.assertj.core.api.Assertions.assertThat;
-import static org.junit.jupiter.api.Assertions.assertSame;
-
-import java.net.URI;
 import java.nio.file.Path;
 import java.util.stream.Stream;
-import org.apache.logging.log4j.core.async.AsyncLoggerContextSelector;
-import org.apache.logging.log4j.core.async.BasicAsyncLoggerContextSelector;
-import org.apache.logging.log4j.core.config.Configuration;
-import org.apache.logging.log4j.core.config.DefaultConfiguration;
-import org.apache.logging.log4j.core.config.xml.XmlConfiguration;
 import org.apache.logging.log4j.core.impl.Log4jContextFactory;
 import org.apache.logging.log4j.core.selector.BasicContextSelector;
 import org.apache.logging.log4j.core.selector.ClassLoaderContextSelector;
 import org.apache.logging.log4j.core.selector.ContextSelector;
+import org.apache.logging.log4j.core.test.LateConfigAbstractTest;
 import org.apache.logging.log4j.plugins.di.ConfigurableInstanceFactory;
 import org.apache.logging.log4j.plugins.di.DI;
 import org.apache.logging.log4j.test.junit.TempLoggingDir;
+import org.apache.logging.log4j.test.junit.UsingStatusListener;
 import org.junit.jupiter.api.Tag;
 import org.junit.jupiter.params.ParameterizedTest;
 import org.junit.jupiter.params.provider.MethodSource;
 
 @Tag("functional")
-public class LateConfigTest {
-
-    private static final String CONFIG = "/log4j-test1.xml";
-    // This class will be the caller of `Log4jContextFactory`
-    private static final String FQCN = Log4jContextFactory.class.getName();
+@UsingStatusListener
+public class LateConfigTest extends LateConfigAbstractTest {
 
     @TempLoggingDir
     private static Path loggingPath;
@@ -52,30 +42,13 @@ public class LateConfigTest {
         final ConfigurableInstanceFactory instanceFactory = DI.createInitializedFactory();
         return Stream.<ContextSelector>of(
                         new ClassLoaderContextSelector(instanceFactory.newChildInstanceFactory()),
-                        new BasicContextSelector(instanceFactory.newChildInstanceFactory()),
-                        new AsyncLoggerContextSelector(instanceFactory.newChildInstanceFactory()),
-                        new BasicAsyncLoggerContextSelector(instanceFactory.newChildInstanceFactory()))
+                        new BasicContextSelector(instanceFactory.newChildInstanceFactory()))
                 .map(Log4jContextFactory::new);
     }
 
     @ParameterizedTest(name = "reconfigure {0}")
     @MethodSource("selectors")
-    public void testReconfiguration(final Log4jContextFactory factory) throws Exception {
-        try (final LoggerContext context = factory.getContext(FQCN, null, null, false)) {
-            final Configuration defaultConfig = context.getConfiguration();
-            assertThat(defaultConfig).isInstanceOf(DefaultConfiguration.class);
-
-            final URI configLocation = LateConfigTest.class.getResource(CONFIG).toURI();
-            final LoggerContext context1 = factory.getContext(FQCN, null, null, false, configLocation, null);
-            assertThat(context1).isSameAs(context);
-            assertThat(loggingPath.resolve("test-xml.log")).exists();
-            final Configuration newConfig = context.getConfiguration();
-            assertThat(newConfig).isInstanceOf(XmlConfiguration.class);
-
-            final LoggerContext context2 = factory.getContext(FQCN, null, null, false);
-            assertThat(context2).isSameAs(context);
-            final Configuration sameConfig = context.getConfiguration();
-            assertSame(newConfig, sameConfig, "Configuration should not have been reset");
-        }
+    void reconfiguration(final Log4jContextFactory factory) throws Exception {
+        testReconfiguration(factory, loggingPath);
     }
 }
diff --git a/log4j-core-test/src/test/resources/perf/SimplePerfTest.bat b/log4j-core-test/src/test/resources/perf/SimplePerfTest.bat
deleted file mode 100644
index d6ca9ec1ba..0000000000
--- a/log4j-core-test/src/test/resources/perf/SimplePerfTest.bat
+++ /dev/null
@@ -1,47 +0,0 @@
-@echo off
-rem Licensed to the Apache Software Foundation (ASF) under one or more
-rem contributor license agreements.  See the NOTICE file distributed with
-rem this work for additional information regarding copyright ownership.
-rem The ASF licenses this file to You under the Apache License, Version 2.0
-rem (the "License"); you may not use this file except in compliance with
-rem the License.  You may obtain a copy of the License at
-rem
-rem     http://www.apache.org/licenses/LICENSE-2.0
-rem
-rem Unless required by applicable law or agreed to in writing, software
-rem distributed under the License is distributed on an "AS IS" BASIS,
-rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-rem See the License for the specific language governing permissions and
-rem limitations under the License.
-
-REM reject if no arg supplied
-IF %1.==. echo Usage: %0 version [core-version] & exit /b
-IF %2.==. set %2=%1
-
-set GC_OPTIONS=
-:set GC_OPTIONS=-XX:+UnlockDiagnosticVMOptions -verbose:gc -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintTenuringDistribution -XX:+PrintGCApplicationConcurrentTime -XX:+PrintGCApplicationStoppedTime
-:set GC_OPTIONS=-XX:+PrintCompilation
-
-set LOG4J_OPTIONS=
-set LOG4J_OPTIONS=-Dlog4j.configurationFile=perf-CountingNoOpAppender.xml
-:set LOG4J_OPTIONS=-Dlog4j.configurationFile=perf3PlainNoLoc.xml
-set LOG4J_OPTIONS=%LOG4J_OPTIONS% -DLog4jContextSelector=org.apache.logging.log4j.core.async.AsyncLoggerContextSelector
-:set LOG4J_OPTIONS=%LOG4J_OPTIONS% -Dlog4j2.enable.threadlocals=true
-:set LOG4J_OPTIONS=%LOG4J_OPTIONS% -DAsyncLogger.WaitStrategy=Yield
-:set LOG4J_OPTIONS=%LOG4J_OPTIONS% -DAsyncLogger.RingBufferSize=262144
-
-REM Java Flight Recorder settings: %JAVA_HOME%jre\lib\jfr\default.jfc
-REM Tip: set all 3 settings for "allocation-profiling-enabled" to true
-set JFR_OPTIONS=
-set JFR_OPTIONS=-XX:+UnlockCommercialFeatures -XX:+UnlockDiagnosticVMOptions -XX:+DebugNonSafepoints -XX:+FlightRecorder
-set JFR_OPTIONS=%JFR_OPTIONS% -XX:StartFlightRecording=duration=60s,filename=log4j-%1.jfr
-
-set CP=
-set CP=log4j-api-%1.jar;log4j-core-%1.jar;disruptor-3.3.4.jar;log4j-1.2.17.jar;slf4j-api-1.7.13.jar;logback-classic-1.1.3.jar;logback-core-1.1.3.jar
-set CP=%CP%;C:\Users\remko\IdeaProjects\logging-log4j2\log4j-core\target\test-classes
-:set CP=%CP%;log4j-core-2.6-SNAPSHOT-tests.jar
-
-set MAIN=org.apache.logging.log4j.core.async.perftest.SimplePerfTest
-
-@echo on
-java -Xms256M -Xmx256M %JFR_OPTIONS% %GC_OPTIONS% %LOG4J_OPTIONS% -cp %CP% %MAIN%
diff --git a/log4j-core-test/src/test/resources/perf/SimplePerfTest.sh b/log4j-core-test/src/test/resources/perf/SimplePerfTest.sh
deleted file mode 100644
index ec877a0829..0000000000
--- a/log4j-core-test/src/test/resources/perf/SimplePerfTest.sh
+++ /dev/null
@@ -1,56 +0,0 @@
-#!/bin/sh
-#
-#
-# 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.
-#
-if [ $# -eq 0 ]; then
-    echo Usage: $0 api-version core-version
-    exit 1
-fi
-
-DIR=$HOME
-NOW=$(date +%Y%m%d-%H%M%S)
-
-GC_OPTIONS="-XX:+UnlockDiagnosticVMOptions -verbose:gc -XX:+PrintGCDetails -XX:+PrintGCDateStamps"
-GC_OPTIONS="${GC_OPTIONS} -XX:+PrintTenuringDistribution -XX:+PrintGCApplicationConcurrentTime -XX:+PrintGCApplicationStoppedTime"
-GC_OPTIONS="${GC_OPTIONS} -XX:+PrintGCCause -Xloggc:$DIR/gc-$NOW.log"
-#GC_OPTIONS="${GC_OPTIONS} -XX:+PrintSafepointStatistics -XX:+LogVMOutput -XX:LogFile=$DIR/safepoint$NOW.log"
-GC_OPTIONS=
-
-# Needs -XX:+UnlockDiagnosticVMOptions (as first VM arg)
-#VM_OPTIONS="-XX:+PrintCompilation -XX:+PrintInlining"
-
-LOG4J_OPTIONS="-Dlog4j.configurationFile=perf-CountingNoOpAppender.xml"
-LOG4J_OPTIONS="${LOG4J_OPTIONS} -DLog4jContextSelector=org.apache.logging.log4j.core.async.AsyncLoggerContextSelector"
-LOG4J_OPTIONS="${LOG4J_OPTIONS} -DAsyncLogger.WaitStrategy=Block"
-LOG4J_OPTIONS="${LOG4J_OPTIONS} -Dlog4j.format.msg.async=true"
-export LOG4J_OPTIONS
-
-CP="log4j-api-${1}.jar:log4j-core-${2}.jar:disruptor-3.3.4.jar"
-CP="${CP}:log4j-core-2.6-SNAPSHOT-tests.jar"
-#CP="${CP}:${HOME}/Documents/log4j/log4j-core/target/test-classes"
-export CP
-
-export MEM_OPTIONS="-Xms128m -Xmx128m"
-export MAIN="org.apache.logging.log4j.core.async.perftest.SimplePerfTest"
-
-#PERF_OPTIONS="-e cycles,instructions,cache-references,cache-misses,branches,branch-misses,L1-dcache-loads,L1-dcache-load-misses,dTLB-loads,dTLB-load-misses"
-PERF_OPTIONS=
-#perf stat ${PERF_OPTIONS} java ${MEM_OPTIONS} ${GC_OPTIONS} ${VM_OPTIONS} ${LOG4J_OPTIONS} -cp "${CP}" ${MAIN}
-
-java ${MEM_OPTIONS} ${GC_OPTIONS} ${VM_OPTIONS} ${LOG4J_OPTIONS} -cp "${CP}" ${MAIN}
diff --git a/log4j-core-test/src/test/resources/perf/runResponseTm.sh b/log4j-core-test/src/test/resources/perf/runResponseTm.sh
deleted file mode 100644
index 2860dcd9be..0000000000
--- a/log4j-core-test/src/test/resources/perf/runResponseTm.sh
+++ /dev/null
@@ -1,61 +0,0 @@
-#!/bin/sh
-#
-#
-# 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.
-#
-
-NOW=$(date +%Y%m%d-%H%M%S)
-
-GC_OPTIONS="-XX:+UnlockDiagnosticVMOptions -verbose:gc -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintTenuringDistribution -XX:+PrintGCApplicationConcurrentTime -XX:+PrintGCApplicationStoppedTime"
-#GC_OPTIONS="${GC_OPTIONS} -XX:GuaranteedSafepointInterval=500000"
-GC_OPTIONS="${GC_OPTIONS} -XX:+PrintGCCause  -XX:+PrintSafepointStatistics -XX:+LogVMOutput -XX:LogFile=safepoint$NOW.log"
-COMPILE_OPTIONS="-XX:CompileCommand=dontinline,org.apache.logging.log4j.core.async.perftest.NoOpIdleStrategy::idle"
-
-#VM_OPTIONS="-XX:+UnlockDiagnosticVMOptions -XX:+PrintCompilation -XX:+PrintInlining"
-
-LOG4J_OPTIONS=
-#LOG4J_OPTIONS="-Dlog4j.configurationFile=perf-CountingNoOpAppender.xml"
-#LOG4J_OPTIONS="-Dlog4j.configurationFile=perf3PlainNoLoc.xml"
-#LOG4J_OPTIONS="-Dlog4j.configurationFile=perf7MixedNoLoc.xml"
-LOG4J_OPTIONS="-Dlog4j.configurationFile=perf5AsyncApndNoLoc.xml"
-
-#LOG4J_OPTIONS="-Dlog4j.configuration=perf-log4j12.xml"
-#LOG4J_OPTIONS="-Dlog4j.configuration=perf-log4j12-async.xml"
-#LOG4J_OPTIONS="-Dlogback.configurationFile=perf-logback-async.xml"
-#LOG4J_OPTIONS="-Dlogback.configurationFile=perf-logback.xml"
-
-#LOG4J_OPTIONS="${LOG4J_OPTIONS} -DLog4jContextSelector=org.apache.logging.log4j.core.async.AsyncLoggerContextSelector"
-LOG4J_OPTIONS="${LOG4J_OPTIONS} -Dlog4j2.enable.direct.encoders=true"
-LOG4J_OPTIONS="${LOG4J_OPTIONS} -DAsyncLogger.WaitStrategy=busySpin"
-LOG4J_OPTIONS="${LOG4J_OPTIONS} -DAsyncLoggerConfig.WaitStrategy=busySpin"
-#LOG4J_OPTIONS="${LOG4J_OPTIONS} -Dlog4j.format.msg.async=true"
-export LOG4J_OPTIONS
-
-CP=".:HdrHistogram-2.1.8.jar:disruptor-3.3.4.jar:log4j-1.2.17.jar:slf4j-api-1.7.21.jar:slf4j-ext-1.7.21.jar:logback-core-1.1.7.jar:logback-classic-1.1.7.jar:log4j-api-2.6-SNAPSHOT.jar:log4j-core-2.6-SNAPSHOT.jar:log4j-core-2.6-SNAPSHOT-tests.jar"
-
-RUNNER=RunLog4j2
-RESULTDIR=ApndLog4j2
-java -Xms1G -Xmx1G $GC_OPTIONS $COMPILE_OPTIONS $VM_OPTIONS $JFR_OPTIONS $LOG4J_OPTIONS -cp $CP org.apache.logging.log4j.core.async.perftest.ResponseTimeTest 1 10000 $RUNNER
-java -Xms1G -Xmx1G $GC_OPTIONS $COMPILE_OPTIONS $VM_OPTIONS $JFR_OPTIONS $LOG4J_OPTIONS -cp $CP org.apache.logging.log4j.core.async.perftest.ResponseTimeTest 2 5000 $RUNNER
-java -Xms1G -Xmx1G $GC_OPTIONS $COMPILE_OPTIONS $VM_OPTIONS $JFR_OPTIONS $LOG4J_OPTIONS -cp $CP org.apache.logging.log4j.core.async.perftest.ResponseTimeTest 4 2500 $RUNNER
-mkdir async$RESULTDIR-10k
-mv *k? async$RESULTDIR-10k
-mv nohup.out async$RESULTDIR-10k
-mv safepoint$NOW.log async$RESULTDIR-10k
-
-
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/selector/CoreContextSelectors.java b/log4j-core/src/main/java/org/apache/logging/log4j/core/selector/CoreContextSelectors.java
deleted file mode 100644
index 51975ed947..0000000000
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/selector/CoreContextSelectors.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * 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.selector;
-
-import org.apache.logging.log4j.core.async.AsyncLoggerContextSelector;
-import org.apache.logging.log4j.core.async.BasicAsyncLoggerContextSelector;
-
-public class CoreContextSelectors {
-
-    public static final Class<?>[] CLASSES = new Class<?>[] {
-        ClassLoaderContextSelector.class,
-        BasicContextSelector.class,
-        AsyncLoggerContextSelector.class,
-        BasicAsyncLoggerContextSelector.class
-    };
-}
diff --git a/log4j-csv/pom.xml b/log4j-csv/pom.xml
index d9efac8623..9556eb32a2 100644
--- a/log4j-csv/pom.xml
+++ b/log4j-csv/pom.xml
@@ -53,6 +53,11 @@
       <artifactId>log4j-api-test</artifactId>
       <scope>test</scope>
     </dependency>
+    <dependency>
+      <groupId>org.apache.logging.log4j</groupId>
+      <artifactId>log4j-async-logger</artifactId>
+      <scope>test</scope>
+    </dependency>
     <dependency>
       <groupId>org.apache.logging.log4j</groupId>
       <artifactId>log4j-core-test</artifactId>
diff --git a/log4j-gc-test/pom.xml b/log4j-gc-test/pom.xml
index 66a32be640..8d10ca0391 100644
--- a/log4j-gc-test/pom.xml
+++ b/log4j-gc-test/pom.xml
@@ -32,6 +32,11 @@
     <maven.install.skip>true</maven.install.skip>
   </properties>
   <dependencies>
+    <dependency>
+      <groupId>org.apache.logging.log4j</groupId>
+      <artifactId>log4j-async-logger</artifactId>
+      <scope>test</scope>
+    </dependency>
     <dependency>
       <groupId>org.apache.logging.log4j</groupId>
       <artifactId>log4j-core</artifactId>
diff --git a/log4j-jul/pom.xml b/log4j-jul/pom.xml
index bf99f99916..5fb2704a4c 100644
--- a/log4j-jul/pom.xml
+++ b/log4j-jul/pom.xml
@@ -71,6 +71,11 @@
       <artifactId>junit</artifactId>
       <scope>test</scope>
     </dependency>
+    <dependency>
+      <groupId>org.apache.logging.log4j</groupId>
+      <artifactId>log4j-async-logger</artifactId>
+      <scope>test</scope>
+    </dependency>
     <dependency>
       <groupId>org.apache.logging.log4j</groupId>
       <artifactId>log4j-core-test</artifactId>
@@ -122,8 +127,6 @@
             <phase>test</phase>
             <configuration>
               <excludes>
-                <exclude>${log4j.skip.test1}</exclude>
-                <exclude>${log4j.skip.test2}</exclude>
                 <exclude>Log4jBridgeHandlerTest.java</exclude>
               </excludes>
             </configuration>
diff --git a/log4j-perf-test/pom.xml b/log4j-perf-test/pom.xml
index 92e055ea94..3892cddbe1 100644
--- a/log4j-perf-test/pom.xml
+++ b/log4j-perf-test/pom.xml
@@ -49,6 +49,10 @@
       <groupId>org.apache.logging.log4j</groupId>
       <artifactId>log4j-api</artifactId>
     </dependency>
+    <dependency>
+      <groupId>org.apache.logging.log4j</groupId>
+      <artifactId>log4j-async-logger</artifactId>
+    </dependency>
     <dependency>
       <groupId>org.apache.logging.log4j</groupId>
       <artifactId>log4j-core</artifactId>


(logging-log4j2) 02/03: Move async support to `log4j-async-logger`

Posted by pk...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

pkarwasz pushed a commit to branch move-async-end
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git

commit 51d86c13a73e7f81163dd24d4ad2897f5e25a252
Author: Piotr P. Karwasz <pi...@karwasz.org>
AuthorDate: Thu Jan 25 11:50:18 2024 +0100

    Move async support to `log4j-async-logger`
    
    This moves the main code for `AsyncLogger` and `AsyncLoggerConfig` to
    `log4j-async-logger`.
    
    Further tasks such as proper encapsulation into internal packages and
    removal of the optional dependency guards, will be performed in a future
    task.
---
 .../log4j/async/logger}/AbstractAsyncExceptionHandler.java        | 2 +-
 .../java/org/apache/logging/log4j/async/logger}/AsyncLogger.java  | 4 +++-
 .../org/apache/logging/log4j/async/logger}/AsyncLoggerConfig.java | 4 +++-
 .../async/logger}/AsyncLoggerConfigDefaultExceptionHandler.java   | 2 +-
 .../logging/log4j/async/logger}/AsyncLoggerConfigDelegate.java    | 3 ++-
 .../logging/log4j/async/logger}/AsyncLoggerConfigDisruptor.java   | 7 ++++++-
 .../apache/logging/log4j/async/logger}/AsyncLoggerContext.java    | 2 +-
 .../logging/log4j/async/logger}/AsyncLoggerContextSelector.java   | 2 +-
 .../log4j/async/logger}/AsyncLoggerDefaultExceptionHandler.java   | 2 +-
 .../apache/logging/log4j/async/logger}/AsyncLoggerDisruptor.java  | 6 +++++-
 .../logging/log4j/async/logger}/AsyncWaitStrategyFactory.java     | 2 +-
 .../log4j/async/logger}/BasicAsyncLoggerContextSelector.java      | 2 +-
 .../log4j/async/logger}/DefaultAsyncWaitStrategyFactory.java      | 2 +-
 .../logging/log4j/async/logger}/DisruptorConfiguration.java       | 2 +-
 .../org/apache/logging/log4j/async/logger}/DisruptorUtil.java     | 2 +-
 .../apache/logging/log4j/async/logger}/RingBufferLogEvent.java    | 3 ++-
 .../logging/log4j/async/logger}/RingBufferLogEventHandler.java    | 2 +-
 .../logging/log4j/async/logger}/RingBufferLogEventTranslator.java | 2 +-
 .../logging/log4j/async/logger}/TimeoutBlockingWaitStrategy.java  | 2 +-
 .../log4j/{core/async => async/logger}/AsyncLateConfigTest.java   | 2 +-
 .../async => async/logger}/AsyncLoggerClassLoadDeadlockTest.java  | 2 +-
 .../{core/async => async/logger}/AsyncLoggerConfig2Test.java      | 2 +-
 .../{core/async => async/logger}/AsyncLoggerConfig3Test.java      | 2 +-
 .../{core/async => async/logger}/AsyncLoggerConfig4Test.java      | 2 +-
 .../async => async/logger}/AsyncLoggerConfigAutoFlushTest.java    | 2 +-
 .../async => async/logger}/AsyncLoggerConfigErrorOnFormat.java    | 2 +-
 .../log4j/{core/async => async/logger}/AsyncLoggerConfigTest.java | 4 ++--
 .../logger}/AsyncLoggerConfigUseAfterShutdownTest.java            | 2 +-
 .../logger}/AsyncLoggerConfigWithAsyncEnabledTest.java            | 2 +-
 .../logger}/AsyncLoggerContextSelectorInitialStateTest.java       | 2 +-
 .../async => async/logger}/AsyncLoggerContextSelectorTest.java    | 2 +-
 .../{core/async => async/logger}/AsyncLoggerContextTest.java      | 2 +-
 .../logger}/AsyncLoggerCustomSelectorLocationTest.java            | 2 +-
 .../async => async/logger}/AsyncLoggerDefaultLocationTest.java    | 2 +-
 .../logger}/AsyncLoggerEventTranslationExceptionTest.java         | 2 +-
 .../{core/async => async/logger}/AsyncLoggerLocationTest.java     | 2 +-
 .../{core/async => async/logger}/AsyncLoggerNanoTimeTest.java     | 2 +-
 .../log4j/{core/async => async/logger}/AsyncLoggerTest.java       | 2 +-
 .../logger}/AsyncLoggerTestArgumentFreedOnErrorTest.java          | 2 +-
 .../async => async/logger}/AsyncLoggerThreadContextTest.java      | 2 +-
 .../async => async/logger}/AsyncLoggerTimestampMessageTest.java   | 2 +-
 .../async => async/logger}/AsyncLoggerUseAfterShutdownTest.java   | 2 +-
 .../async => async/logger}/AsyncLoggersWithAsyncAppenderTest.java | 2 +-
 .../logger}/AsyncLoggersWithAsyncLoggerConfigTest.java            | 2 +-
 .../async => async/logger}/AsyncQueueFullPolicyFactoryTest.java   | 7 ++++++-
 .../log4j/{core/async => async/logger}/AsyncRootReloadTest.java   | 2 +-
 .../{core/async => async/logger}/AsyncThreadContextTest.java      | 2 +-
 .../logger}/BasicAsyncLoggerContextSelectorTest.java              | 2 +-
 .../async => async/logger}/DisruptorConfigurationInvalidTest.java | 2 +-
 .../{core/async => async/logger}/DisruptorConfigurationTest.java  | 2 +-
 .../async => async/logger}/GarbageFreeAsyncThreadContextTest.java | 2 +-
 .../{core/async => async/logger}/Log4j2Jira1688AsyncTest.java     | 2 +-
 .../{core/async => async/logger}/QueueFullAsyncAbstractTest.java  | 3 ++-
 .../{core/async => async/logger}/QueueFullAsyncLogger2Test.java   | 2 +-
 .../{core/async => async/logger}/QueueFullAsyncLogger3Test.java   | 8 +++++---
 .../async => async/logger}/QueueFullAsyncLoggerConfig2Test.java   | 2 +-
 .../QueueFullAsyncLoggerConfigLoggingFromToString2Test.java       | 2 +-
 .../QueueFullAsyncLoggerConfigLoggingFromToStringTest.java        | 2 +-
 .../async => async/logger}/QueueFullAsyncLoggerConfigTest.java    | 2 +-
 .../logger}/QueueFullAsyncLoggerLoggingFromToStringTest.java      | 2 +-
 .../{core/async => async/logger}/QueueFullAsyncLoggerTest.java    | 2 +-
 .../{core/async => async/logger}/RingBufferLogEventTest.java      | 2 +-
 .../async => async/logger}/AsyncLoggerClassLoadDeadlockTest.xml   | 0
 .../log4j/{core/async => async/logger}/AsyncLoggerConfig2Test.xml | 0
 .../log4j/{core/async => async/logger}/AsyncLoggerConfig3Test.xml | 0
 .../log4j/{core/async => async/logger}/AsyncLoggerConfig4Test.xml | 0
 .../async => async/logger}/AsyncLoggerConfigAutoFlushTest.xml     | 0
 .../async => async/logger}/AsyncLoggerConfigErrorOnFormat.xml     | 0
 .../log4j/{core/async => async/logger}/AsyncLoggerConfigTest.xml  | 0
 .../logger}/AsyncLoggerConfigUseAfterShutdownTest.xml             | 0
 .../logger}/AsyncLoggerConfigWithAsyncEnabledTest.xml             | 0
 .../logger}/AsyncLoggerCustomSelectorLocationTest.xml             | 0
 .../async => async/logger}/AsyncLoggerDefaultLocationTest.xml     | 0
 .../logger}/AsyncLoggerEventTranslationExceptionTest.xml          | 0
 .../{core/async => async/logger}/AsyncLoggerLocationTest.xml      | 0
 .../{core/async => async/logger}/AsyncLoggerNanoTimeTest.xml      | 0
 .../log4j/{core/async => async/logger}/AsyncLoggerTest.xml        | 0
 .../logger}/AsyncLoggerTestArgumentFreedOnErrorTest.xml           | 0
 .../{core/async => async/logger}/AsyncLoggerThreadContextTest.xml | 0
 .../async => async/logger}/AsyncLoggerTimestampMessageTest.xml    | 0
 .../async => async/logger}/AsyncLoggerUseAfterShutdownTest.xml    | 0
 .../async => async/logger}/AsyncLoggersWithAsyncAppenderTest.xml  | 0
 .../logger}/AsyncLoggersWithAsyncLoggerConfigTest.xml             | 0
 .../log4j/{core/async => async/logger}/AsyncRootReloadTest.xml    | 0
 .../async => async/logger}/AsyncThreadContextTest/ALL_ASYNC.xml   | 0
 .../logger}/AsyncThreadContextTest/BOTH_ALL_ASYNC_AND_MIXED.xml   | 0
 .../{core/async => async/logger}/AsyncThreadContextTest/MIXED.xml | 0
 .../async => async/logger}/DisruptorConfigurationInvalidTest.xml  | 0
 .../{core/async => async/logger}/DisruptorConfigurationTest.xml   | 2 +-
 .../{core/async => async/logger}/Log4j2Jira1688AsyncTest.xml      | 0
 .../logger}/QueueFullAsyncLoggerConfigLoggingFromToStringTest.xml | 0
 .../async => async/logger}/QueueFullAsyncLoggerConfigTest.xml     | 0
 log4j-core/pom.xml                                                | 6 ------
 .../logging/log4j/csv/layout/CsvParameterLayoutAllAsyncTest.java  | 2 +-
 .../org/apache/logging/log4j/gctests/GcFreeAsyncLoggingTest.java  | 2 +-
 .../org/apache/logging/log4j/jul/test/AsyncLoggerThreadsTest.java | 2 +-
 .../logging/log4j/perf/jmh/FileAppenderThrowableBenchmark.java    | 4 ++--
 97 files changed, 94 insertions(+), 77 deletions(-)

diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AbstractAsyncExceptionHandler.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AbstractAsyncExceptionHandler.java
similarity index 98%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AbstractAsyncExceptionHandler.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AbstractAsyncExceptionHandler.java
index dd84b23c52..51f1c7bc96 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AbstractAsyncExceptionHandler.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AbstractAsyncExceptionHandler.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import com.lmax.disruptor.ExceptionHandler;
 
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLogger.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLogger.java
similarity index 98%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLogger.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLogger.java
index 5515fcbb34..ef58ea767c 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLogger.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLogger.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.util.List;
 import org.apache.logging.log4j.Level;
@@ -24,6 +24,8 @@ import org.apache.logging.log4j.core.ContextDataInjector;
 import org.apache.logging.log4j.core.Logger;
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.ReusableLogEvent;
+import org.apache.logging.log4j.core.async.AsyncQueueFullMessageUtil;
+import org.apache.logging.log4j.core.async.EventRoute;
 import org.apache.logging.log4j.core.config.Configuration;
 import org.apache.logging.log4j.core.config.LoggerConfig;
 import org.apache.logging.log4j.core.config.Property;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig.java
similarity index 98%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig.java
index a51e1cced4..f6d1fb9895 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.util.List;
 import java.util.concurrent.TimeUnit;
@@ -22,6 +22,8 @@ import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.LogManager;
 import org.apache.logging.log4j.core.Filter;
 import org.apache.logging.log4j.core.LogEvent;
+import org.apache.logging.log4j.core.async.AsyncQueueFullMessageUtil;
+import org.apache.logging.log4j.core.async.EventRoute;
 import org.apache.logging.log4j.core.config.AppenderRef;
 import org.apache.logging.log4j.core.config.Configuration;
 import org.apache.logging.log4j.core.config.LoggerConfig;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigDefaultExceptionHandler.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigDefaultExceptionHandler.java
similarity index 95%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigDefaultExceptionHandler.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigDefaultExceptionHandler.java
index 1bf13f7dd3..3502bb38d0 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigDefaultExceptionHandler.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigDefaultExceptionHandler.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 /**
  * Default disruptor exception handler for errors that occur in the AsyncLogger background thread.
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigDelegate.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigDelegate.java
similarity index 95%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigDelegate.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigDelegate.java
index e2145a93f4..e3997404c4 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigDelegate.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigDelegate.java
@@ -14,10 +14,11 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.core.LogEvent;
+import org.apache.logging.log4j.core.async.EventRoute;
 import org.apache.logging.log4j.core.impl.LogEventFactory;
 
 /**
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigDisruptor.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigDisruptor.java
similarity index 98%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigDisruptor.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigDisruptor.java
index 3f27efc83f..b132e6ae84 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigDisruptor.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigDisruptor.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import com.lmax.disruptor.EventFactory;
 import com.lmax.disruptor.EventHandler;
@@ -34,6 +34,11 @@ import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.core.AbstractLifeCycle;
 import org.apache.logging.log4j.core.LogEvent;
 import org.apache.logging.log4j.core.ReusableLogEvent;
+import org.apache.logging.log4j.core.async.AsyncQueueFullPolicy;
+import org.apache.logging.log4j.core.async.AsyncQueueFullPolicyFactory;
+import org.apache.logging.log4j.core.async.DiscardingAsyncQueueFullPolicy;
+import org.apache.logging.log4j.core.async.EventRoute;
+import org.apache.logging.log4j.core.async.InternalAsyncUtil;
 import org.apache.logging.log4j.core.impl.Log4jLogEvent;
 import org.apache.logging.log4j.core.impl.Log4jPropertyKey;
 import org.apache.logging.log4j.core.impl.LogEventFactory;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerContext.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerContext.java
similarity index 99%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerContext.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerContext.java
index 0484eb6e91..8e1ce4290e 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerContext.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerContext.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.net.URI;
 import java.util.concurrent.TimeUnit;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerContextSelector.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextSelector.java
similarity index 97%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerContextSelector.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextSelector.java
index fe43e06f9d..31e5b9c403 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerContextSelector.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextSelector.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.net.URI;
 import org.apache.logging.log4j.core.LoggerContext;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerDefaultExceptionHandler.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerDefaultExceptionHandler.java
similarity index 95%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerDefaultExceptionHandler.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerDefaultExceptionHandler.java
index 058d306c22..f8e866183f 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerDefaultExceptionHandler.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerDefaultExceptionHandler.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 /**
  * Default disruptor exception handler for errors that occur in the AsyncLogger background thread.
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerDisruptor.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerDisruptor.java
similarity index 97%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerDisruptor.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerDisruptor.java
index b3281e4216..b2280e62b7 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncLoggerDisruptor.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncLoggerDisruptor.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import com.lmax.disruptor.ExceptionHandler;
 import com.lmax.disruptor.RingBuffer;
@@ -30,6 +30,10 @@ import java.util.concurrent.locks.ReentrantLock;
 import java.util.function.Supplier;
 import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.core.AbstractLifeCycle;
+import org.apache.logging.log4j.core.async.AsyncQueueFullPolicy;
+import org.apache.logging.log4j.core.async.AsyncQueueFullPolicyFactory;
+import org.apache.logging.log4j.core.async.DiscardingAsyncQueueFullPolicy;
+import org.apache.logging.log4j.core.async.EventRoute;
 import org.apache.logging.log4j.core.impl.Log4jPropertyKey;
 import org.apache.logging.log4j.core.util.Log4jThread;
 import org.apache.logging.log4j.core.util.Log4jThreadFactory;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncWaitStrategyFactory.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncWaitStrategyFactory.java
similarity index 96%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncWaitStrategyFactory.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncWaitStrategyFactory.java
index 7b5f1c0b1a..491b37eebf 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/AsyncWaitStrategyFactory.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/AsyncWaitStrategyFactory.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import com.lmax.disruptor.WaitStrategy;
 
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/BasicAsyncLoggerContextSelector.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/BasicAsyncLoggerContextSelector.java
similarity index 97%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/BasicAsyncLoggerContextSelector.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/BasicAsyncLoggerContextSelector.java
index 7292941cd5..e8d458f466 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/BasicAsyncLoggerContextSelector.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/BasicAsyncLoggerContextSelector.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.net.URI;
 import org.apache.logging.log4j.core.LoggerContext;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/DefaultAsyncWaitStrategyFactory.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/DefaultAsyncWaitStrategyFactory.java
similarity index 98%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/DefaultAsyncWaitStrategyFactory.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/DefaultAsyncWaitStrategyFactory.java
index 1014846a66..d0084a17ee 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/DefaultAsyncWaitStrategyFactory.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/DefaultAsyncWaitStrategyFactory.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import com.lmax.disruptor.BlockingWaitStrategy;
 import com.lmax.disruptor.BusySpinWaitStrategy;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/DisruptorConfiguration.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/DisruptorConfiguration.java
similarity index 99%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/DisruptorConfiguration.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/DisruptorConfiguration.java
index 035aa4c445..01eccd43e6 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/DisruptorConfiguration.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/DisruptorConfiguration.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.util.Objects;
 import java.util.concurrent.TimeUnit;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/DisruptorUtil.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/DisruptorUtil.java
similarity index 99%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/DisruptorUtil.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/DisruptorUtil.java
index 7d9444e0ef..9716276ed6 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/DisruptorUtil.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/DisruptorUtil.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.apache.logging.log4j.core.impl.Log4jPropertyKey.ASYNC_CONFIG_EXCEPTION_HANDLER_CLASS_NAME;
 import static org.apache.logging.log4j.core.impl.Log4jPropertyKey.ASYNC_LOGGER_EXCEPTION_HANDLER_CLASS_NAME;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/RingBufferLogEvent.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/RingBufferLogEvent.java
similarity index 99%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/RingBufferLogEvent.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/RingBufferLogEvent.java
index 5d97613bc2..4c4b6da4c2 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/RingBufferLogEvent.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/RingBufferLogEvent.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import com.lmax.disruptor.EventFactory;
 import java.util.Arrays;
@@ -23,6 +23,7 @@ import org.apache.logging.log4j.Marker;
 import org.apache.logging.log4j.ThreadContext.ContextStack;
 import org.apache.logging.log4j.core.LogEvent;
 import org.apache.logging.log4j.core.ReusableLogEvent;
+import org.apache.logging.log4j.core.async.InternalAsyncUtil;
 import org.apache.logging.log4j.core.impl.ContextDataFactory;
 import org.apache.logging.log4j.core.impl.Log4jLogEvent;
 import org.apache.logging.log4j.core.impl.MementoMessage;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/RingBufferLogEventHandler.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/RingBufferLogEventHandler.java
similarity index 98%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/RingBufferLogEventHandler.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/RingBufferLogEventHandler.java
index f141846591..f19be65493 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/RingBufferLogEventHandler.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/RingBufferLogEventHandler.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import com.lmax.disruptor.EventHandler;
 import com.lmax.disruptor.Sequence;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/RingBufferLogEventTranslator.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/RingBufferLogEventTranslator.java
similarity index 99%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/RingBufferLogEventTranslator.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/RingBufferLogEventTranslator.java
index 15b2b652bc..96948902be 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/RingBufferLogEventTranslator.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/RingBufferLogEventTranslator.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import com.lmax.disruptor.EventTranslator;
 import org.apache.logging.log4j.Level;
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/TimeoutBlockingWaitStrategy.java b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/TimeoutBlockingWaitStrategy.java
similarity index 98%
rename from log4j-core/src/main/java/org/apache/logging/log4j/core/async/TimeoutBlockingWaitStrategy.java
rename to log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/TimeoutBlockingWaitStrategy.java
index 77db1635c9..657da6fec4 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/TimeoutBlockingWaitStrategy.java
+++ b/log4j-async-logger/src/main/java/org/apache/logging/log4j/async/logger/TimeoutBlockingWaitStrategy.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import com.lmax.disruptor.AlertException;
 import com.lmax.disruptor.BatchEventProcessor;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLateConfigTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLateConfigTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLateConfigTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLateConfigTest.java
index 3c4b73fff7..79cf78d7ec 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLateConfigTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLateConfigTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.nio.file.Path;
 import java.util.stream.Stream;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerClassLoadDeadlockTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerClassLoadDeadlockTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerClassLoadDeadlockTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerClassLoadDeadlockTest.java
index 4836bbbfbd..b4ff970790 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerClassLoadDeadlockTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerClassLoadDeadlockTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertNotNull;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig2Test.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig2Test.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig2Test.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig2Test.java
index a36c756959..ff45f7b904 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig2Test.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig2Test.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertNotNull;
 import static org.junit.jupiter.api.Assertions.assertTrue;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig3Test.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig3Test.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig3Test.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig3Test.java
index f46c75b61f..8508971b99 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig3Test.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig3Test.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.nio.file.Path;
 import java.util.HashMap;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig4Test.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig4Test.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig4Test.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig4Test.java
index f95ddedbf0..5f203739be 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfig4Test.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfig4Test.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.hamcrest.MatcherAssert.assertThat;
 import static org.hamcrest.Matchers.equalTo;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigAutoFlushTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigAutoFlushTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigAutoFlushTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigAutoFlushTest.java
index 12b745207a..d59738208a 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigAutoFlushTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigAutoFlushTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertTrue;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigErrorOnFormat.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigErrorOnFormat.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigErrorOnFormat.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigErrorOnFormat.java
index 1b144842a0..7ed1bfe672 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigErrorOnFormat.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigErrorOnFormat.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.hamcrest.MatcherAssert.assertThat;
 import static org.hamcrest.Matchers.containsString;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigTest.java
index 3dba066194..6a08fdaf86 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.assertThat;
 import static org.junit.jupiter.api.Assertions.assertFalse;
@@ -30,10 +30,10 @@ import java.nio.file.Files;
 import java.nio.file.Path;
 import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.Logger;
+import org.apache.logging.log4j.async.logger.AsyncLoggerConfig.RootLogger;
 import org.apache.logging.log4j.core.Appender;
 import org.apache.logging.log4j.core.Filter;
 import org.apache.logging.log4j.core.LoggerContext;
-import org.apache.logging.log4j.core.async.AsyncLoggerConfig.RootLogger;
 import org.apache.logging.log4j.core.config.Configuration;
 import org.apache.logging.log4j.core.config.LoggerConfig;
 import org.apache.logging.log4j.core.config.NullConfiguration;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigUseAfterShutdownTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigUseAfterShutdownTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigUseAfterShutdownTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigUseAfterShutdownTest.java
index 29f20f63e5..79165e5c9b 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigUseAfterShutdownTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigUseAfterShutdownTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.nio.file.Path;
 import org.apache.logging.log4j.Level;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigWithAsyncEnabledTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigWithAsyncEnabledTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigWithAsyncEnabledTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigWithAsyncEnabledTest.java
index 3cbcdaf5f3..657cc65bee 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerConfigWithAsyncEnabledTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerConfigWithAsyncEnabledTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.hamcrest.MatcherAssert.assertThat;
 import static org.hamcrest.Matchers.equalTo;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerContextSelectorInitialStateTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextSelectorInitialStateTest.java
similarity index 96%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerContextSelectorInitialStateTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextSelectorInitialStateTest.java
index 8e3af12235..31997d697b 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerContextSelectorInitialStateTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextSelectorInitialStateTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertTrue;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerContextSelectorTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextSelectorTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerContextSelectorTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextSelectorTest.java
index 7c6081e7c0..b3141cb42b 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerContextSelectorTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextSelectorTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertEquals;
 import static org.junit.jupiter.api.Assertions.assertTrue;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerContextTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextTest.java
similarity index 96%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerContextTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextTest.java
index 54403bbd9e..a89108b3c0 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerContextTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerContextTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.Assert.assertTrue;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerCustomSelectorLocationTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerCustomSelectorLocationTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerCustomSelectorLocationTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerCustomSelectorLocationTest.java
index f75fe35977..f84dd735ab 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerCustomSelectorLocationTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerCustomSelectorLocationTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.hamcrest.CoreMatchers.containsString;
 import static org.hamcrest.CoreMatchers.not;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerDefaultLocationTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerDefaultLocationTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerDefaultLocationTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerDefaultLocationTest.java
index 3d5ecfd09e..6c2e5b3bbb 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerDefaultLocationTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerDefaultLocationTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertEquals;
 import static org.junit.jupiter.api.Assertions.assertFalse;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerEventTranslationExceptionTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerEventTranslationExceptionTest.java
similarity index 99%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerEventTranslationExceptionTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerEventTranslationExceptionTest.java
index bc7e9ca545..418b8bedf7 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerEventTranslationExceptionTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerEventTranslationExceptionTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertFalse;
 import static org.junit.jupiter.api.Assertions.assertThrows;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerLocationTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerLocationTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerLocationTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerLocationTest.java
index fb81b286b0..81899d4b0f 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerLocationTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerLocationTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertNotNull;
 import static org.junit.jupiter.api.Assertions.assertTrue;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerNanoTimeTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerNanoTimeTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerNanoTimeTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerNanoTimeTest.java
index 02137cd983..2ab6d4e1c8 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerNanoTimeTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerNanoTimeTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.assertThat;
 import static org.junit.jupiter.api.Assertions.assertEquals;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerTest.java
index 319e9d0e87..a5e48de0d9 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertFalse;
 import static org.junit.jupiter.api.Assertions.assertNotNull;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerTestArgumentFreedOnErrorTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerTestArgumentFreedOnErrorTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerTestArgumentFreedOnErrorTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerTestArgumentFreedOnErrorTest.java
index 17774c3765..f66e1d76d7 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerTestArgumentFreedOnErrorTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerTestArgumentFreedOnErrorTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertTrue;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerThreadContextTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerThreadContextTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerThreadContextTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerThreadContextTest.java
index 2cd7adf0ce..8741a347b1 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerThreadContextTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerThreadContextTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertNotNull;
 import static org.junit.jupiter.api.Assertions.assertTrue;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerTimestampMessageTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerTimestampMessageTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerTimestampMessageTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerTimestampMessageTest.java
index 256ee7130e..89912ae092 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerTimestampMessageTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerTimestampMessageTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.assertThat;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerUseAfterShutdownTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerUseAfterShutdownTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerUseAfterShutdownTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerUseAfterShutdownTest.java
index 520300e05c..912d2409c3 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggerUseAfterShutdownTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerUseAfterShutdownTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.Logger;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggersWithAsyncAppenderTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggersWithAsyncAppenderTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggersWithAsyncAppenderTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggersWithAsyncAppenderTest.java
index cb0c87d338..04ca49d4db 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggersWithAsyncAppenderTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggersWithAsyncAppenderTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.assertThat;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggersWithAsyncLoggerConfigTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggersWithAsyncLoggerConfigTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggersWithAsyncLoggerConfigTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggersWithAsyncLoggerConfigTest.java
index c7690d858a..0564601b31 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncLoggersWithAsyncLoggerConfigTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggersWithAsyncLoggerConfigTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertEquals;
 import static org.junit.jupiter.api.Assertions.assertNotNull;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncQueueFullPolicyFactoryTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncQueueFullPolicyFactoryTest.java
similarity index 93%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncQueueFullPolicyFactoryTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncQueueFullPolicyFactoryTest.java
index 532cb9fe6e..7f9f9c1c30 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncQueueFullPolicyFactoryTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncQueueFullPolicyFactoryTest.java
@@ -14,12 +14,17 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.apache.logging.log4j.util.Strings.toRootLowerCase;
 import static org.junit.jupiter.api.Assertions.assertEquals;
 
 import org.apache.logging.log4j.Level;
+import org.apache.logging.log4j.core.async.AsyncQueueFullPolicy;
+import org.apache.logging.log4j.core.async.AsyncQueueFullPolicyFactory;
+import org.apache.logging.log4j.core.async.DefaultAsyncQueueFullPolicy;
+import org.apache.logging.log4j.core.async.DiscardingAsyncQueueFullPolicy;
+import org.apache.logging.log4j.core.async.EventRoute;
 import org.apache.logging.log4j.core.impl.Log4jPropertyKey;
 import org.apache.logging.log4j.util.PropertiesUtil;
 import org.junit.jupiter.api.AfterEach;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncRootReloadTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncRootReloadTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncRootReloadTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncRootReloadTest.java
index 45807b6072..bb7e1cecf0 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncRootReloadTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncRootReloadTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.io.File;
 import java.net.URISyntaxException;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncThreadContextTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncThreadContextTest.java
similarity index 99%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncThreadContextTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncThreadContextTest.java
index 819eaa0f90..c8d57007bc 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/AsyncThreadContextTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncThreadContextTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.assertThat;
 import static org.awaitility.Awaitility.waitAtMost;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/BasicAsyncLoggerContextSelectorTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/BasicAsyncLoggerContextSelectorTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/BasicAsyncLoggerContextSelectorTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/BasicAsyncLoggerContextSelectorTest.java
index dc38a33864..a0256ee8ef 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/BasicAsyncLoggerContextSelectorTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/BasicAsyncLoggerContextSelectorTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.assertThat;
 import static org.junit.jupiter.api.Assertions.assertEquals;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/DisruptorConfigurationInvalidTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/DisruptorConfigurationInvalidTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/DisruptorConfigurationInvalidTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/DisruptorConfigurationInvalidTest.java
index aec3757813..c7742987d5 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/DisruptorConfigurationInvalidTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/DisruptorConfigurationInvalidTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.assertThat;
 import static org.junit.jupiter.api.Assertions.assertEquals;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/DisruptorConfigurationTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/DisruptorConfigurationTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/DisruptorConfigurationTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/DisruptorConfigurationTest.java
index 16dedf4037..190dbee16b 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/DisruptorConfigurationTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/DisruptorConfigurationTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.assertThat;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/GarbageFreeAsyncThreadContextTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/GarbageFreeAsyncThreadContextTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/GarbageFreeAsyncThreadContextTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/GarbageFreeAsyncThreadContextTest.java
index 8dab35c708..5bb8bf789c 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/GarbageFreeAsyncThreadContextTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/GarbageFreeAsyncThreadContextTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import java.nio.file.Path;
 import org.apache.logging.log4j.test.TestProperties;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/Log4j2Jira1688AsyncTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/Log4j2Jira1688AsyncTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/Log4j2Jira1688AsyncTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/Log4j2Jira1688AsyncTest.java
index 5b5e1ef57b..220cad08a7 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/Log4j2Jira1688AsyncTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/Log4j2Jira1688AsyncTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.junit.jupiter.api.Assertions.assertArrayEquals;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncAbstractTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncAbstractTest.java
similarity index 98%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncAbstractTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncAbstractTest.java
index 03ea0a04c7..93ef280d44 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncAbstractTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncAbstractTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.assertThat;
 
@@ -26,6 +26,7 @@ import java.util.stream.Collectors;
 import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.Logger;
 import org.apache.logging.log4j.core.LoggerContext;
+import org.apache.logging.log4j.core.async.QueueFullAbstractTest;
 import org.apache.logging.log4j.core.config.Configuration;
 import org.apache.logging.log4j.core.config.LoggerConfig;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger2Test.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLogger2Test.java
similarity index 96%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger2Test.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLogger2Test.java
index 962ac5fb74..55e0b74025 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger2Test.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLogger2Test.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.test.junit.SetTestProperty;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger3Test.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLogger3Test.java
similarity index 91%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger3Test.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLogger3Test.java
index 8debb4b435..575f15c422 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLogger3Test.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLogger3Test.java
@@ -14,21 +14,23 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static java.util.concurrent.TimeUnit.SECONDS;
-import static org.assertj.core.api.Assertions.assertThat;
 import static org.junit.Assert.assertTrue;
 
 import java.util.concurrent.CountDownLatch;
 import org.apache.logging.log4j.Logger;
 import org.apache.logging.log4j.core.GarbageCollectionHelper;
 import org.apache.logging.log4j.core.LoggerContext;
+import org.apache.logging.log4j.core.async.AsyncQueueFullPolicyFactory;
+import org.apache.logging.log4j.core.async.DiscardingAsyncQueueFullPolicy;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
 import org.apache.logging.log4j.core.test.junit.LoggerContextSource;
 import org.apache.logging.log4j.core.test.junit.Named;
 import org.apache.logging.log4j.message.Message;
 import org.apache.logging.log4j.test.junit.SetTestProperty;
+import org.assertj.core.api.Assertions;
 import org.junit.jupiter.api.Test;
 import org.junit.jupiter.api.Timeout;
 
@@ -47,7 +49,7 @@ public class QueueFullAsyncLogger3Test extends QueueFullAsyncAbstractTest {
     protected void checkConfig(final LoggerContext ctx) {
         assertAsyncLogger(ctx, 128);
         assertFormatMessagesInBackground();
-        assertThat(AsyncQueueFullPolicyFactory.create()).isInstanceOf(DiscardingAsyncQueueFullPolicy.class);
+        Assertions.assertThat(AsyncQueueFullPolicyFactory.create()).isInstanceOf(DiscardingAsyncQueueFullPolicy.class);
     }
 
     @Test
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfig2Test.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfig2Test.java
similarity index 96%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfig2Test.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfig2Test.java
index ef5f5f0455..48e3479036 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfig2Test.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfig2Test.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.test.junit.SetTestProperty;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToString2Test.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigLoggingFromToString2Test.java
similarity index 96%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToString2Test.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigLoggingFromToString2Test.java
index 7820f1c1e5..9d886ce595 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToString2Test.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigLoggingFromToString2Test.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.test.junit.SetTestProperty;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToStringTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigLoggingFromToStringTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToStringTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigLoggingFromToStringTest.java
index e9d78fa638..900e1711e4 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToStringTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigLoggingFromToStringTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.assertThat;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigTest.java
index feb04be22e..0eb7e853b5 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerLoggingFromToStringTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerLoggingFromToStringTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerLoggingFromToStringTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerLoggingFromToStringTest.java
index e58bd1a7ab..5ac3c0aa21 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerLoggingFromToStringTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerLoggingFromToStringTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerTest.java
similarity index 97%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerTest.java
index 0c2e41a316..e6043dc880 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/RingBufferLogEventTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/RingBufferLogEventTest.java
similarity index 99%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/RingBufferLogEventTest.java
rename to log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/RingBufferLogEventTest.java
index f2995c2461..edefd4975c 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/core/async/RingBufferLogEventTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/RingBufferLogEventTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.async.logger;
 
 import static org.assertj.core.api.Assertions.as;
 import static org.assertj.core.api.Assertions.assertThat;
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerClassLoadDeadlockTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerClassLoadDeadlockTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerClassLoadDeadlockTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerClassLoadDeadlockTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfig2Test.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfig2Test.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfig2Test.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfig2Test.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfig3Test.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfig3Test.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfig3Test.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfig3Test.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfig4Test.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfig4Test.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfig4Test.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfig4Test.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfigAutoFlushTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfigAutoFlushTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfigAutoFlushTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfigAutoFlushTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfigErrorOnFormat.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfigErrorOnFormat.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfigErrorOnFormat.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfigErrorOnFormat.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfigTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfigTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfigTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfigTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfigUseAfterShutdownTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfigUseAfterShutdownTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfigUseAfterShutdownTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfigUseAfterShutdownTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfigWithAsyncEnabledTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfigWithAsyncEnabledTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerConfigWithAsyncEnabledTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerConfigWithAsyncEnabledTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerCustomSelectorLocationTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerCustomSelectorLocationTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerCustomSelectorLocationTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerCustomSelectorLocationTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerDefaultLocationTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerDefaultLocationTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerDefaultLocationTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerDefaultLocationTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerEventTranslationExceptionTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerEventTranslationExceptionTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerEventTranslationExceptionTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerEventTranslationExceptionTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerLocationTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerLocationTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerLocationTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerLocationTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerNanoTimeTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerNanoTimeTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerNanoTimeTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerNanoTimeTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerTestArgumentFreedOnErrorTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerTestArgumentFreedOnErrorTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerTestArgumentFreedOnErrorTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerTestArgumentFreedOnErrorTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerThreadContextTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerThreadContextTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerThreadContextTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerThreadContextTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerTimestampMessageTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerTimestampMessageTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerTimestampMessageTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerTimestampMessageTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerUseAfterShutdownTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerUseAfterShutdownTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggerUseAfterShutdownTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggerUseAfterShutdownTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggersWithAsyncAppenderTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggersWithAsyncAppenderTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggersWithAsyncAppenderTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggersWithAsyncAppenderTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggersWithAsyncLoggerConfigTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggersWithAsyncLoggerConfigTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncLoggersWithAsyncLoggerConfigTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncLoggersWithAsyncLoggerConfigTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncRootReloadTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncRootReloadTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncRootReloadTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncRootReloadTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncThreadContextTest/ALL_ASYNC.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncThreadContextTest/ALL_ASYNC.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncThreadContextTest/ALL_ASYNC.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncThreadContextTest/ALL_ASYNC.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncThreadContextTest/BOTH_ALL_ASYNC_AND_MIXED.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncThreadContextTest/BOTH_ALL_ASYNC_AND_MIXED.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncThreadContextTest/BOTH_ALL_ASYNC_AND_MIXED.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncThreadContextTest/BOTH_ALL_ASYNC_AND_MIXED.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncThreadContextTest/MIXED.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncThreadContextTest/MIXED.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/AsyncThreadContextTest/MIXED.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/AsyncThreadContextTest/MIXED.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/DisruptorConfigurationInvalidTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/DisruptorConfigurationInvalidTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/DisruptorConfigurationInvalidTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/DisruptorConfigurationInvalidTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/DisruptorConfigurationTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/DisruptorConfigurationTest.xml
similarity index 91%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/DisruptorConfigurationTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/DisruptorConfigurationTest.xml
index f52b0d58c3..2265a4963e 100644
--- a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/DisruptorConfigurationTest.xml
+++ b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/DisruptorConfigurationTest.xml
@@ -27,5 +27,5 @@
   </Loggers>
 
   <AsyncWaitStrategyFactory
-          class="org.apache.logging.log4j.core.async.DisruptorConfigurationTest$YieldingWaitStrategyFactory" />
+          class="org.apache.logging.log4j.async.logger.DisruptorConfigurationTest$YieldingWaitStrategyFactory" />
 </Configuration>
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/Log4j2Jira1688AsyncTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/Log4j2Jira1688AsyncTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/Log4j2Jira1688AsyncTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/Log4j2Jira1688AsyncTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToStringTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigLoggingFromToStringTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigLoggingFromToStringTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigLoggingFromToStringTest.xml
diff --git a/log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigTest.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigTest.xml
similarity index 100%
rename from log4j-async-logger/src/test/resources/org/apache/logging/log4j/core/async/QueueFullAsyncLoggerConfigTest.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerConfigTest.xml
diff --git a/log4j-core/pom.xml b/log4j-core/pom.xml
index cdbbeca83c..e676d00b87 100644
--- a/log4j-core/pom.xml
+++ b/log4j-core/pom.xml
@@ -92,12 +92,6 @@
       <artifactId>disruptor</artifactId>
       <optional>true</optional>
     </dependency>
-    <!-- Required for AsyncLoggers -->
-    <dependency>
-      <groupId>com.lmax</groupId>
-      <artifactId>disruptor</artifactId>
-      <optional>true</optional>
-    </dependency>
     <!-- Required for console color support in Windows -->
     <dependency>
       <groupId>org.fusesource.jansi</groupId>
diff --git a/log4j-csv/src/test/java/org/apache/logging/log4j/csv/layout/CsvParameterLayoutAllAsyncTest.java b/log4j-csv/src/test/java/org/apache/logging/log4j/csv/layout/CsvParameterLayoutAllAsyncTest.java
index 64cff2cfe4..e57d2c99c8 100644
--- a/log4j-csv/src/test/java/org/apache/logging/log4j/csv/layout/CsvParameterLayoutAllAsyncTest.java
+++ b/log4j-csv/src/test/java/org/apache/logging/log4j/csv/layout/CsvParameterLayoutAllAsyncTest.java
@@ -18,8 +18,8 @@ package org.apache.logging.log4j.csv.layout;
 
 import org.apache.commons.csv.CSVFormat;
 import org.apache.logging.log4j.LogManager;
+import org.apache.logging.log4j.async.logger.AsyncLoggerContextSelector;
 import org.apache.logging.log4j.core.Logger;
-import org.apache.logging.log4j.core.async.AsyncLoggerContextSelector;
 import org.apache.logging.log4j.core.impl.Log4jPropertyKey;
 import org.apache.logging.log4j.core.test.categories.Layouts;
 import org.apache.logging.log4j.util.Strings;
diff --git a/log4j-gc-test/src/test/java/org/apache/logging/log4j/gctests/GcFreeAsyncLoggingTest.java b/log4j-gc-test/src/test/java/org/apache/logging/log4j/gctests/GcFreeAsyncLoggingTest.java
index 7b49932dcc..ac19e9e344 100644
--- a/log4j-gc-test/src/test/java/org/apache/logging/log4j/gctests/GcFreeAsyncLoggingTest.java
+++ b/log4j-gc-test/src/test/java/org/apache/logging/log4j/gctests/GcFreeAsyncLoggingTest.java
@@ -16,7 +16,7 @@
  */
 package org.apache.logging.log4j.gctests;
 
-import org.apache.logging.log4j.core.async.AsyncLoggerContextSelector;
+import org.apache.logging.log4j.async.logger.AsyncLoggerContextSelector;
 import org.apache.logging.log4j.core.impl.Log4jPropertyKey;
 import org.apache.logging.log4j.spi.LoggingSystemProperty;
 import org.junit.jupiter.api.Tag;
diff --git a/log4j-jul/src/test/java/org/apache/logging/log4j/jul/test/AsyncLoggerThreadsTest.java b/log4j-jul/src/test/java/org/apache/logging/log4j/jul/test/AsyncLoggerThreadsTest.java
index 3abe1f9743..aa36a07de4 100644
--- a/log4j-jul/src/test/java/org/apache/logging/log4j/jul/test/AsyncLoggerThreadsTest.java
+++ b/log4j-jul/src/test/java/org/apache/logging/log4j/jul/test/AsyncLoggerThreadsTest.java
@@ -21,7 +21,7 @@ import static org.junit.Assert.assertEquals;
 import java.util.List;
 import java.util.stream.Collectors;
 import org.apache.logging.log4j.LogManager;
-import org.apache.logging.log4j.core.async.AsyncLoggerContextSelector;
+import org.apache.logging.log4j.async.logger.AsyncLoggerContextSelector;
 import org.apache.logging.log4j.core.impl.Log4jPropertyKey;
 import org.apache.logging.log4j.core.test.categories.AsyncLoggers;
 import org.junit.AfterClass;
diff --git a/log4j-perf-test/src/main/java/org/apache/logging/log4j/perf/jmh/FileAppenderThrowableBenchmark.java b/log4j-perf-test/src/main/java/org/apache/logging/log4j/perf/jmh/FileAppenderThrowableBenchmark.java
index 2dd0bcfa65..54f7c3d6db 100644
--- a/log4j-perf-test/src/main/java/org/apache/logging/log4j/perf/jmh/FileAppenderThrowableBenchmark.java
+++ b/log4j-perf-test/src/main/java/org/apache/logging/log4j/perf/jmh/FileAppenderThrowableBenchmark.java
@@ -24,8 +24,8 @@ import java.util.logging.FileHandler;
 import java.util.logging.Level;
 import org.apache.logging.log4j.LogManager;
 import org.apache.logging.log4j.Logger;
-import org.apache.logging.log4j.core.async.AsyncLoggerContext;
-import org.apache.logging.log4j.core.async.AsyncLoggerContextSelector;
+import org.apache.logging.log4j.async.logger.AsyncLoggerContext;
+import org.apache.logging.log4j.async.logger.AsyncLoggerContextSelector;
 import org.apache.logging.log4j.core.impl.Log4jPropertyKey;
 import org.apache.logging.log4j.spi.LoggingSystemProperty;
 import org.openjdk.jmh.annotations.Benchmark;


(logging-log4j2) 03/03: Fix failing tests

Posted by pk...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

pkarwasz pushed a commit to branch move-async-end
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git

commit 2fb51110e067b9f0099e382fffb4762b3e3bb24c
Author: Piotr P. Karwasz <pi...@karwasz.org>
AuthorDate: Thu Jan 25 16:24:00 2024 +0100

    Fix failing tests
---
 log4j-async-logger/pom.xml                         | 20 ++++-
 .../AsyncLoggerEventTranslationExceptionTest.java  |  2 +-
 .../async/logger/DefaultIncludeLocationTest.java   | 91 ++++++++++++++++++++++
 .../async/logger/NestedAsyncLoggerConfigTest.java  | 21 +++++
 .../async/logger/QueueFullAsyncAbstractTest.java   |  2 +-
 .../async/logger/QueueFullAsyncLogger3Test.java    |  5 +-
 ...ueueFullAsyncLoggerLoggingFromToStringTest.java |  5 +-
 .../async/logger/QueueFullAsyncLoggerTest.java     |  5 +-
 .../NestedAsyncLoggerConfigTest}/default-level.xml |  0
 .../NestedAsyncLoggerConfigTest}/inherit-level.xml |  0
 .../JavaPropsConfigurationFactoryTest.java         |  2 +-
 .../config/yaml/YamlConfigurationFactoryTest.java  |  2 +-
 .../{ => test}/async/QueueFullAbstractTest.java    |  7 +-
 .../config/AbstractConfigurationFactoryTest.java   |  3 +-
 .../config/AbstractNestedLoggerConfigTest.java}    | 35 +++------
 .../{ => test}/async/QueueFullAbstractTest.xml     |  0
 .../appender/RandomAccessFileAppenderTest.java     | 79 +++++--------------
 .../async}/AsyncQueueFullPolicyFactoryTest.java    |  7 +-
 .../core/async/QueueFullAsyncAppenderTest.java     |  1 +
 .../core/config/ConfigurationFactoryTest.java      |  1 +
 .../log4j/core/config/NestedLoggerConfigTest.java  | 58 +-------------
 .../RandomAccessFileAppenderLocationTest.xml       | 35 ---------
 .../resources/RandomAccessFileAppenderTest.xml     | 35 ---------
 .../RollingRandomAccessFileAppenderTest.xml        | 37 ---------
 .../appender/RandomAccessFileAppenderTest.xml}     | 28 ++++---
 .../NestedLoggerConfigTest}/default-level.xml      |  0
 .../NestedLoggerConfigTest}/inherit-level.xml      |  0
 27 files changed, 197 insertions(+), 284 deletions(-)

diff --git a/log4j-async-logger/pom.xml b/log4j-async-logger/pom.xml
index 5d37d3d80f..aba22bd83d 100644
--- a/log4j-async-logger/pom.xml
+++ b/log4j-async-logger/pom.xml
@@ -25,7 +25,7 @@
   </parent>
 
   <artifactId>log4j-async-logger</artifactId>
-  <name>Log4j Async Logger</name>
+  <name>Apache Log4j Async Logger</name>
   <description>Alternative implementation of logger that uses LMAX Disruptor.</description>
 
   <dependencies>
@@ -65,4 +65,22 @@
     </dependency>
 
   </dependencies>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <configuration>
+          <annotationProcessorPaths combine.children="append">
+            <path>
+              <groupId>org.apache.logging.log4j</groupId>
+              <artifactId>log4j-plugin-processor</artifactId>
+              <version>${project.version}</version>
+            </path>
+          </annotationProcessorPaths>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
 </project>
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerEventTranslationExceptionTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerEventTranslationExceptionTest.java
index 418b8bedf7..a5a32b29f1 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerEventTranslationExceptionTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncLoggerEventTranslationExceptionTest.java
@@ -46,7 +46,7 @@ import org.junitpioneer.jupiter.SetSystemProperty;
 @ContextSelectorType(AsyncLoggerContextSelector.class)
 @SetSystemProperty(
         key = Log4jPropertyKey.Constant.ASYNC_LOGGER_EXCEPTION_HANDLER_CLASS_NAME,
-        value = "org.apache.logging.log4j.core.async.AsyncLoggerEventTranslationExceptionTest$TestExceptionHandler")
+        value = "org.apache.logging.log4j.async.logger.AsyncLoggerEventTranslationExceptionTest$TestExceptionHandler")
 class AsyncLoggerEventTranslationExceptionTest {
 
     @Test
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/DefaultIncludeLocationTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/DefaultIncludeLocationTest.java
new file mode 100644
index 0000000000..9f92ff02c6
--- /dev/null
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/DefaultIncludeLocationTest.java
@@ -0,0 +1,91 @@
+/*
+ * 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.async.logger;
+
+import java.util.stream.Stream;
+import org.apache.logging.log4j.core.LoggerContext;
+import org.apache.logging.log4j.core.config.Configuration;
+import org.apache.logging.log4j.core.config.LoggerConfig;
+import org.apache.logging.log4j.core.config.NullConfiguration;
+import org.apache.logging.log4j.util.PropertiesUtil;
+import org.assertj.core.api.Assertions;
+import org.junit.jupiter.params.ParameterizedTest;
+import org.junit.jupiter.params.provider.Arguments;
+import org.junit.jupiter.params.provider.MethodSource;
+
+class DefaultIncludeLocationTest {
+
+    private static final String LOGGER_NAME = DefaultIncludeLocationTest.class.getName();
+
+    private static Stream<Arguments> loggerConfigs(final Configuration config) {
+        return Stream.of(
+                Arguments.of(
+                        LoggerConfig.newBuilder()
+                                .setConfig(config)
+                                .setLoggerName(LOGGER_NAME)
+                                .build(),
+                        true),
+                Arguments.of(
+                        LoggerConfig.RootLogger.newRootBuilder()
+                                .setConfig(config)
+                                .build(),
+                        true),
+                Arguments.of(
+                        AsyncLoggerConfig.newAsyncBuilder()
+                                .setConfig(config)
+                                .setLoggerName(LOGGER_NAME)
+                                .build(),
+                        false),
+                Arguments.of(
+                        AsyncLoggerConfig.RootLogger.newAsyncRootBuilder()
+                                .setConfig(config)
+                                .build(),
+                        false));
+    }
+
+    static Stream<Arguments> loggerContextDefaultLocation() {
+        final LoggerContext ctx = new LoggerContext("sync");
+        ctx.setProperties(PropertiesUtil.getProperties());
+        final NullConfiguration config = new NullConfiguration(ctx);
+        ctx.setConfiguration(config);
+        return loggerConfigs(config);
+    }
+
+    @ParameterizedTest
+    @MethodSource
+    void loggerContextDefaultLocation(final LoggerConfig loggerConfig, final boolean expected) {
+        Assertions.assertThat(loggerConfig.isIncludeLocation())
+                .as("Default `includeLocation` value")
+                .isEqualTo(expected);
+    }
+
+    static Stream<LoggerConfig> asyncLoggerContextDefaultLocation() {
+        final AsyncLoggerContext ctx = new AsyncLoggerContext("async");
+        ctx.setProperties(PropertiesUtil.getProperties());
+        final NullConfiguration config = new NullConfiguration(ctx);
+        ctx.setConfiguration(config);
+        return loggerConfigs(config).map(args -> (LoggerConfig) args.get()[0]);
+    }
+
+    @ParameterizedTest
+    @MethodSource
+    void asyncLoggerContextDefaultLocation(final LoggerConfig loggerConfig) {
+        Assertions.assertThat(loggerConfig.isIncludeLocation())
+                .as("Default `includeLocation` value")
+                .isFalse();
+    }
+}
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/NestedAsyncLoggerConfigTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/NestedAsyncLoggerConfigTest.java
new file mode 100644
index 0000000000..8a2161c955
--- /dev/null
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/NestedAsyncLoggerConfigTest.java
@@ -0,0 +1,21 @@
+/*
+ * 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.async.logger;
+
+import org.apache.logging.log4j.core.test.config.AbstractNestedLoggerConfigTest;
+
+public class NestedAsyncLoggerConfigTest extends AbstractNestedLoggerConfigTest {}
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncAbstractTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncAbstractTest.java
index 93ef280d44..1e5e4bf3bc 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncAbstractTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncAbstractTest.java
@@ -26,10 +26,10 @@ import java.util.stream.Collectors;
 import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.Logger;
 import org.apache.logging.log4j.core.LoggerContext;
-import org.apache.logging.log4j.core.async.QueueFullAbstractTest;
 import org.apache.logging.log4j.core.config.Configuration;
 import org.apache.logging.log4j.core.config.LoggerConfig;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
+import org.apache.logging.log4j.core.test.async.QueueFullAbstractTest;
 import org.apache.logging.log4j.status.StatusData;
 import org.apache.logging.log4j.test.ListStatusListener;
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLogger3Test.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLogger3Test.java
index 575f15c422..d9416e79b8 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLogger3Test.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLogger3Test.java
@@ -26,6 +26,7 @@ import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.async.AsyncQueueFullPolicyFactory;
 import org.apache.logging.log4j.core.async.DiscardingAsyncQueueFullPolicy;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
+import org.apache.logging.log4j.core.test.junit.ContextSelectorType;
 import org.apache.logging.log4j.core.test.junit.LoggerContextSource;
 import org.apache.logging.log4j.core.test.junit.Named;
 import org.apache.logging.log4j.message.Message;
@@ -37,9 +38,7 @@ import org.junit.jupiter.api.Timeout;
 /**
  * Tests queue full scenarios with pure AsyncLoggers (all loggers async).
  */
-@SetTestProperty(
-        key = "LoggerContext.selector",
-        value = "org.apache.logging.log4j.core.async.AsyncLoggerContextSelector")
+@ContextSelectorType(AsyncLoggerContextSelector.class)
 @SetTestProperty(key = "AsyncLogger.ringBufferSize", value = "128")
 @SetTestProperty(key = "AsyncLogger.formatMsg", value = "true")
 @SetTestProperty(key = "AsyncLogger.queueFullPolicy", value = "Discard")
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerLoggingFromToStringTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerLoggingFromToStringTest.java
index 5ac3c0aa21..d95ec2966a 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerLoggingFromToStringTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerLoggingFromToStringTest.java
@@ -18,6 +18,7 @@ package org.apache.logging.log4j.async.logger;
 
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
+import org.apache.logging.log4j.core.test.junit.ContextSelectorType;
 import org.apache.logging.log4j.core.test.junit.LoggerContextSource;
 import org.apache.logging.log4j.core.test.junit.Named;
 import org.apache.logging.log4j.test.junit.SetTestProperty;
@@ -26,9 +27,7 @@ import org.junit.jupiter.api.Test;
 /**
  * Tests queue full scenarios with pure AsyncLoggers (all loggers async).
  */
-@SetTestProperty(
-        key = "LoggerContext.selector",
-        value = "org.apache.logging.log4j.core.async.AsyncLoggerContextSelector")
+@ContextSelectorType(AsyncLoggerContextSelector.class)
 @SetTestProperty(key = "AsyncLogger.ringBufferSize", value = "128")
 public class QueueFullAsyncLoggerLoggingFromToStringTest extends QueueFullAsyncAbstractTest {
 
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerTest.java b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerTest.java
index e6043dc880..f1e8e44107 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerTest.java
+++ b/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/QueueFullAsyncLoggerTest.java
@@ -18,6 +18,7 @@ package org.apache.logging.log4j.async.logger;
 
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
+import org.apache.logging.log4j.core.test.junit.ContextSelectorType;
 import org.apache.logging.log4j.core.test.junit.LoggerContextSource;
 import org.apache.logging.log4j.core.test.junit.Named;
 import org.apache.logging.log4j.test.junit.SetTestProperty;
@@ -26,9 +27,7 @@ import org.junit.jupiter.api.Test;
 /**
  * Tests queue full scenarios with pure AsyncLoggers (all loggers async).
  */
-@SetTestProperty(
-        key = "LoggerContext.selector",
-        value = "org.apache.logging.log4j.core.async.AsyncLoggerContextSelector")
+@ContextSelectorType(AsyncLoggerContextSelector.class)
 @SetTestProperty(key = "AsyncLogger.ringBufferSize", value = "128")
 public class QueueFullAsyncLoggerTest extends QueueFullAsyncAbstractTest {
 
diff --git a/log4j-core-test/src/test/resources/logger-config/AsyncLoggerConfig/default-level.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/NestedAsyncLoggerConfigTest/default-level.xml
similarity index 100%
rename from log4j-core-test/src/test/resources/logger-config/AsyncLoggerConfig/default-level.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/NestedAsyncLoggerConfigTest/default-level.xml
diff --git a/log4j-core-test/src/test/resources/logger-config/AsyncLoggerConfig/inherit-level.xml b/log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/NestedAsyncLoggerConfigTest/inherit-level.xml
similarity index 100%
rename from log4j-core-test/src/test/resources/logger-config/AsyncLoggerConfig/inherit-level.xml
rename to log4j-async-logger/src/test/resources/org/apache/logging/log4j/async/logger/NestedAsyncLoggerConfigTest/inherit-level.xml
diff --git a/log4j-config-properties/src/test/java/org/apache/logging/log4j/config/properties/JavaPropsConfigurationFactoryTest.java b/log4j-config-properties/src/test/java/org/apache/logging/log4j/config/properties/JavaPropsConfigurationFactoryTest.java
index a02814efb6..f1656be526 100644
--- a/log4j-config-properties/src/test/java/org/apache/logging/log4j/config/properties/JavaPropsConfigurationFactoryTest.java
+++ b/log4j-config-properties/src/test/java/org/apache/logging/log4j/config/properties/JavaPropsConfigurationFactoryTest.java
@@ -23,9 +23,9 @@ import java.nio.file.Path;
 import org.apache.logging.log4j.core.Appender;
 import org.apache.logging.log4j.core.Filter;
 import org.apache.logging.log4j.core.LoggerContext;
-import org.apache.logging.log4j.core.config.AbstractConfigurationFactoryTest;
 import org.apache.logging.log4j.core.filter.ThresholdFilter;
 import org.apache.logging.log4j.core.test.appender.ListAppender;
+import org.apache.logging.log4j.core.test.config.AbstractConfigurationFactoryTest;
 import org.apache.logging.log4j.core.test.junit.LoggerContextSource;
 import org.apache.logging.log4j.test.junit.TempLoggingDir;
 import org.junit.jupiter.api.Test;
diff --git a/log4j-config-yaml/src/test/java/org/apache/logging/log4j/config/yaml/YamlConfigurationFactoryTest.java b/log4j-config-yaml/src/test/java/org/apache/logging/log4j/config/yaml/YamlConfigurationFactoryTest.java
index 02d21323ab..8e88f321e0 100644
--- a/log4j-config-yaml/src/test/java/org/apache/logging/log4j/config/yaml/YamlConfigurationFactoryTest.java
+++ b/log4j-config-yaml/src/test/java/org/apache/logging/log4j/config/yaml/YamlConfigurationFactoryTest.java
@@ -19,7 +19,7 @@ package org.apache.logging.log4j.config.yaml;
 import java.io.IOException;
 import java.nio.file.Path;
 import org.apache.logging.log4j.core.LoggerContext;
-import org.apache.logging.log4j.core.config.AbstractConfigurationFactoryTest;
+import org.apache.logging.log4j.core.test.config.AbstractConfigurationFactoryTest;
 import org.apache.logging.log4j.core.test.junit.LoggerContextSource;
 import org.apache.logging.log4j.test.junit.TempLoggingDir;
 import org.junit.jupiter.api.Test;
diff --git a/log4j-core-test/src/main/java/org/apache/logging/log4j/core/async/QueueFullAbstractTest.java b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/async/QueueFullAbstractTest.java
similarity index 96%
rename from log4j-core-test/src/main/java/org/apache/logging/log4j/core/async/QueueFullAbstractTest.java
rename to log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/async/QueueFullAbstractTest.java
index f6ea81eb13..4943de6314 100644
--- a/log4j-core-test/src/main/java/org/apache/logging/log4j/core/async/QueueFullAbstractTest.java
+++ b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/async/QueueFullAbstractTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.async;
+package org.apache.logging.log4j.core.test.async;
 
 import static java.util.concurrent.TimeUnit.SECONDS;
 import static org.assertj.core.api.Assertions.assertThat;
@@ -32,7 +32,6 @@ import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.appender.AsyncAppender;
 import org.apache.logging.log4j.core.config.Configuration;
 import org.apache.logging.log4j.core.config.LoggerConfig;
-import org.apache.logging.log4j.core.test.async.BlockingAppender;
 import org.apache.logging.log4j.core.util.Constants;
 import org.apache.logging.log4j.status.StatusLogger;
 import org.apache.logging.log4j.test.junit.UsingStatusListener;
@@ -58,10 +57,10 @@ public abstract class QueueFullAbstractTest {
 
     protected static class Unlocker extends Thread {
 
-        final CountDownLatch countDownLatch;
+        public final CountDownLatch countDownLatch;
         final BlockingAppender blockingAppender;
 
-        Unlocker(final CountDownLatch countDownLatch, final BlockingAppender blockingAppender) {
+        public Unlocker(final CountDownLatch countDownLatch, final BlockingAppender blockingAppender) {
             this.countDownLatch = countDownLatch;
             this.blockingAppender = blockingAppender;
         }
diff --git a/log4j-core-test/src/main/java/org/apache/logging/log4j/core/config/AbstractConfigurationFactoryTest.java b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/config/AbstractConfigurationFactoryTest.java
similarity index 97%
rename from log4j-core-test/src/main/java/org/apache/logging/log4j/core/config/AbstractConfigurationFactoryTest.java
rename to log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/config/AbstractConfigurationFactoryTest.java
index 52f8ff9ee3..a0b3fc45ac 100644
--- a/log4j-core-test/src/main/java/org/apache/logging/log4j/core/config/AbstractConfigurationFactoryTest.java
+++ b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/config/AbstractConfigurationFactoryTest.java
@@ -14,7 +14,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.config;
+package org.apache.logging.log4j.core.test.config;
 
 import static org.apache.logging.log4j.util.Unbox.box;
 import static org.junit.jupiter.api.Assertions.assertAll;
@@ -35,6 +35,7 @@ import org.apache.logging.log4j.core.Filter;
 import org.apache.logging.log4j.core.Logger;
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.appender.ConsoleAppender;
+import org.apache.logging.log4j.core.config.Configuration;
 import org.apache.logging.log4j.core.filter.ThreadContextMapFilter;
 import org.apache.logging.log4j.util.Strings;
 
diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/NestedLoggerConfigTest.java b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/config/AbstractNestedLoggerConfigTest.java
similarity index 65%
copy from log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/NestedLoggerConfigTest.java
copy to log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/config/AbstractNestedLoggerConfigTest.java
index abdcd11303..4c0a3cbb5f 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/NestedLoggerConfigTest.java
+++ b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/config/AbstractNestedLoggerConfigTest.java
@@ -14,41 +14,24 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.core.config;
+package org.apache.logging.log4j.core.test.config;
 
-import static org.junit.Assert.assertEquals;
+import static org.junit.jupiter.api.Assertions.assertEquals;
 
-import com.google.common.collect.ImmutableList;
 import java.io.IOException;
 import java.io.InputStream;
-import java.util.List;
 import org.apache.logging.log4j.Level;
 import org.apache.logging.log4j.core.LoggerContext;
+import org.apache.logging.log4j.core.config.Configuration;
+import org.apache.logging.log4j.core.config.ConfigurationSource;
 import org.apache.logging.log4j.core.config.xml.XmlConfiguration;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.Parameterized;
+import org.junit.jupiter.api.Test;
 
-/**
- * Tests for LoggerConfig hierarchies.
- */
-@RunWith(Parameterized.class)
-public class NestedLoggerConfigTest {
-
-    @Parameterized.Parameters(name = "{0}")
-    public static List<String> data() throws IOException {
-        return ImmutableList.of("logger-config/LoggerConfig/", "logger-config/AsyncLoggerConfig/");
-    }
-
-    private final String prefix;
-
-    public NestedLoggerConfigTest(final String prefix) {
-        this.prefix = prefix;
-    }
+public abstract class AbstractNestedLoggerConfigTest {
 
     @Test
     public void testInheritParentDefaultLevel() throws IOException {
-        final Configuration configuration = loadConfiguration(prefix + "default-level.xml");
+        final Configuration configuration = loadConfiguration("/default-level.xml");
         try {
             assertEquals(Level.ERROR, configuration.getLoggerConfig("com.foo").getLevel());
         } finally {
@@ -58,7 +41,7 @@ public class NestedLoggerConfigTest {
 
     @Test
     public void testInheritParentLevel() throws IOException {
-        final Configuration configuration = loadConfiguration(prefix + "inherit-level.xml");
+        final Configuration configuration = loadConfiguration("/inherit-level.xml");
         try {
             assertEquals(Level.TRACE, configuration.getLoggerConfig("com.foo").getLevel());
         } finally {
@@ -67,7 +50,7 @@ public class NestedLoggerConfigTest {
     }
 
     private Configuration loadConfiguration(final String resourcePath) throws IOException {
-        try (final InputStream in = getClass().getClassLoader().getResourceAsStream(resourcePath)) {
+        try (final InputStream in = getClass().getResourceAsStream(getClass().getSimpleName() + resourcePath)) {
             final Configuration configuration =
                     new XmlConfiguration(new LoggerContext("test"), new ConfigurationSource(in));
             configuration.initialize();
diff --git a/log4j-core-test/src/main/resources/org/apache/logging/log4j/core/async/QueueFullAbstractTest.xml b/log4j-core-test/src/main/resources/org/apache/logging/log4j/core/test/async/QueueFullAbstractTest.xml
similarity index 100%
rename from log4j-core-test/src/main/resources/org/apache/logging/log4j/core/async/QueueFullAbstractTest.xml
rename to log4j-core-test/src/main/resources/org/apache/logging/log4j/core/test/async/QueueFullAbstractTest.xml
diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/appender/RandomAccessFileAppenderTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/appender/RandomAccessFileAppenderTest.java
index 1266ff7804..6b0292f74d 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/appender/RandomAccessFileAppenderTest.java
+++ b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/appender/RandomAccessFileAppenderTest.java
@@ -16,75 +16,38 @@
  */
 package org.apache.logging.log4j.core.appender;
 
-import static org.hamcrest.CoreMatchers.containsString;
-import static org.hamcrest.CoreMatchers.not;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertThat;
+import static org.assertj.core.api.Assertions.assertThat;
 
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.FileReader;
-import java.util.Arrays;
-import java.util.Collection;
+import java.nio.file.Files;
+import java.nio.file.Path;
+import java.util.List;
 import org.apache.logging.log4j.Logger;
-import org.apache.logging.log4j.core.test.junit.LoggerContextRule;
-import org.apache.logging.log4j.test.junit.CleanFiles;
-import org.hamcrest.Matcher;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.rules.RuleChain;
-import org.junit.runner.RunWith;
-import org.junit.runners.Parameterized;
+import org.apache.logging.log4j.core.LoggerContext;
+import org.apache.logging.log4j.core.test.junit.LoggerContextSource;
+import org.apache.logging.log4j.test.junit.TempLoggingDir;
+import org.junit.jupiter.api.Test;
 
 /**
  * Simple tests for both the RandomAccessFileAppender and RollingRandomAccessFileAppender.
  */
-@RunWith(Parameterized.class)
 public class RandomAccessFileAppenderTest {
 
-    @Parameterized.Parameters(name = "{0}, locationEnabled={1}, type={2}")
-    public static Collection<Object[]> data() {
-        return Arrays.asList(new Object[][] {
-            {"RandomAccessFileAppenderTest", false, ".xml"},
-            {"RandomAccessFileAppenderLocationTest", true, ".xml"},
-            {"RollingRandomAccessFileAppenderTest", false, ".xml"},
-            {"RollingRandomAccessFileAppenderLocationTest", true, ".xml"}
-        });
-    }
-
-    private final LoggerContextRule init;
-    private final CleanFiles files;
-
-    @Rule
-    public final RuleChain chain;
+    public static final String MESSAGE = "This is a test log message brought to you by Slurm.";
 
-    private final File logFile;
-    private final boolean locationEnabled;
-
-    public RandomAccessFileAppenderTest(final String testName, final boolean locationEnabled, final String type) {
-        this.init = new LoggerContextRule(testName + type);
-        this.logFile = new File("target", testName + ".log");
-        this.files = new CleanFiles(this.logFile);
-        this.locationEnabled = locationEnabled;
-        this.chain = RuleChain.outerRule(files).around(init);
-    }
+    @TempLoggingDir
+    private static Path loggingPath;
 
     @Test
-    public void testRandomAccessConfiguration() throws Exception {
-        final Logger logger = this.init.getLogger("com.foo.Bar");
-        final String message = "This is a test log message brought to you by Slurm.";
-        logger.info(message);
-        this.init.getLoggerContext().stop(); // stop async thread
-
-        String line;
-        try (final BufferedReader reader = new BufferedReader(new FileReader(this.logFile))) {
-            line = reader.readLine();
+    @LoggerContextSource
+    public void testRandomAccessConfiguration(final LoggerContext ctx) throws Exception {
+        final Logger logger = ctx.getLogger(getClass());
+        logger.info(MESSAGE);
+        ctx.stop();
+
+        for (final String fileName : List.of("RandomAccessFile.log", "RollingRandomAccessFile.log")) {
+            final Path file = loggingPath.resolve(fileName);
+            assertThat(file).isNotEmptyFile();
+            assertThat(Files.readAllLines(file)).hasSize(1).containsExactly(MESSAGE);
         }
-        assertNotNull(line);
-        assertThat(line, containsString(message));
-        final Matcher<String> containsLocationInformation = containsString("testRandomAccessConfiguration");
-        final Matcher<String> containsLocationInformationIfEnabled =
-                this.locationEnabled ? containsLocationInformation : not(containsLocationInformation);
-        assertThat(line, containsLocationInformationIfEnabled);
     }
 }
diff --git a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncQueueFullPolicyFactoryTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/async/AsyncQueueFullPolicyFactoryTest.java
similarity index 93%
rename from log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncQueueFullPolicyFactoryTest.java
rename to log4j-core-test/src/test/java/org/apache/logging/log4j/core/async/AsyncQueueFullPolicyFactoryTest.java
index 7f9f9c1c30..532cb9fe6e 100644
--- a/log4j-async-logger/src/test/java/org/apache/logging/log4j/async/logger/AsyncQueueFullPolicyFactoryTest.java
+++ b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/async/AsyncQueueFullPolicyFactoryTest.java
@@ -14,17 +14,12 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.logging.log4j.async.logger;
+package org.apache.logging.log4j.core.async;
 
 import static org.apache.logging.log4j.util.Strings.toRootLowerCase;
 import static org.junit.jupiter.api.Assertions.assertEquals;
 
 import org.apache.logging.log4j.Level;
-import org.apache.logging.log4j.core.async.AsyncQueueFullPolicy;
-import org.apache.logging.log4j.core.async.AsyncQueueFullPolicyFactory;
-import org.apache.logging.log4j.core.async.DefaultAsyncQueueFullPolicy;
-import org.apache.logging.log4j.core.async.DiscardingAsyncQueueFullPolicy;
-import org.apache.logging.log4j.core.async.EventRoute;
 import org.apache.logging.log4j.core.impl.Log4jPropertyKey;
 import org.apache.logging.log4j.util.PropertiesUtil;
 import org.junit.jupiter.api.AfterEach;
diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncAppenderTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncAppenderTest.java
index e2383a8691..d4d15772ac 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncAppenderTest.java
+++ b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/async/QueueFullAsyncAppenderTest.java
@@ -18,6 +18,7 @@ package org.apache.logging.log4j.core.async;
 
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.test.async.BlockingAppender;
+import org.apache.logging.log4j.core.test.async.QueueFullAbstractTest;
 import org.apache.logging.log4j.core.test.junit.LoggerContextSource;
 import org.apache.logging.log4j.core.test.junit.Named;
 import org.junit.jupiter.api.Test;
diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/ConfigurationFactoryTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/ConfigurationFactoryTest.java
index 623f841be8..b78741cd6c 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/ConfigurationFactoryTest.java
+++ b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/ConfigurationFactoryTest.java
@@ -19,6 +19,7 @@ package org.apache.logging.log4j.core.config;
 import java.io.IOException;
 import java.nio.file.Path;
 import org.apache.logging.log4j.core.LoggerContext;
+import org.apache.logging.log4j.core.test.config.AbstractConfigurationFactoryTest;
 import org.apache.logging.log4j.core.test.junit.LoggerContextSource;
 import org.apache.logging.log4j.test.junit.TempLoggingDir;
 import org.junit.jupiter.api.Tag;
diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/NestedLoggerConfigTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/NestedLoggerConfigTest.java
index abdcd11303..72fc5726fd 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/NestedLoggerConfigTest.java
+++ b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/NestedLoggerConfigTest.java
@@ -16,63 +16,9 @@
  */
 package org.apache.logging.log4j.core.config;
 
-import static org.junit.Assert.assertEquals;
-
-import com.google.common.collect.ImmutableList;
-import java.io.IOException;
-import java.io.InputStream;
-import java.util.List;
-import org.apache.logging.log4j.Level;
-import org.apache.logging.log4j.core.LoggerContext;
-import org.apache.logging.log4j.core.config.xml.XmlConfiguration;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.Parameterized;
+import org.apache.logging.log4j.core.test.config.AbstractNestedLoggerConfigTest;
 
 /**
  * Tests for LoggerConfig hierarchies.
  */
-@RunWith(Parameterized.class)
-public class NestedLoggerConfigTest {
-
-    @Parameterized.Parameters(name = "{0}")
-    public static List<String> data() throws IOException {
-        return ImmutableList.of("logger-config/LoggerConfig/", "logger-config/AsyncLoggerConfig/");
-    }
-
-    private final String prefix;
-
-    public NestedLoggerConfigTest(final String prefix) {
-        this.prefix = prefix;
-    }
-
-    @Test
-    public void testInheritParentDefaultLevel() throws IOException {
-        final Configuration configuration = loadConfiguration(prefix + "default-level.xml");
-        try {
-            assertEquals(Level.ERROR, configuration.getLoggerConfig("com.foo").getLevel());
-        } finally {
-            configuration.stop();
-        }
-    }
-
-    @Test
-    public void testInheritParentLevel() throws IOException {
-        final Configuration configuration = loadConfiguration(prefix + "inherit-level.xml");
-        try {
-            assertEquals(Level.TRACE, configuration.getLoggerConfig("com.foo").getLevel());
-        } finally {
-            configuration.stop();
-        }
-    }
-
-    private Configuration loadConfiguration(final String resourcePath) throws IOException {
-        try (final InputStream in = getClass().getClassLoader().getResourceAsStream(resourcePath)) {
-            final Configuration configuration =
-                    new XmlConfiguration(new LoggerContext("test"), new ConfigurationSource(in));
-            configuration.initialize();
-            configuration.start();
-            return configuration;
-        }
-    }
-}
+public class NestedLoggerConfigTest extends AbstractNestedLoggerConfigTest {}
diff --git a/log4j-core-test/src/test/resources/RandomAccessFileAppenderLocationTest.xml b/log4j-core-test/src/test/resources/RandomAccessFileAppenderLocationTest.xml
deleted file mode 100644
index 38a76f0a89..0000000000
--- a/log4j-core-test/src/test/resources/RandomAccessFileAppenderLocationTest.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?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.
-  -->
-<Configuration status="OFF">
-  <Appenders>
-    <RandomAccessFile name="RandomAccessFile" fileName="target/RandomAccessFileAppenderLocationTest.log" immediateFlush="false" append="false">
-      <PatternLayout>
-        <Pattern>%d %p %c{1.} [%t] %X{aKey} %m %location %ex%n</Pattern>
-        <!--
-        <Pattern>%d %p %c{1.} %C %location %line [%t] %X{aKey} %m %ex%n</Pattern>
-        -->
-      </PatternLayout>
-    </RandomAccessFile>
-  </Appenders>
-
-  <Loggers>
-    <AsyncRoot level="info" includeLocation="true">
-      <AppenderRef ref="RandomAccessFile"/>
-    </AsyncRoot>
-  </Loggers>
-</Configuration>
diff --git a/log4j-core-test/src/test/resources/RandomAccessFileAppenderTest.xml b/log4j-core-test/src/test/resources/RandomAccessFileAppenderTest.xml
deleted file mode 100644
index 146dd390cb..0000000000
--- a/log4j-core-test/src/test/resources/RandomAccessFileAppenderTest.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-<?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.
-  -->
-<Configuration status="OFF">
-  <Appenders>
-    <RandomAccessFile name="RandomAccessFile" fileName="target/RandomAccessFileAppenderTest.log" immediateFlush="false" append="false">
-      <PatternLayout>
-        <Pattern>%d %p %c{1.} [%t] %X{aKey} %m %location %ex%n</Pattern>
-        <!--
-        <Pattern>%d %p %c{1.} %C %location %line [%t] %X{aKey} %m %ex%n</Pattern>
-        -->
-      </PatternLayout>
-    </RandomAccessFile>
-  </Appenders>
-
-  <Loggers>
-    <AsyncRoot level="info" includeLocation="false">
-      <AppenderRef ref="RandomAccessFile"/>
-    </AsyncRoot>
-  </Loggers>
-</Configuration>
diff --git a/log4j-core-test/src/test/resources/RollingRandomAccessFileAppenderTest.xml b/log4j-core-test/src/test/resources/RollingRandomAccessFileAppenderTest.xml
deleted file mode 100644
index fcea9c717c..0000000000
--- a/log4j-core-test/src/test/resources/RollingRandomAccessFileAppenderTest.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-<?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.
-  -->
-<Configuration status="OFF">
-  <Appenders>
-    <RollingRandomAccessFile name="RollingRandomAccessFile" fileName="target/RollingRandomAccessFileAppenderTest.log"
-                 filePattern="target/afterRollover-%i.log" append="false"
-                 immediateFlush="false">
-      <PatternLayout>
-        <Pattern>%d %p %c{1.} [%t] %X{aKey} %m %location %ex%n</Pattern>
-      </PatternLayout>
-      <Policies>
-        <SizeBasedTriggeringPolicy size="250 B"/>
-      </Policies>
-    </RollingRandomAccessFile>
-  </Appenders>
-
-  <Loggers>
-    <AsyncRoot level="info" includeLocation="false">
-      <AppenderRef ref="RollingRandomAccessFile"/>
-    </AsyncRoot>
-  </Loggers>
-</Configuration>
diff --git a/log4j-core-test/src/test/resources/RollingRandomAccessFileAppenderLocationTest.xml b/log4j-core-test/src/test/resources/org/apache/logging/log4j/core/appender/RandomAccessFileAppenderTest.xml
similarity index 58%
rename from log4j-core-test/src/test/resources/RollingRandomAccessFileAppenderLocationTest.xml
rename to log4j-core-test/src/test/resources/org/apache/logging/log4j/core/appender/RandomAccessFileAppenderTest.xml
index 9e4f844552..06b2dd8035 100644
--- a/log4j-core-test/src/test/resources/RollingRandomAccessFileAppenderLocationTest.xml
+++ b/log4j-core-test/src/test/resources/org/apache/logging/log4j/core/appender/RandomAccessFileAppenderTest.xml
@@ -17,21 +17,25 @@
   -->
 <Configuration status="OFF">
   <Appenders>
-    <RollingRandomAccessFile name="RollingRandomAccessFile" fileName="target/RollingRandomAccessFileAppenderLocationTest.log"
-                 filePattern="test-%d{MM-dd-yyyy}-%i.log.gz" append="false"
-                 immediateFlush="false">
-      <PatternLayout>
-        <Pattern>%d %p %c{1.} [%t] %X{aKey} %m %location %ex%n</Pattern>
-      </PatternLayout>
-      <Policies>
-        <TimeBasedTriggeringPolicy />
-      </Policies>
+    <RandomAccessFile name="RandomAccessFile"
+                      fileName="${test:logging.path}/RandomAccessFile.log"
+                      immediateFlush="false"
+                      append="false">
+      <PatternLayout/>
+    </RandomAccessFile>
+    <RollingRandomAccessFile name="RollingRandomAccessFile"
+                             fileName="${test:logging.path}/RollingRandomAccessFile.log"
+                             filePattern="${test:logging.path}/afterRollover-%i.log"
+                             append="false"
+                             immediateFlush="false">
+      <PatternLayout/>
+      <SizeBasedTriggeringPolicy size="250 B"/>
     </RollingRandomAccessFile>
   </Appenders>
-
   <Loggers>
-    <AsyncRoot level="info" includeLocation="true">
+    <Root level="INFO">
+      <AppenderRef ref="RandomAccessFile"/>
       <AppenderRef ref="RollingRandomAccessFile"/>
-    </AsyncRoot>
+    </Root>
   </Loggers>
 </Configuration>
diff --git a/log4j-core-test/src/test/resources/logger-config/LoggerConfig/default-level.xml b/log4j-core-test/src/test/resources/org/apache/logging/log4j/core/config/NestedLoggerConfigTest/default-level.xml
similarity index 100%
rename from log4j-core-test/src/test/resources/logger-config/LoggerConfig/default-level.xml
rename to log4j-core-test/src/test/resources/org/apache/logging/log4j/core/config/NestedLoggerConfigTest/default-level.xml
diff --git a/log4j-core-test/src/test/resources/logger-config/LoggerConfig/inherit-level.xml b/log4j-core-test/src/test/resources/org/apache/logging/log4j/core/config/NestedLoggerConfigTest/inherit-level.xml
similarity index 100%
rename from log4j-core-test/src/test/resources/logger-config/LoggerConfig/inherit-level.xml
rename to log4j-core-test/src/test/resources/org/apache/logging/log4j/core/config/NestedLoggerConfigTest/inherit-level.xml