<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~ 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 "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>

  <parent>
    <groupId>org.apache</groupId>
    <artifactId>apache</artifactId>
    <version>18</version>
  </parent>


  <groupId>org.apache.servicecomb</groupId>
  <artifactId>java-chassis</artifactId>
  <version>1.0.0-m1</version>
  <packaging>pom</packaging>

  <name>ServiceComb Java Chassis</name>
  <description>Software Development Kit (SDK) for rapid development of microservices</description>
  <url>https://github.com/apache/incubator-servicecomb-java-chassis</url>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  </properties>

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

  <mailingLists>
    <mailingList>
      <name>Development List</name>
      <subscribe>dev-subscribe@servicecomb.apache.org</subscribe>
      <unsubscribe>dev-unsubscribe@servicecomb.apache.org</unsubscribe>
      <post>dev@servicecomb.apache.org</post>
    </mailingList>
    <mailingList>
      <name>Commits List</name>
      <subscribe>commits-subscribe@servicecomb.apache.org</subscribe>
      <unsubscribe>commits-unsubscribe@servicecomb.apache.org</unsubscribe>
      <post>commits@servicecomb.apache.org</post>
    </mailingList>
  </mailingLists>

  <developers>
    <developer>
      <name>The ServiceComb Developer Team</name>
      <email>dev@servicecomb.apache.org</email>
    </developer>
  </developers>

  <issueManagement>
    <system>jira</system>
    <url>https://issues.apache.org/jira/browse/SCB</url>
  </issueManagement>

  <organization>
    <name>The Apache Software Foundation</name>
    <url>http://www.apache.org/</url>
  </organization>

  <inceptionYear>2017</inceptionYear>

  <scm>
    <url>https://github.com/apache/incubator-servicecomb-java-chassis</url>
    <connection>scm:git:https://github.com/apache/incubator-servicecomb-java-chassis.git</connection>
    <developerConnection>scm:git:https://github.com/apache/incubator-servicecomb-java-chassis.git</developerConnection>
    <tag>v${project.version}</tag>
  </scm>

  <modules>
    <module>parent</module>
    <module>java-chassis-dependencies</module>
    <module>common</module>
    <module>foundations</module>
    <module>handlers</module>
    <module>providers</module>
    <module>transports</module>
    <module>swagger</module>
    <module>core</module>
    <module>service-registry</module>
    <module>spring-boot-starter</module>
    <module>tracing</module>
    <module>edge</module>
    <module>metrics</module>
    <module>dynamic-config</module>
  </modules>

  <profiles>
    <profile>
      <id>release</id>
      <build>
        <plugins>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-deploy-plugin</artifactId>
        </plugin>
	      <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <version>1.6</version>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <version>2.2.1</version>
            <executions>
              <execution>
                <id>attach-sources</id>
                <goals>
                  <goal>jar-no-fork</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-javadoc-plugin</artifactId>
            <version>2.9.1</version>
            <executions>
              <execution>
                <id>attach-javadocs</id>
                <goals>
                  <goal>jar</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-release-plugin</artifactId>
            <version>2.5.3</version>
            <configuration>
              <autoVersionSubmodules>true</autoVersionSubmodules>
              <useReleaseProfile>false</useReleaseProfile>
              <releaseProfiles>release</releaseProfiles>
              <goals>deploy</goals>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>it</id>
      <modules>
        <module>demo</module>
        <module>integration-tests</module>
      </modules>
    </profile>
    <profile>
      <id>distribution</id>
      <modules>
        <module>java-chassis-distribution</module>
      </modules>
    </profile>
    <profile>
      <id>coverage</id>
      <modules>
        <module>coverage-reports</module>
      </modules>
    </profile>
    <profile>
      <id>samples</id>
      <modules>
        <module>samples</module>
      </modules>
    </profile>
  </profiles>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.rat</groupId>
        <artifactId>apache-rat-plugin</artifactId>
        <configuration>
          <excludes>
            <exclude>DISCLAIMER</exclude>
            <exclude>.travis.yml</exclude>
            <exclude>**/*.md</exclude>
            <excldue>**/*.MD</excldue>
            <exclude>**/target/*</exclude>
            <!-- Skip the code style configuration file -->
            <exclude>**/etc/eclipse-java-google-style.xml</exclude>
            <exclude>**/etc/intellij-java-google-style.xml</exclude>
            <!-- Skip the ssl configuration files -->
            <exculde>**/resources/ssl/**</exculde>
            <!-- SKip the licenses files -->
            <exclude>**/src/release/licenses/**</exclude>
            <!-- Skip the demo log files -->
            <exclude>**/logs/**.log</exclude>
            <!-- Skip the source files which are forked from vertx -->
            <exclude>**/io/vertx/ext/web/impl/MimeTypesUtils.java</exclude>
            <exclude>**/java/org/apache/servicecomb/transport/rest/vertx/RestBodyHandler.java</exclude>
          </excludes>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>exec-maven-plugin</artifactId>
        <version>1.2.1</version>
        <executions>
          <execution>
            <goals>
              <goal>java</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <configuration>
          <skip>${maven.test.skip}</skip>
          <testFailureIgnore>${maven.test.failure.ignore}</testFailureIgnore>
          <excludes>
            <exclude>${excludesFile}</exclude>
          </excludes>
          <forkCount>2</forkCount>
          <reuseForks>true</reuseForks>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>findbugs-maven-plugin</artifactId>
        <version>3.0.1</version>
        <configuration>
          <findbugsXmlOutput>true</findbugsXmlOutput>
          <findbugsXmlWithMessages>true</findbugsXmlWithMessages>
          <xmlOutput>true</xmlOutput>
          <excludeFilterFile>findbugs-exclude.xml</excludeFilterFile>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <configuration>
          <archive>
            <manifest>
              <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
              <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
            </manifest>
          </archive>
        </configuration>
      </plugin>
    </plugins>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.eluder.coveralls</groupId>
          <artifactId>coveralls-maven-plugin</artifactId>
          <version>4.3.0</version>
          <configuration>
            <jacocoReports>
              <jacocoReport>${project.basedir}/coverage-reports/target/site/jacoco-aggregate/jacoco.xml</jacocoReport>
            </jacocoReports>
          </configuration>
        </plugin>
      </plugins>
    </pluginManagement>
  </build>
</project>
