Skip to content

Commit 8368d99

Browse files
author
Brett Berenz
authored
Log4j update (#897)
1 parent db01438 commit 8368d99

File tree

113 files changed

+395
-385
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

113 files changed

+395
-385
lines changed

build.xml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,11 +96,12 @@
9696
<jar compress="${jar.compress}" index="${jar.index}" destfile="${dist.dir}/${project.filename}.jar" duplicate="preserve">
9797
<fileset dir="${build.dir}/${project.filename}"/>
9898
<!-- Some root level files will cause jlink to fail, they need to be cleaned up -->
99-
<fileset dir="${out.dir}/libs-temp" excludes="*.class,LICENSE,jetty-dir.css"/>
99+
<fileset dir="${out.dir}/libs-temp" excludes="*.class,LICENSE,jetty-dir.css,about.html,Log4j-*"/>
100100
<manifest>
101101
<attribute name="Application-Name" value="${project.name}"/>
102102
<attribute name="Main-Class" value="qz.App"/>
103103
<attribute name="Permissions" value="all-permissions"/>
104+
<attribute name="Multi-Release" value="true"/>
104105
</manifest>
105106
</jar>
106107
<delete dir="${out.dir}/libs-temp" includeemptydirs="true" defaultexcludes="false"/>
@@ -156,10 +157,14 @@
156157
<!-- Remove files that can/did collide during unpacking -->
157158
<delete includeemptydirs="true" failonerror="false">
158159
<fileset dir="${out.dir}/libs-temp">
159-
<include name="**/META-INF/**"/>
160-
<exclude name="**/META-INF/maven/**"/>
161160
<include name="LICENSE*"/>
162161
<include name="README*"/>
162+
<include name="**/META-INF/**"/>
163+
<!-- Used by SecurityInfo.getMavenVersions() -->
164+
<exclude name="**/META-INF/maven/**"/>
165+
<!-- Required by log4j -->
166+
<exclude name="**/META-INF/**/apache/logging/**"/>
167+
<exclude name="**/META-INF/services/**"/>
163168
</fileset>
164169
</delete>
165170
</target>
-438 KB
Binary file not shown.

lib/logging/log4j-1.2.17.jar

-478 KB
Binary file not shown.

lib/logging/log4j-api-2.16.0.jar

295 KB
Binary file not shown.

lib/logging/log4j-core-2.16.0.jar

1.71 MB
Binary file not shown.

lib/logging/slf4j-api-1.7.12.jar

-31.4 KB
Binary file not shown.
-8.65 KB
Binary file not shown.

src/com/apple/OSXAdapterWrapper.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
package com.apple;
1212

1313
import com.github.zafarkhaja.semver.Version;
14-
import org.slf4j.Logger;
15-
import org.slf4j.LoggerFactory;
14+
import org.apache.logging.log4j.LogManager;
15+
import org.apache.logging.log4j.Logger;
1616
import qz.common.Constants;
1717
import qz.utils.MacUtilities;
1818

@@ -27,7 +27,7 @@
2727
* @author Tres Finocchiaro
2828
*/
2929
public class OSXAdapterWrapper implements InvocationHandler {
30-
private static final Logger log = LoggerFactory.getLogger(OSXAdapterWrapper.class);
30+
private static final Logger log = LogManager.getLogger(OSXAdapterWrapper.class);
3131
public static final boolean legacyMode = Constants.JAVA_VERSION.lessThan(Version.valueOf("9.0.0"));
3232

3333
private Object target;

src/log4j.xml

Lines changed: 0 additions & 29 deletions
This file was deleted.

src/log4j2.xml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Configuration>
3+
<Appenders>
4+
<Console name="console" target="SYSTEM_OUT">
5+
<PatternLayout pattern="[%p] %d{ISO8601} @ %c:%L%n\t%m%n"/>
6+
</Console>
7+
</Appenders>
8+
<Loggers>
9+
<!-- Packages -->
10+
<Logger name="qz" level="trace"/>
11+
<!-- Default -->
12+
<Root level="warn">
13+
<AppenderRef ref="console"/>
14+
</Root>
15+
</Loggers>
16+
</Configuration>

0 commit comments

Comments
 (0)