1 <?xml version="1.0" encoding="UTF-8"?> 2 3 <!-- 4 ~ Licensed to the Apache Software Foundation (ASF) under one or more 5 ~ contributor license agreements. See the NOTICE file distributed with 6 ~ this work for additional information regarding copyright ownership. 7 ~ The ASF licenses this file to You under the Apache license, Version 2.0 8 ~ (the "License"); you may not use this file except in compliance with 9 ~ the License. You may obtain a copy of the License at 10 ~ 11 ~ http://www.apache.org/licenses/LICENSE-2.0 12 ~ 13 ~ Unless required by applicable law or agreed to in writing, software 14 ~ distributed under the License is distributed on an "AS IS" BASIS, 15 ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16 ~ See the license for the specific language governing permissions and 17 ~ limitations under the license. 18 --> 19 <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/maven-v4_0_0.xsd"> 20 <modelVersion>4.0.0</modelVersion> 21 <parent> 22 <groupId>org.apache.logging.log4j</groupId> 23 <artifactId>log4j</artifactId> 24 <version>2.5</version> 25 <relativePath>../</relativePath> 26 </parent> 27 <artifactId>log4j-core</artifactId> 28 <packaging>jar</packaging> 29 <name>Apache Log4j Core</name> 30 <description>The Apache Log4j Implementation</description> 31 <properties> 32 <log4jParentDir>${basedir}/..</log4jParentDir> 33 <docLabel>Core Documentation</docLabel> 34 <projectDir>/core</projectDir> 35 </properties> 36 <dependencies> 37 <!-- Naturally, all implementations require the log4j-api JAR --> 38 <dependency> 39 <groupId>org.apache.logging.log4j</groupId> 40 <artifactId>log4j-api</artifactId> 41 </dependency> 42 <!-- Used for OSGi bundle support --> 43 <dependency> 44 <groupId>org.osgi</groupId> 45 <artifactId>org.osgi.core</artifactId> 46 <scope>provided</scope> 47 </dependency> 48 <!-- Required for AsyncLoggers --> 49 <dependency> 50 <groupId>com.lmax</groupId> 51 <artifactId>disruptor</artifactId> 52 <optional>true</optional> 53 </dependency> 54 <!-- Required for JSON support --> 55 <dependency> 56 <groupId>com.fasterxml.jackson.core</groupId> 57 <artifactId>jackson-core</artifactId> 58 <optional>true</optional> 59 </dependency> 60 <!-- Required for JSON support --> 61 <dependency> 62 <groupId>com.fasterxml.jackson.core</groupId> 63 <artifactId>jackson-databind</artifactId> 64 <optional>true</optional> 65 </dependency> 66 <!-- Required for YAML support (including JSON requirements) --> 67 <dependency> 68 <groupId>com.fasterxml.jackson.dataformat</groupId> 69 <artifactId>jackson-dataformat-yaml</artifactId> 70 <optional>true</optional> 71 </dependency> 72 <!-- Required for XML layout and receiver support --> 73 <dependency> 74 <groupId>com.fasterxml.jackson.dataformat</groupId> 75 <artifactId>jackson-dataformat-xml</artifactId> 76 <optional>true</optional> 77 </dependency> 78 <!-- POM for jackson-dataformat-xml 2.5.4 depends on woodstox-core-asl 4.3.0 --> 79 <dependency> 80 <groupId>org.codehaus.woodstox</groupId> 81 <artifactId>woodstox-core-asl</artifactId> 82 <version>4.3.0</version> 83 <optional>true</optional> 84 </dependency> 85 <!-- Required for console color support in Windows --> 86 <dependency> 87 <groupId>org.fusesource.jansi</groupId> 88 <artifactId>jansi</artifactId> 89 <optional>true</optional> 90 </dependency> 91 <!-- Required for SMTPAppender --> 92 <dependency> 93 <groupId>com.sun.mail</groupId> 94 <artifactId>javax.mail</artifactId> 95 <optional>true</optional> 96 </dependency> 97 <!-- Used for JPA appenders (needs an implementation of course) --> 98 <dependency> 99 <groupId>org.eclipse.persistence</groupId> 100 <artifactId>javax.persistence</artifactId> 101 <scope>compile</scope> 102 <optional>true</optional> 103 </dependency> 104 <!-- Used for JMS appenders (needs an implementation of course) --> 105 <dependency> 106 <groupId>org.jboss.spec.javax.jms</groupId> 107 <artifactId>jboss-jms-api_1.1_spec</artifactId> 108 <scope>provided</scope> 109 <optional>true</optional> 110 </dependency> 111 <!-- Used for Kafka appender --> 112 <dependency> 113 <groupId>org.apache.kafka</groupId> 114 <artifactId>kafka-clients</artifactId> 115 <optional>true</optional> 116 </dependency> 117 <!-- Used for ZeroMQ JeroMQ appender --> 118 <dependency> 119 <groupId>org.zeromq</groupId> 120 <artifactId>jeromq</artifactId> 121 <optional>true</optional> 122 </dependency> 123 <!-- Used for compressing to formats other than zip and gz --> 124 <dependency> 125 <groupId>org.apache.commons</groupId> 126 <artifactId>commons-compress</artifactId> 127 <optional>true</optional> 128 </dependency> 129 <!-- Used for the CSV layout --> 130 <dependency> 131 <groupId>org.apache.commons</groupId> 132 <artifactId>commons-csv</artifactId> 133 <optional>true</optional> 134 </dependency> 135 136 <!-- TEST DEPENDENCIES --> 137 138 <!-- Pull in useful test classes from API --> 139 <dependency> 140 <groupId>org.apache.logging.log4j</groupId> 141 <artifactId>log4j-api</artifactId> 142 <type>test-jar</type> 143 <scope>test</scope> 144 </dependency> 145 <!-- Zeroconf advertiser tests --> 146 <dependency> 147 <groupId>javax.jmdns</groupId> 148 <artifactId>jmdns</artifactId> 149 <version>3.4.1</version> 150 <scope>test</scope> 151 </dependency> 152 <!-- Log4j 1.2 tests --> 153 <dependency> 154 <groupId>log4j</groupId> 155 <artifactId>log4j</artifactId> 156 <version>1.2.17</version> 157 <scope>test</scope> 158 </dependency> 159 <!-- SLF4J tests --> 160 <dependency> 161 <groupId>org.slf4j</groupId> 162 <artifactId>slf4j-api</artifactId> 163 <scope>test</scope> 164 </dependency> 165 <dependency> 166 <groupId>org.slf4j</groupId> 167 <artifactId>slf4j-ext</artifactId> 168 <scope>test</scope> 169 </dependency> 170 <!-- JUnit, naturally --> 171 <dependency> 172 <groupId>junit</groupId> 173 <artifactId>junit</artifactId> 174 <scope>test</scope> 175 </dependency> 176 <dependency> 177 <groupId>org.hamcrest</groupId> 178 <artifactId>hamcrest-all</artifactId> 179 <scope>test</scope> 180 </dependency> 181 <!-- Mocking framework for use with JUnit --> 182 <dependency> 183 <groupId>org.easymock</groupId> 184 <artifactId>easymock</artifactId> 185 <scope>test</scope> 186 </dependency> 187 <!-- Embedded JDBC drivers for database appender tests --> 188 <dependency> 189 <groupId>org.hsqldb</groupId> 190 <artifactId>hsqldb</artifactId> 191 <scope>test</scope> 192 </dependency> 193 <dependency> 194 <groupId>com.h2database</groupId> 195 <artifactId>h2</artifactId> 196 <scope>test</scope> 197 </dependency> 198 <!-- JPA Tests --> 199 <dependency> 200 <groupId>org.eclipse.persistence</groupId> 201 <artifactId>org.eclipse.persistence.jpa</artifactId> 202 <scope>test</scope> 203 </dependency> 204 <!-- JNDI and JMS tests --> 205 <dependency> 206 <groupId>org.mockejb</groupId> 207 <artifactId>mockejb</artifactId> 208 <scope>test</scope> 209 </dependency> 210 <dependency> 211 <groupId>org.apache.activemq</groupId> 212 <artifactId>activemq-broker</artifactId> 213 <scope>test</scope> 214 </dependency> 215 <dependency> 216 <groupId>commons-logging</groupId> 217 <artifactId>commons-logging</artifactId> 218 <scope>test</scope> 219 </dependency> 220 <!-- Logback performance tests --> 221 <dependency> 222 <groupId>ch.qos.logback</groupId> 223 <artifactId>logback-core</artifactId> 224 <scope>test</scope> 225 </dependency> 226 <dependency> 227 <groupId>ch.qos.logback</groupId> 228 <artifactId>logback-classic</artifactId> 229 <scope>test</scope> 230 </dependency> 231 <!-- OSGi tests --> 232 <dependency> 233 <groupId>org.eclipse.osgi</groupId> 234 <artifactId>org.eclipse.osgi</artifactId> 235 <scope>test</scope> 236 </dependency> 237 <dependency> 238 <groupId>org.apache.felix</groupId> 239 <artifactId>org.apache.felix.framework</artifactId> 240 <scope>test</scope> 241 </dependency> 242 <!-- GELF --> 243 <dependency> 244 <groupId>net.javacrumbs.json-unit</groupId> 245 <artifactId>json-unit</artifactId> 246 <scope>test</scope> 247 </dependency> 248 <dependency> 249 <groupId>commons-io</groupId> 250 <artifactId>commons-io</artifactId> 251 <scope>test</scope> 252 </dependency> 253 <!-- Other --> 254 <dependency> 255 <groupId>commons-codec</groupId> 256 <artifactId>commons-codec</artifactId> 257 <scope>test</scope> 258 </dependency> 259 <dependency> 260 <groupId>org.apache.commons</groupId> 261 <artifactId>commons-lang3</artifactId> 262 <scope>test</scope> 263 </dependency> 264 <dependency> 265 <groupId>org.apache-extras.beanshell</groupId> 266 <artifactId>bsh</artifactId> 267 <version>2.0b5</version> 268 <scope>test</scope> 269 </dependency> 270 <dependency> 271 <groupId>org.codehaus.groovy</groupId> 272 <artifactId>groovy-all</artifactId> 273 <version>2.4.5</version> 274 <scope>test</scope> 275 </dependency> 276 </dependencies> 277 <build> 278 <plugins> 279 <plugin> 280 <artifactId>maven-compiler-plugin</artifactId> 281 <version>${compiler.plugin.version}</version> 282 <executions> 283 <execution> 284 <!-- disable annotation processing for first pass --> 285 <id>default-compile</id> 286 <goals> 287 <goal>compile</goal> 288 </goals> 289 <phase>compile</phase> 290 <configuration> 291 <proc>none</proc> 292 </configuration> 293 </execution> 294 <execution> 295 <!-- then do a processing-only pass to generate plugins .dat file --> 296 <id>process-plugins</id> 297 <goals> 298 <goal>compile</goal> 299 </goals> 300 <phase>process-classes</phase> 301 <configuration> 302 <proc>only</proc> 303 </configuration> 304 </execution> 305 </executions> 306 </plugin> 307 <plugin> 308 <artifactId>maven-surefire-plugin</artifactId> 309 <configuration> 310 <excludedGroups> 311 org.apache.logging.log4j.categories.PerformanceTests 312 </excludedGroups> 313 <forkCount>1</forkCount> 314 <reuseForks>false</reuseForks> 315 </configuration> 316 </plugin> 317 <plugin> 318 <groupId>org.apache.maven.plugins</groupId> 319 <artifactId>maven-failsafe-plugin</artifactId> 320 <configuration> 321 <includes> 322 <include>**/*.java</include> 323 </includes> 324 <excludes> 325 <exclude>**/ForceNoDefClassFoundError.*</exclude> 326 </excludes> 327 <groups> 328 org.apache.logging.log4j.categories.PerformanceTests 329 </groups> 330 </configuration> 331 </plugin> 332 <plugin> 333 <groupId>org.apache.maven.plugins</groupId> 334 <artifactId>maven-jar-plugin</artifactId> 335 <executions> 336 <execution> 337 <goals> 338 <goal>test-jar</goal> 339 </goals> 340 </execution> 341 </executions> 342 </plugin> 343 <plugin> 344 <groupId>org.apache.felix</groupId> 345 <artifactId>maven-bundle-plugin</artifactId> 346 <configuration> 347 <instructions> 348 <Bundle-SymbolicName>org.apache.logging.log4j.core</Bundle-SymbolicName> 349 <!-- TODO: exclude internal classes from export --> 350 <Export-Package>org.apache.logging.log4j.core.*</Export-Package> 351 <Import-Package> 352 sun.reflect;resolution:=optional, 353 * 354 </Import-Package> 355 <Bundle-Activator>org.apache.logging.log4j.core.osgi.Activator</Bundle-Activator> 356 </instructions> 357 </configuration> 358 </plugin> 359 </plugins> 360 </build> 361 <reporting> 362 <plugins> 363 <plugin> 364 <groupId>org.apache.maven.plugins</groupId> 365 <artifactId>maven-changes-plugin</artifactId> 366 <version>${changes.plugin.version}</version> 367 <reportSets> 368 <reportSet> 369 <reports> 370 <report>changes-report</report> 371 </reports> 372 </reportSet> 373 </reportSets> 374 <configuration> 375 <issueLinkTemplate>%URL%/show_bug.cgi?id=%ISSUE%</issueLinkTemplate> 376 <useJql>true</useJql> 377 </configuration> 378 </plugin> 379 <plugin> 380 <groupId>org.apache.maven.plugins</groupId> 381 <artifactId>maven-checkstyle-plugin</artifactId> 382 <version>${checkstyle.plugin.version}</version> 383 <configuration> 384 <!--<propertiesLocation>${vfs.parent.dir}/checkstyle.properties</propertiesLocation> --> 385 <configLocation>${log4jParentDir}/checkstyle.xml</configLocation> 386 <suppressionsLocation>${log4jParentDir}/checkstyle-suppressions.xml</suppressionsLocation> 387 <enableRulesSummary>false</enableRulesSummary> 388 <propertyExpansion>basedir=${basedir}</propertyExpansion> 389 <propertyExpansion>licensedir=${log4jParentDir}/checkstyle-header.txt</propertyExpansion> 390 </configuration> 391 </plugin> 392 <plugin> 393 <groupId>org.apache.maven.plugins</groupId> 394 <artifactId>maven-javadoc-plugin</artifactId> 395 <version>${javadoc.plugin.version}</version> 396 <configuration> 397 <bottom><![CDATA[<p align="center">Copyright © {inceptionYear}-{currentYear} {organizationName}. All Rights Reserved.<br /> 398 Apache Logging, Apache Log4j, Log4j, Apache, the Apache feather logo, the Apache Logging project logo, 399 and the Apache Log4j logo are trademarks of The Apache Software Foundation.</p>]]></bottom> 400 <!-- module link generation is completely broken in the javadoc plugin for a multi-module non-aggregating 401 project --> 402 <detectOfflineLinks>false</detectOfflineLinks> 403 <linksource>true</linksource> 404 <links> 405 <link>http://docs.oracle.com/javaee/6/api/</link> 406 <link>http://www.osgi.org/javadoc/r4v43/core/</link> 407 <link>https://commons.apache.org/proper/commons-lang/javadocs/api-release/</link> 408 </links> 409 <groups> 410 <group> 411 <title>Core API</title> 412 <packages>org.apache.logging.log4j.core</packages> 413 </group> 414 <group> 415 <title>Configuration</title> 416 <packages>org.apache.logging.log4j.core.config*:org.apache.logging.log4j.core.selector</packages> 417 </group> 418 <group> 419 <title>Core Plugins</title> 420 <packages>org.apache.logging.log4j.core.appender*:org.apache.logging.log4j.core.filter:org.apache.logging.log4j.core.layout:org.apache.logging.log4j.core.lookup:org.apache.logging.log4j.core.pattern</packages> 421 </group> 422 <group> 423 <title>Tools</title> 424 <packages>org.apache.logging.log4j.core.net*:org.apache.logging.log4j.core.tools</packages> 425 </group> 426 <group> 427 <title>Internals</title> 428 <packages>org.apache.logging.log4j.core.async:org.apache.logging.log4j.core.impl:org.apache.logging.log4j.core.util:org.apache.logging.log4j.core.osgi:org.apache.logging.log4j.core.jackson:org.apache.logging.log4j.core.jmx</packages> 429 </group> 430 </groups> 431 </configuration> 432 <reportSets> 433 <reportSet> 434 <id>non-aggregate</id> 435 <reports> 436 <report>javadoc</report> 437 </reports> 438 </reportSet> 439 </reportSets> 440 </plugin> 441 <plugin> 442 <groupId>org.codehaus.mojo</groupId> 443 <artifactId>findbugs-maven-plugin</artifactId> 444 <version>${findbugs.plugin.version}</version> 445 <configuration> 446 <fork>true</fork> 447 <jvmArgs>-Duser.language=en</jvmArgs> 448 <threshold>Normal</threshold> 449 <effort>Default</effort> 450 <excludeFilterFile>${log4jParentDir}/findbugs-exclude-filter.xml</excludeFilterFile> 451 </configuration> 452 </plugin> 453 <plugin> 454 <groupId>org.apache.maven.plugins</groupId> 455 <artifactId>maven-jxr-plugin</artifactId> 456 <version>${jxr.plugin.version}</version> 457 <reportSets> 458 <reportSet> 459 <id>non-aggregate</id> 460 <reports> 461 <report>jxr</report> 462 </reports> 463 </reportSet> 464 <reportSet> 465 <id>aggregate</id> 466 <reports> 467 <report>aggregate</report> 468 </reports> 469 </reportSet> 470 </reportSets> 471 </plugin> 472 <plugin> 473 <groupId>org.apache.maven.plugins</groupId> 474 <artifactId>maven-pmd-plugin</artifactId> 475 <version>${pmd.plugin.version}</version> 476 <configuration> 477 <targetJdk>${maven.compile.target}</targetJdk> 478 </configuration> 479 </plugin> 480 </plugins> 481 </reporting> 482 </project> 483 484