This is an automated email from the ASF dual-hosted git repository.
pkarwasz pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/logging-log4j-samples.git
The following commit(s) were added to refs/heads/main by this push:
new f6986ba Adds `log4j-server` to the build
f6986ba is described below
commit f6986baea723908d038977ddf80f5ebf0e1a77a9
Author: Piotr P. Karwasz <[email protected]>
AuthorDate: Tue Nov 14 14:20:41 2023 +0100
Adds `log4j-server` to the build
---
log4j-server/pom.xml | 192 +++++++++------------------------------------------
pom.xml | 25 +++++--
2 files changed, 54 insertions(+), 163 deletions(-)
diff --git a/log4j-server/pom.xml b/log4j-server/pom.xml
index c95fdb2..284c9aa 100644
--- a/log4j-server/pom.xml
+++ b/log4j-server/pom.xml
@@ -3,11 +3,11 @@
~ 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 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
+ ~ 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,
@@ -18,57 +18,60 @@
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
- <groupId>org.apache.logging.log4j</groupId>
- <artifactId>log4j-tools</artifactId>
- <version>3.0.0-SNAPSHOT</version>
- <relativePath>../</relativePath>
+ <groupId>org.apache.logging.log4j.samples</groupId>
+ <artifactId>log4j-samples</artifactId>
+ <version>${revision}</version>
</parent>
+
<artifactId>log4j-server</artifactId>
<packaging>jar</packaging>
<name>Apache Log4j Server components</name>
<description>The Apache Log4j server components</description>
+
<properties>
- <log4jParentDir>${basedir}/..</log4jParentDir>
- <projectDir>/log4j-server</projectDir>
+ <log4j2.version>3.0.0-SNAPSHOT</log4j2.version>
</properties>
+
<dependencies>
+ <!-- Used for JMS server (needs an implementation of course) -->
+ <dependency>
+ <groupId>javax.jms</groupId>
+ <artifactId>javax.jms-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
</dependency>
+
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-jms</artifactId>
- <version>${project.version}</version>
</dependency>
+
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-layout-jackson-json</artifactId>
- <version>${project.version}</version>
</dependency>
+
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-layout-jackson-xml</artifactId>
- <version>${project.version}</version>
- </dependency>
- <!-- Used for JMS server (needs an implementation of course) -->
- <dependency>
- <groupId>org.jboss.spec.javax.jms</groupId>
- <artifactId>jboss-jms-api_1.1_spec</artifactId>
- <scope>provided</scope>
- <optional>true</optional>
</dependency>
+
<!-- Required for JSON support -->
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
+
<!-- Required for XML support -->
<dependency>
<groupId>com.fasterxml.jackson.dataformat</groupId>
<artifactId>jackson-dataformat-xml</artifactId>
</dependency>
- <!-- POM for jackson-dataformat-xml 2.8.3 depends on woodstox-core 5.0.2
-->
+
<dependency>
<groupId>com.fasterxml.woodstox</groupId>
<artifactId>woodstox-core</artifactId>
@@ -77,165 +80,36 @@
<!-- TEST DEPENDENCIES -->
+ <dependency>
+ <groupId>org.apache.activemq</groupId>
+ <artifactId>activemq-broker</artifactId>
+ <scope>test</scope>
+ </dependency>
+
<!-- Pull in useful test classes from API -->
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core-test</artifactId>
<scope>test</scope>
</dependency>
+
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
+
<dependency>
<groupId>org.hamcrest</groupId>
- <artifactId>hamcrest-all</artifactId>
+ <artifactId>hamcrest</artifactId>
<scope>test</scope>
</dependency>
+
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
</dependency>
- <dependency>
- <groupId>org.apache.activemq</groupId>
- <artifactId>activemq-broker</artifactId>
- <scope>test</scope>
- </dependency>
+
</dependencies>
- <build>
- <plugins>
- <!-- Include the standard NOTICE and LICENSE -->
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-remote-resources-plugin</artifactId>
- <executions>
- <execution>
- <goals>
- <goal>process</goal>
- </goals>
- <configuration>
- <skip>false</skip>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-bundle-plugin</artifactId>
- <configuration>
- <instructions>
-
<Export-Package>org.apache.logging.log4j.core.net.*</Export-Package>
- </instructions>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-jar-plugin</artifactId>
- <executions>
- <execution>
- <goals>
- <goal>test-jar</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- <reporting>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-changes-plugin</artifactId>
- <version>${changes.plugin.version}</version>
- <reportSets>
- <reportSet>
- <reports>
- <report>changes-report</report>
- </reports>
- </reportSet>
- </reportSets>
- <configuration>
- <issueLinkTemplate>%URL%/show_bug.cgi?id=%ISSUE%</issueLinkTemplate>
- <useJql>true</useJql>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-checkstyle-plugin</artifactId>
- <version>${checkstyle.plugin.version}</version>
- <configuration>
-
<!--<propertiesLocation>${vfs.parent.dir}/checkstyle.properties</propertiesLocation>
-->
- <configLocation>${log4jParentDir}/checkstyle.xml</configLocation>
-
<suppressionsLocation>${log4jParentDir}/checkstyle-suppressions.xml</suppressionsLocation>
- <enableRulesSummary>false</enableRulesSummary>
- <propertyExpansion>basedir=${basedir}</propertyExpansion>
-
<propertyExpansion>licensedir=${log4jParentDir}/checkstyle-header.txt</propertyExpansion>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-javadoc-plugin</artifactId>
- <version>${javadoc.plugin.version}</version>
- <configuration>
- <bottom><![CDATA[<p align="center">Copyright ©
{inceptionYear}-{currentYear} {organizationName}. All Rights Reserved.<br />
- Apache Logging, Apache Log4j, Log4j, Apache, the Apache feather
logo, the Apache Logging project logo,
- and the Apache Log4j logo are trademarks of The Apache Software
Foundation.</p>]]></bottom>
- <!-- module link generation is completely broken in the javadoc
plugin for a multi-module non-aggregating
- project -->
- <detectOfflineLinks>false</detectOfflineLinks>
- <linksource>true</linksource>
- </configuration>
- <reportSets>
- <reportSet>
- <id>non-aggregate</id>
- <reports>
- <report>javadoc</report>
- </reports>
- </reportSet>
- </reportSets>
- </plugin>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>findbugs-maven-plugin</artifactId>
- <version>${findbugs.plugin.version}</version>
- <configuration>
- <fork>true</fork>
- <jvmArgs>-Duser.language=en</jvmArgs>
- <threshold>Normal</threshold>
- <effort>Default</effort>
-
<excludeFilterFile>${log4jParentDir}/findbugs-exclude-filter.xml</excludeFilterFile>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-jxr-plugin</artifactId>
- <version>${jxr.plugin.version}</version>
- <reportSets>
- <reportSet>
- <id>non-aggregate</id>
- <reports>
- <report>jxr</report>
- </reports>
- </reportSet>
- <reportSet>
- <id>aggregate</id>
- <reports>
- <report>aggregate</report>
- </reports>
- </reportSet>
- </reportSets>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-pmd-plugin</artifactId>
- <version>${pmd.plugin.version}</version>
- <configuration>
- <targetJdk>${maven.compiler.target}</targetJdk>
- </configuration>
- </plugin>
- </plugins>
- </reporting>
</project>
-
diff --git a/pom.xml b/pom.xml
index 82a1461..3c0f45c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -41,6 +41,7 @@
<module>log4j-samples-flume-remote</module>
<module>log4j-samples-jlink</module>
<module>log4j-samples-loggerProperties</module>
+ <module>log4j-server</module>
<module>log4j-spring-cloud-config-sample-application</module>
<module>log4j-spring-cloud-config-sample-server</module>
</modules>
@@ -62,8 +63,10 @@
<flatten-maven-plugin.version>1.5.0</flatten-maven-plugin.version>
<flume.version>1.11.0</flume.version>
<guava.version>32.1.3-jre</guava.version>
+ <hamcrest.version>2.2</hamcrest.version>
<jackson.version>2.15.3</jackson.version>
<jetty.version>10.0.17</jetty.version>
+ <javax-jms.version>2.0.1</javax-jms.version>
<junit.version>5.9.0</junit.version>
<kotlin.version>1.9.10</kotlin.version>
<kubernetes-client.version>6.9.0</kubernetes-client.version>
@@ -97,6 +100,14 @@
<scope>import</scope>
</dependency>
+ <dependency>
+ <groupId>org.junit</groupId>
+ <artifactId>junit-bom</artifactId>
+ <version>${junit.version}</version>
+ <type>pom</type>
+ <scope>import</scope>
+ </dependency>
+
<!-- Transitive dependency of multiple dependencies -->
<!-- We fix a common version -->
<dependency>
@@ -125,7 +136,7 @@
<dependency>
<groupId>org.springframework.boot</groupId>
- <artifactId>spring-boot-starter-parent</artifactId>
+ <artifactId>spring-boot-dependencies</artifactId>
<version>${spring-boot.version}</version>
<type>pom</type>
<scope>import</scope>
@@ -196,9 +207,15 @@
</dependency>
<dependency>
- <groupId>org.junit</groupId>
- <artifactId>junit-bom</artifactId>
- <version>${junit.version}</version>
+ <groupId>org.hamcrest</groupId>
+ <artifactId>hamcrest</artifactId>
+ <version>${hamcrest.version}</version>
+ </dependency>
+
+ <dependency>
+ <groupId>javax.jms</groupId>
+ <artifactId>javax.jms-api</artifactId>
+ <version>${javax-jms.version}</version>
</dependency>
<dependency>