-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Update Log4j * update log4j (again)
- Loading branch information
Showing
2 changed files
with
112 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,111 @@ | ||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 | ||
From: sulu5890 <sulu@sulu.me> | ||
Date: Sat, 11 Dec 2021 12:42:57 -0600 | ||
Subject: [PATCH] Update Log4j | ||
|
||
|
||
diff --git a/pom.xml b/pom.xml | ||
index e4c63bb76cb598545f9d215a8859724d6e7f8b81..4d4e37c1ad973e5419924f61972b37980d2233ea 100644 | ||
--- a/pom.xml | ||
+++ b/pom.xml | ||
@@ -63,25 +63,25 @@ | ||
<dependency> | ||
<groupId>org.apache.logging.log4j</groupId> | ||
<artifactId>log4j-core</artifactId> | ||
- <version>2.8.1</version> | ||
+ <version>2.17.0</version> <!-- Paper - Update Log4j --> | ||
<scope>compile</scope> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.apache.logging.log4j</groupId> | ||
<artifactId>log4j-slf4j-impl</artifactId> | ||
- <version>2.8.1</version> | ||
+ <version>2.17.0</version> <!-- Paper - Update Log4j --> | ||
<scope>runtime</scope> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.apache.logging.log4j</groupId> | ||
<artifactId>log4j-iostreams</artifactId> | ||
- <version>2.8.1</version> | ||
+ <version>2.17.0</version> <!-- Paper - Update Log4j --> | ||
</dependency> | ||
<!-- Paper - Async loggers --> | ||
<dependency> | ||
<groupId>com.lmax</groupId> | ||
<artifactId>disruptor</artifactId> | ||
- <version>3.4.2</version> | ||
+ <version>3.4.4</version> <!-- Paper - Update Log4j --> | ||
<scope>runtime</scope> | ||
</dependency> | ||
<dependency> | ||
@@ -203,6 +203,7 @@ | ||
<Specification-Title>Bukkit</Specification-Title> | ||
<Specification-Version>${api.version}</Specification-Version> | ||
<Specification-Vendor>Bukkit Team</Specification-Vendor> | ||
+ <Multi-Release>true</Multi-Release> <!-- Paper - update log4j --> | ||
</manifestEntries> | ||
<manifestSections> | ||
<manifestSection> | ||
@@ -230,7 +231,7 @@ | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-shade-plugin</artifactId> | ||
- <version>3.2.3</version> | ||
+ <version>3.2.4</version> <!-- Paper - Update Log4j --> | ||
<executions> | ||
<execution> | ||
<phase>package</phase> | ||
@@ -242,7 +243,7 @@ | ||
<createSourcesJar>${shadeSourcesJar}</createSourcesJar> | ||
<filters> | ||
<filter> | ||
- <artifact>org.spigotmc:minecraft-server</artifact> | ||
+ <artifact>org.spigotmc:minecraft-server:**</artifact> <!-- Paper - update log4j --> | ||
<excludes> | ||
<exclude>com/google/common/**</exclude> | ||
<exclude>com/google/gson/**</exclude> | ||
@@ -254,7 +255,7 @@ | ||
<exclude>META-INF/MANIFEST.MF</exclude> | ||
<exclude>com.mojang.authlib.yggdrasil.YggdrasilGameProfileRepository</exclude> | ||
<exclude>com.mojang.datafixers.util.Either</exclude> | ||
- <exclude>org.apache.logging.log4j/**</exclude> | ||
+ <exclude>org/apache/logging/log4j/**</exclude> <!-- Paper - update log4j --> | ||
</excludes> | ||
</filter> | ||
</filters> | ||
@@ -307,16 +308,18 @@ | ||
<transformer implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer"> | ||
<resource>META-INF/services/java.sql.Driver</resource> | ||
</transformer> | ||
- <transformer implementation="com.github.edwgiz.maven_shade_plugin.log4j2_cache_transformer.PluginsCacheFileTransformer" /> | ||
+ <transformer implementation="io.github.edwgiz.log4j.maven.plugins.shade.transformer.Log4j2PluginCacheFileTransformer" /> <!-- Paper - update log4j --> | ||
</transformers> | ||
</configuration> | ||
</execution> | ||
</executions> | ||
<dependencies> | ||
<dependency> | ||
- <groupId>com.github.edwgiz</groupId> | ||
- <artifactId>maven-shade-plugin.log4j2-cachefile-transformer</artifactId> | ||
- <version>2.13.1</version> | ||
+ <!-- Paper start - update log4j --> | ||
+ <groupId>io.github.edwgiz</groupId> | ||
+ <artifactId>log4j-maven-shade-plugin-extensions</artifactId> | ||
+ <version>2.17.0</version> | ||
+ <!-- Paper end - update log4j --> | ||
</dependency> | ||
</dependencies> | ||
</plugin> | ||
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java | ||
index 2ea6f5b7da35cbb342e72a00ea70fef667f05d49..da02663cb468449aed25b2d6ff2a416179c3088b 100644 | ||
--- a/src/main/java/org/bukkit/craftbukkit/Main.java | ||
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java | ||
@@ -178,7 +178,7 @@ public class Main { | ||
tryPreloadClass("org.apache.logging.log4j.core.async.DisruptorUtil"); | ||
tryPreloadClass("org.apache.logging.log4j.core.async.RingBufferLogEventHandler"); | ||
tryPreloadClass("org.apache.logging.log4j.core.impl.ThrowableProxy"); | ||
- tryPreloadClass("org.apache.logging.log4j.core.impl.ThrowableProxy$CacheEntry"); | ||
+ tryPreloadClass("org.apache.logging.log4j.core.impl.ThrowableProxyHelper$CacheEntry"); // Paper - Update Log4j -- https://github.com/apache/logging-log4j2/commit/de6593f5f3b5acbb2cdb4ee91e4e1f472db5dcbb | ||
tryPreloadClass("org.apache.logging.log4j.core.impl.ExtendedClassInfo"); | ||
tryPreloadClass("org.apache.logging.log4j.core.impl.ExtendedStackTraceElement"); | ||
// Paper end |
Submodule Paperclip
updated
7 files