diff options
author | Marius Volkhart <mariusvolkhart@apache.org> | 2021-02-21 20:57:25 +0000 |
---|---|---|
committer | Marius Volkhart <mariusvolkhart@apache.org> | 2021-02-21 20:57:25 +0000 |
commit | 259c9967efb354a0feff2a861ac8bd20582b6562 (patch) | |
tree | ba76a4f20503d97e77bdf18146d59e00a2369fb9 /sonar | |
parent | 6d10f26718f84591671d7cafdcc009345b9c777e (diff) | |
download | poi-259c9967efb354a0feff2a861ac8bd20582b6562.tar.gz poi-259c9967efb354a0feff2a861ac8bd20582b6562.zip |
[bug-63046] Use Log4j 2 for logging
This removes the POILogger and POILogFactory mechanism for logging. This mechanism was created at a time when the Java landscape looked very different than it does today.
Log4j 2 is an Apache Foundation project that is well maintained and is widely regarded as having good performance and capabilities. We use only the Log4j API artifact. This lets application developers choose how they want to capture logging events if at all. Integrations with Log4j 2 Core and Logback are available from the Log4j project.
Closes #224
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1886770 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sonar')
-rw-r--r-- | sonar/excelant/pom.xml | 3 | ||||
-rw-r--r-- | sonar/integration-test/pom.xml | 3 | ||||
-rw-r--r-- | sonar/main/pom.xml | 14 | ||||
-rw-r--r-- | sonar/ooxml/pom.xml | 15 | ||||
-rw-r--r-- | sonar/pom.xml | 7 | ||||
-rw-r--r-- | sonar/scratchpad/pom.xml | 3 |
6 files changed, 24 insertions, 21 deletions
diff --git a/sonar/excelant/pom.xml b/sonar/excelant/pom.xml index 56c42cead9..3c28c7989b 100644 --- a/sonar/excelant/pom.xml +++ b/sonar/excelant/pom.xml @@ -49,6 +49,9 @@ <resource> <directory>../../src/excelant/resources</directory> </resource> + <resource> + <directory>../../src/resources/test</directory> + </resource> </resources> </configuration> </execution> diff --git a/sonar/integration-test/pom.xml b/sonar/integration-test/pom.xml index 54cc95e79b..d1baa067e4 100644 --- a/sonar/integration-test/pom.xml +++ b/sonar/integration-test/pom.xml @@ -41,6 +41,9 @@ <include>org/apache/poi/hssf/HSSFTestDataSamples.java</include> </includes> </resource> + <resource> + <directory>../../src/resources/integrationtest</directory> + </resource> </resources> </configuration> </execution> diff --git a/sonar/main/pom.xml b/sonar/main/pom.xml index b20321c9ec..0d99970519 100644 --- a/sonar/main/pom.xml +++ b/sonar/main/pom.xml @@ -63,6 +63,9 @@ <resource> <directory>../../src/testcases</directory> </resource> + <resource> + <directory>../../src/resources/test</directory> + </resource> </resources> </configuration> </execution> @@ -101,14 +104,9 @@ <dependencies> <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.30</version> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>jcl-over-slf4j</artifactId> - <version>1.7.30</version> + <groupId>org.apache.logging.log4j</groupId> + <artifactId>log4j-api</artifactId> + <version>2.14.0</version> </dependency> <dependency> <groupId>commons-codec</groupId> diff --git a/sonar/ooxml/pom.xml b/sonar/ooxml/pom.xml index 6da633343d..454f46b8b4 100644 --- a/sonar/ooxml/pom.xml +++ b/sonar/ooxml/pom.xml @@ -60,6 +60,9 @@ <resource> <directory>../../src/ooxml/testcases</directory> </resource> + <resource> + <directory>../../src/resources/test</directory> + </resource> </resources> </configuration> </execution> @@ -152,23 +155,11 @@ <groupId>org.apache.xmlgraphics</groupId> <artifactId>batik-all</artifactId> <version>1.14</version> - <exclusions> - <exclusion> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - </exclusion> - </exclusions> </dependency> <dependency> <groupId>de.rototor.pdfbox</groupId> <artifactId>graphics2d</artifactId> <version>0.30</version> - <exclusions> - <exclusion> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - </exclusion> - </exclusions> </dependency> <dependency> diff --git a/sonar/pom.xml b/sonar/pom.xml index fc16a892ba..8dfbf0df4b 100644 --- a/sonar/pom.xml +++ b/sonar/pom.xml @@ -115,7 +115,6 @@ <systemPropertyVariables> <POI.testdata.path>../../test-data</POI.testdata.path> <java.awt.headless>true</java.awt.headless> - <org.apache.poi.util.POILogger>org.apache.poi.util.NullLogger</org.apache.poi.util.POILogger> </systemPropertyVariables> <!-- use to following to analyze OOM issues: -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/tmp --> <argLine>@{argLine} -Duser.language=en -Duser.country=US -Xmx1024m -Djava.io.tmpdir=${basedir}/target/tmp -XX:-OmitStackTraceInFastThrow</argLine> @@ -180,6 +179,12 @@ <version>2.2</version> <scope>test</scope> </dependency> + <dependency> + <groupId>org.apache.logging.log4j</groupId> + <artifactId>log4j-core</artifactId> + <version>2.14.0</version> + <scope>test</scope> + </dependency> </dependencies> <profiles> diff --git a/sonar/scratchpad/pom.xml b/sonar/scratchpad/pom.xml index 6bb368e8e5..c79dc66f81 100644 --- a/sonar/scratchpad/pom.xml +++ b/sonar/scratchpad/pom.xml @@ -71,6 +71,9 @@ <resource> <directory>../../src/scratchpad/testcases</directory> </resource> + <resource> + <directory>../../src/resources/test</directory> + </resource> </resources> </configuration> </execution> |