<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~ Copyright 2014 Groupon.com
  ~
  ~ Licensed 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
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License.
  -->
<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>

  <groupId>com.arpnetworking.logback</groupId>
  <artifactId>logback-steno</artifactId>
  <packaging>jar</packaging>
  <name>logback-steno</name>
  <description>A logback encoder for the steno format</description>
  <url>https://github.com/arpnetworking/logback-steno</url>
  <version>1.9.2</version>

  <licenses>
    <license>
      <name>Apache License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
      <distribution>repo</distribution>
      <comments>A business-friendly OSS license</comments>
    </license>
  </licenses>

  <developers>
    <developer>
      <id>gil</id>
      <name>Gil Markham</name>
      <email>gil@groupon.com</email>
      <organization>Groupon</organization>
      <organizationUrl>http://www.groupon.com</organizationUrl>
      <roles>
        <role>developer</role>
      </roles>
    </developer>
    <developer>
      <id>fsiegrist</id>
      <name>Stuart Siegrist</name>
      <email>fsiegrist@groupon.com</email>
      <organization>Groupon</organization>
      <organizationUrl>http://www.groupon.com</organizationUrl>
      <roles>
        <role>developer</role>
      </roles>
    </developer>
    <developer>
      <id>tmack</id>
      <name>Trevor Mack</name>
      <email>tmack@groupon.com</email>
      <organization>Groupon</organization>
      <organizationUrl>http://www.groupon.com</organizationUrl>
      <roles>
        <role>developer</role>
      </roles>
    </developer>
    <developer>
      <id>vkoskela</id>
      <name>Ville Koskela</name>
      <email>vkoskela@groupon.com</email>
      <organization>Groupon</organization>
      <organizationUrl>http://www.groupon.com</organizationUrl>
      <roles>
        <role>developer</role>
      </roles>
    </developer>
    <developer>
      <id>barp</id>
      <name>Brandon Arp</name>
      <email>barp@groupon.com</email>
      <organization>Groupon</organization>
      <organizationUrl>http://www.groupon.com</organizationUrl>
      <roles>
        <role>developer</role>
      </roles>
    </developer>
  </developers>

  <properties>
    <maven.compiler.source>1.8</maven.compiler.source>
    <maven.compiler.target>1.8</maven.compiler.target>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <maven.test.skip>false</maven.test.skip>
    <gpg.skip>true</gpg.skip>

    <!--Dependency versions-->
    <build-resources.version>1.0.3</build-resources.version>
    <slf4j.version>1.7.10</slf4j.version>
    <logback.version>1.1.3</logback.version>
    <jackson.version>2.5.3</jackson.version>
    <afterburner.version>2.5.1</afterburner.version>
    <aspectjrt.version>1.8.5</aspectjrt.version>
    <aspectjtools.version>1.8.5</aspectjtools.version>
    <junit.version>4.12</junit.version>
    <mockito.version>1.10.19</mockito.version>
    <findbugs.annotations.version>3.0.0</findbugs.annotations.version>
    <apache.commons.lang3.version>3.4</apache.commons.lang3.version>
    <json-schema-validator.version>2.2.6</json-schema-validator.version>

    <!--Plugin versions-->
    <maven.compiler.plugin.version>3.2</maven.compiler.plugin.version>
    <aspectj.maven.plugin.version>1.7</aspectj.maven.plugin.version>
    <maven.source.plugin.version>2.4</maven.source.plugin.version>
    <maven.surefire.plugin.version>2.18.1</maven.surefire.plugin.version>
    <maven.javadoc.plugin.version>2.10.1</maven.javadoc.plugin.version>
    <maven.resources.plugin.version>2.7</maven.resources.plugin.version>
    <maven.checkstyle.plugin.version>2.15</maven.checkstyle.plugin.version>
    <maven.findbugs.plugin.version>3.0.1</maven.findbugs.plugin.version>
    <maven.jacoco.plugin.version>0.7.4.201502262128</maven.jacoco.plugin.version>
    <maven.gpg.plugin.version>1.6</maven.gpg.plugin.version>
    <maven.release.plugin.version>2.5</maven.release.plugin.version>
  </properties>

  <scm>
    <connection>scm:git:git@github.com:arpnetworking/logback-steno.git</connection>
    <developerConnection>scm:git:git@github.com:arpnetworking/logback-steno.git</developerConnection>
    <url>https://github.com/arpnetworking/logback-steno</url>
    <tag>logback-steno-1.9.2</tag>
  </scm>

  <dependencies>
    <dependency>
      <groupId>ch.qos.logback</groupId>
      <artifactId>logback-classic</artifactId>
      <version>${logback.version}</version>
    </dependency>
    <dependency>
      <groupId>ch.qos.logback</groupId>
      <artifactId>logback-core</artifactId>
      <version>${logback.version}</version>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <version>${slf4j.version}</version>
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-core</artifactId>
      <version>${jackson.version}</version>
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-databind</artifactId>
      <version>${jackson.version}</version>
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.module</groupId>
      <artifactId>jackson-module-afterburner</artifactId>
      <version>${afterburner.version}</version>
    </dependency>
    <dependency>
      <groupId>org.aspectj</groupId>
      <artifactId>aspectjrt</artifactId>
      <version>${aspectjrt.version}</version>
    </dependency>

    <!-- Test dependencies -->
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>${junit.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-all</artifactId>
      <version>${mockito.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.google.code.findbugs</groupId>
      <artifactId>annotations</artifactId>
      <version>${findbugs.annotations.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.github.fge</groupId>
      <artifactId>json-schema-validator</artifactId>
      <version>${json-schema-validator.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.datatype</groupId>
      <artifactId>jackson-datatype-jsr310</artifactId>
      <version>${jackson.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.commons</groupId>
      <artifactId>commons-lang3</artifactId>
      <version>${apache.commons.lang3.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.jacoco</groupId>
      <artifactId>org.jacoco.agent</artifactId>
      <classifier>runtime</classifier>
      <version>${maven.jacoco.plugin.version}</version>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <plugin>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>${maven.compiler.plugin.version}</version>
        <configuration>
          <source>${maven.compiler.source}</source>
          <target>${maven.compiler.target}</target>
          <showDeprecation>true</showDeprecation>
          <showWarnings>true</showWarnings>
          <compilerArgs>
            <arg>-Werror</arg>
            <arg>-Xlint:all</arg>
          </compilerArgs>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>aspectj-maven-plugin</artifactId>
        <version>${aspectj.maven.plugin.version}</version>
        <executions>
          <execution>
            <goals>
              <goal>compile</goal>
              <goal>test-compile</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <source>${maven.compiler.source}</source>
          <target>${maven.compiler.target}</target>
          <complianceLevel>1.8</complianceLevel>
          <showWeaveInfo>true</showWeaveInfo>
          <testSources>
            <scanner implementation="org.codehaus.plexus.util.DirectoryScanner">
              <basedir>${basedir}</basedir>
              <includes>
                <include>
                  src/test/java/com/arpnetworking/steno/aspect/**/*
                </include>
              </includes>
            </scanner>
          </testSources>
          <sources>
            <scanner implementation="org.codehaus.plexus.util.DirectoryScanner">
              <basedir>${basedir}/src/main/aspect</basedir>
              <includes>
                <include>
                  **/*
                </include>
              </includes>
            </scanner>
          </sources>
          <warn>constructorName,packageDefaultMethod,deprecation,maskedCatchBlocks,unusedImports</warn>
        </configuration>
        <dependencies>
          <dependency>
            <groupId>org.aspectj</groupId>
            <artifactId>aspectjtools</artifactId>
            <version>${aspectjtools.version}</version>
          </dependency>
        </dependencies>
      </plugin>
      <plugin>
        <artifactId>maven-source-plugin</artifactId>
        <version>${maven.source.plugin.version}</version>
        <executions>
          <execution>
            <id>bind-sources</id>
            <goals>
              <goal>jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <artifactId>maven-surefire-plugin</artifactId>
        <version>${maven.surefire.plugin.version}</version>
        <configuration>
          <systemPropertyVariables>
            <jacoco-agent.destfile>target/jacoco.exec</jacoco-agent.destfile>
          </systemPropertyVariables>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>${maven.javadoc.plugin.version}</version>
        <executions>
          <execution>
            <goals>
              <goal>jar</goal>
              <goal>javadoc</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>findbugs-maven-plugin</artifactId>
        <version>${maven.findbugs.plugin.version}</version>
        <executions>
          <execution>
            <id>findbugs-check</id>
            <phase>verify</phase>
            <goals>
              <goal>check</goal>
              <goal>findbugs</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <skip>${maven.test.skip}</skip>
          <effort>Max</effort>
          <threshold>Low</threshold>
          <includeTests>true</includeTests>
          <failOnError>true</failOnError>
          <xmlOutput>true</xmlOutput>
          <xmlOutputDirectory>${project.build.directory}</xmlOutputDirectory>
          <excludeFilterFile>${project.basedir}/findbugs.exclude.xml</excludeFilterFile>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-checkstyle-plugin</artifactId>
        <version>${maven.checkstyle.plugin.version}</version>
        <executions>
          <execution>
            <id>checkstyle-check</id>
            <phase>verify</phase>
            <goals>
              <goal>checkstyle</goal>
              <goal>checkstyle-aggregate</goal>
              <goal>check</goal>
            </goals>
            <configuration>
              <skip>${maven.test.skip}</skip>
              <consoleOutput>true</consoleOutput>
              <logViolationsToConsole>true</logViolationsToConsole>
              <failOnViolation>true</failOnViolation>
              <maxAllowedViolations>0</maxAllowedViolations>
              <configLocation>build/checkstyle.xml</configLocation>
              <includeTestSourceDirectory>true</includeTestSourceDirectory>
              <propertyExpansion>samedir=${project.basedir}/build</propertyExpansion>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.jacoco</groupId>
        <artifactId>jacoco-maven-plugin</artifactId>
        <version>${maven.jacoco.plugin.version}</version>
        <executions>
          <execution>
            <id>default-instrument</id>
            <goals>
              <goal>instrument</goal>
            </goals>
          </execution>
          <execution>
            <id>default-restore-instrumented-classes</id>
            <goals>
              <goal>restore-instrumented-classes</goal>
            </goals>
          </execution>
          <execution>
            <id>default-report</id>
            <phase>prepare-package</phase>
            <goals>
              <goal>report</goal>
            </goals>
          </execution>
          <execution>
            <id>default-check</id>
            <goals>
              <goal>check</goal>
            </goals>
            <configuration>
              <rules>
                <rule>
                  <element>BUNDLE</element>
                  <limits>
                    <limit>
                      <counter>COMPLEXITY</counter>
                      <value>COVEREDRATIO</value>
                      <minimum>1.0</minimum>
                    </limit>
                  </limits>
                </rule>
              </rules>
              <excludes>
                <exclude>com/arpnetworking/steno/aspect/**</exclude>
              </excludes>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-gpg-plugin</artifactId>
        <version>${maven.gpg.plugin.version}</version>
        <executions>
          <execution>
            <id>sign-artifacts</id>
            <phase>verify</phase>
            <goals>
              <goal>sign</goal>
            </goals>
            <configuration>
              <keyname>arpnet</keyname>
              <passphraseServerId>arpnet</passphraseServerId>
              <skip>${gpg.skip}</skip>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-release-plugin</artifactId>
        <version>${maven.release.plugin.version}</version>
      </plugin>
    </plugins>
  </build>
  <distributionManagement>
    <snapshotRepository>
      <id>ossrh</id>
      <url>https://oss.sonatype.org/content/repositories/snapshots</url>
    </snapshotRepository>
    <repository>
      <id>ossrh</id>
      <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
    </repository>
  </distributionManagement>
</project>
