<?xml version="1.0" encoding="UTF-8"?>
<!-- 
 Copyright (c) 2008-2012 EBM WebSourcing, 2012-2020 Linagora

 This program/library is free software: you can redistribute it and/or modify
 it under the terms of the GNU Lesser General Public License as published by
 the Free Software Foundation, either version 2.1 of the License, or (at your
 option) any later version.

 This program/library is distributed in the hope that it will be useful, but
 WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
 for more details.

 You should have received a copy of the GNU Lesser General Public License
 along with this program/library; If not, see http://www.gnu.org/licenses/
 for the GNU Lesser General Public License version 2.1.
-->
<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">
  <modelVersion>4.0.0</modelVersion>

  <parent>
    <groupId>org.ow2.petals</groupId>
    <artifactId>petals-root-parent</artifactId>
    <version>21.0.0.2</version>
    <relativePath />
  </parent>

  <name>Petals ESB - Parent POM</name>
  <groupId>org.ow2.petals</groupId>
  <artifactId>petals-parent</artifactId>
  <packaging>pom</packaging>
  <version>20.2.8.2</version>
   
   <licenses>
      <license>
         <name>GNU LESSER GENERAL PUBLIC LICENSE Version 2.1</name>
         <url>http://www.gnu.org/licenses/old-licenses/lgpl-2.1.txt</url>
      </license>
   </licenses>

   <properties>
      <easycommons-lang.version>1.5.0</easycommons-lang.version>
      <easycommons-properties.version>1.3.0</easycommons-properties.version>
      <easycommons-io.version>1.3.0</easycommons-io.version>
      <easycommons-uuid.version>1.3.0</easycommons-uuid.version>
      <commons-pool.version>2.6.0</commons-pool.version>
      
      <slf4j.version>1.7.28</slf4j.version>
      
      <maven-enforcer-plugin.rules.bannedLogDependencies>true</maven-enforcer-plugin.rules.bannedLogDependencies>
   </properties>

   <dependencies>
      <dependency>
      <!-- Adding the dependency Junit forces developpers to write unit tests. If no unit test exists
           in project, an error is thrown because the junit dependency is declared and not used. -->
         <groupId>junit</groupId>
         <artifactId>junit</artifactId>
         <scope>test</scope>
      </dependency>
   </dependencies>

   <dependencyManagement>
      <dependencies>
         <!-- these dependencies are present in the
              bootstrap-loader so we fix their version here -->
         <dependency>
            <groupId>org.ow2.easycommons</groupId>
            <artifactId>easycommons-lang</artifactId>
            <version>${easycommons-lang.version}</version>
         </dependency>
         <dependency>
            <groupId>org.ow2.easycommons</groupId>
            <artifactId>easycommons-properties</artifactId>
            <version>${easycommons-properties.version}</version>
         </dependency>
         <dependency>
            <groupId>org.ow2.easycommons</groupId>
            <artifactId>easycommons-uuid</artifactId>
            <version>${easycommons-uuid.version}</version>
         </dependency>
         <dependency>
            <groupId>org.ow2.easycommons</groupId>
            <artifactId>easycommons-io</artifactId>
            <version>${easycommons-io.version}</version>
         </dependency>
         <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-pool2</artifactId>
            <version>${commons-pool.version}</version>
         </dependency>
         <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>${slf4j.version}</version>
         </dependency>
         <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-jdk14</artifactId>
            <version>${slf4j.version}</version>
         </dependency>
         <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>jcl-over-slf4j</artifactId>
            <version>${slf4j.version}</version>
         </dependency>
         <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>log4j-over-slf4j</artifactId>
            <version>${slf4j.version}</version>
         </dependency>
         <!-- Test framwork dependencies used in many places in Petals -->
         <dependency>
            <groupId>org.easymock</groupId>
            <artifactId>easymock</artifactId>
            <version>2.4</version>
            <scope>test</scope>
         </dependency>
         <dependency>
            <groupId>org.easymock</groupId>
            <artifactId>easymockclassextension</artifactId>
            <version>2.4</version>
            <scope>test</scope>
         </dependency>
         <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.12</version>
         </dependency>
         <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-core</artifactId>
            <version>1.10.19</version>
         </dependency>
         <dependency>
            <groupId>org.hamcrest</groupId>
            <artifactId>hamcrest-core</artifactId>
            <!-- Align version from junit with mockito-core -->
            <version>1.3</version>
         </dependency>
         <dependency>
            <groupId>com.github.stefanbirkner</groupId>
            <artifactId>system-rules</artifactId>
            <version>1.16.0</version>
            <scope>test</scope>
         </dependency>
         <dependency>
            <groupId>com.jayway.awaitility</groupId>
            <artifactId>awaitility</artifactId>
            <version>1.7.0</version>
            <scope>test</scope>
         </dependency>
      </dependencies>
   </dependencyManagement>

   <build>
      <plugins>
         <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-enforcer-plugin</artifactId>
            <version>1.4.1</version>
            <executions>
               <execution>
                  <id>enforce-slf4j-banned-deps</id>
                  <goals>
                     <goal>enforce</goal>
                  </goals>
                  <configuration>
                     <fail>${maven-enforcer-plugin.rules.bannedLogDependencies}</fail>
                     <rules>
                        <bannedDependencies>
                           <excludes>
                              <exclude>commons-logging:commons-logging</exclude>
                              <exclude>log4j:log4j</exclude>
                              <exclude>org.apache.logging.log4j:log4j</exclude>
                              <exclude>org.slf4j:jul-to-slf4j</exclude>
                              <exclude>org.slf4j:slf4j-jcl</exclude>
                              <exclude>org.slf4j:slf4j-log4j12</exclude>
                              <exclude>ch.qos.logback:logback-classic</exclude>
                              <exclude>ch.qos.logback:logback-core</exclude>
                           </excludes>
                           <message>These dependencies are handled by SLF4J and JUL: ignore them</message>
                        </bannedDependencies>
                     </rules>
                  </configuration>
               </execution>
            </executions>
         </plugin>
         <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-dependency-plugin</artifactId>
            <version>2.10</version>
            <executions>
               <execution>
                  <id>analyze</id>
                  <configuration>
                     <!-- this overrides the configuration from the parent pom, so we need to put all of them -->
                     <ignoredUnusedDeclaredDependencies>
                        <!-- That's often used at runtime and not used at compilation time -->
                        <ignoredUnusedDeclaredDependency>org.slf4j:slf4j-jdk14</ignoredUnusedDeclaredDependency>
                        <ignoredUnusedDeclaredDependency>org.slf4j:jcl-over-slf4j</ignoredUnusedDeclaredDependency>
                        <ignoredUnusedDeclaredDependency>org.slf4j:log4j-over-slf4j</ignoredUnusedDeclaredDependency>
                        <!-- Let's ignore that because it is used at runtime by surefire if jacoco is enabled -->
                        <ignoredUnusedDeclaredDependency>org.sonarsource.java:sonar-jacoco-listeners</ignoredUnusedDeclaredDependency>
                     </ignoredUnusedDeclaredDependencies>
                  </configuration>
               </execution>
            </executions>
         </plugin>
      </plugins>
   </build>
   
  <scm>
    <connection>scm:svn:https://svn.petalslink.org/svnroot/tags/petals-parent-20.2.8.2</connection>
    <developerConnection>scm:svn:https://svn.petalslink.org/svnroot/tags/petals-parent-20.2.8.2</developerConnection>
    <url>scm:svn:https://svn.petalslink.org/svnroot/tags/petals-parent-20.2.8.2</url>
  </scm>
</project>
