mirror of https://github.com/tikv/client-java.git
350 lines
14 KiB
XML
350 lines
14 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<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>org.tikv</groupId>
|
|
<artifactId>tikv-client-java</artifactId>
|
|
<version>2.0-SNAPSHOT</version>
|
|
<packaging>jar</packaging>
|
|
<name>TiSpark Project TiKV Java Client</name>
|
|
|
|
<properties>
|
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
|
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
|
<protobuf.version>3.1.0</protobuf.version>
|
|
<log4j.version>1.2.17</log4j.version>
|
|
<slf4j.version>1.7.16</slf4j.version>
|
|
<grpc.version>1.7.0</grpc.version>
|
|
<powermock.version>1.6.6</powermock.version>
|
|
<jackson.version>2.8.11</jackson.version>
|
|
<jackson.databind.version>2.8.11.1</jackson.databind.version>
|
|
<trove4j.version>3.0.1</trove4j.version>
|
|
<joda-time.version>2.9.9</joda-time.version>
|
|
<joda-convert.version>1.9.2</joda-convert.version>
|
|
<proto.folder>${basedir}/proto</proto.folder>
|
|
<scala.binary.version>2.11</scala.binary.version>
|
|
<scala.version>2.11</scala.version>
|
|
<scalatest.version>3.0.4</scalatest.version>
|
|
<gpg.skip>true</gpg.skip>
|
|
<javadoc.skip>true</javadoc.skip>
|
|
</properties>
|
|
|
|
<dependencies>
|
|
<dependency>
|
|
<groupId>org.apache.commons</groupId>
|
|
<artifactId>commons-lang3</artifactId>
|
|
<version>3.5</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>log4j</groupId>
|
|
<artifactId>log4j</artifactId>
|
|
<version>${log4j.version}</version>
|
|
</dependency>
|
|
<!-- grpc dependencies -->
|
|
<dependency>
|
|
<groupId>io.grpc</groupId>
|
|
<artifactId>grpc-netty</artifactId>
|
|
<version>${grpc.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>io.grpc</groupId>
|
|
<artifactId>grpc-protobuf</artifactId>
|
|
<version>${grpc.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>io.grpc</groupId>
|
|
<artifactId>grpc-stub</artifactId>
|
|
<version>${grpc.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>io.grpc</groupId>
|
|
<artifactId>grpc-testing</artifactId>
|
|
<version>${grpc.version}</version>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>joda-time</groupId>
|
|
<artifactId>joda-time</artifactId>
|
|
<version>${joda-time.version}</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.joda</groupId>
|
|
<artifactId>joda-convert</artifactId>
|
|
<version>${joda-convert.version}</version>
|
|
</dependency>
|
|
<!-- https://mvnrepository.com/artifact/net.sf.trove4j/trove4j -->
|
|
<dependency>
|
|
<groupId>net.sf.trove4j</groupId>
|
|
<artifactId>trove4j</artifactId>
|
|
<version>${trove4j.version}</version>
|
|
</dependency>
|
|
</dependencies>
|
|
<build>
|
|
<resources>
|
|
<resource>
|
|
<directory>src/main/resources</directory>
|
|
</resource>
|
|
</resources>
|
|
<extensions>
|
|
<extension>
|
|
<groupId>kr.motd.maven</groupId>
|
|
<artifactId>os-maven-plugin</artifactId>
|
|
<version>1.4.1.Final</version>
|
|
</extension>
|
|
</extensions>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.codehaus.mojo</groupId>
|
|
<artifactId>exec-maven-plugin</artifactId>
|
|
<version>1.6.0</version>
|
|
<executions>
|
|
<execution>
|
|
<id>clone proto files</id>
|
|
<configuration>
|
|
<executable>${basedir}/scripts/proto.sh</executable>
|
|
</configuration>
|
|
<phase>validate</phase>
|
|
<goals>
|
|
<goal>exec</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
<plugin>
|
|
<artifactId>maven-resources-plugin</artifactId>
|
|
<version>2.5</version>
|
|
<executions>
|
|
<execution>
|
|
<id>copy-resources</id>
|
|
<phase>validate</phase>
|
|
<goals>
|
|
<goal>copy-resources</goal>
|
|
</goals>
|
|
<configuration>
|
|
<outputDirectory>${proto.folder}</outputDirectory>
|
|
<resources>
|
|
<resource>
|
|
<directory>${basedir}/kvproto/include</directory>
|
|
<includes>
|
|
<include>**/gogoproto/**</include>
|
|
</includes>
|
|
</resource>
|
|
<resource>
|
|
<directory>${basedir}/kvproto/include</directory>
|
|
<includes>
|
|
<include>*.proto</include>
|
|
</includes>
|
|
</resource>
|
|
<resource>
|
|
<directory>${basedir}/kvproto/proto</directory>
|
|
<filtering>true</filtering>
|
|
</resource>
|
|
<resource>
|
|
<directory>${basedir}/raft-rs/proto/proto</directory>
|
|
<filtering>true</filtering>
|
|
</resource>
|
|
<resource>
|
|
<directory>${basedir}/tipb/proto</directory>
|
|
<filtering>true</filtering>
|
|
</resource>
|
|
</resources>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
|
|
<plugin>
|
|
<groupId>org.xolstice.maven.plugins</groupId>
|
|
<artifactId>protobuf-maven-plugin</artifactId>
|
|
<version>0.5.0</version>
|
|
<configuration>
|
|
<protocArtifact>com.google.protobuf:protoc:${protobuf.version}:exe:${os.detected.classifier}</protocArtifact>
|
|
<protoSourceRoot>${proto.folder}</protoSourceRoot>
|
|
<includes>
|
|
<param>**/*.proto</param>
|
|
</includes>
|
|
<pluginId>grpc-java</pluginId>
|
|
<pluginArtifact>io.grpc:protoc-gen-grpc-java:1.4.0:exe:${os.detected.classifier}</pluginArtifact>
|
|
</configuration>
|
|
<executions>
|
|
<execution>
|
|
<goals>
|
|
<goal>compile</goal>
|
|
<goal>compile-custom</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
|
|
<!-- Compiler Plug-in -->
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-compiler-plugin</artifactId>
|
|
<version>3.7.0</version>
|
|
<configuration>
|
|
<source>1.8</source>
|
|
<target>1.8</target>
|
|
<encoding>UTF-8</encoding>
|
|
<showWarnings>true</showWarnings>
|
|
<showDeprecation>true</showDeprecation>
|
|
</configuration>
|
|
</plugin>
|
|
<!-- Jar Plug-in -->
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-jar-plugin</artifactId>
|
|
<version>3.0.2</version>
|
|
<configuration>
|
|
<archive>
|
|
<addMavenDescriptor>false</addMavenDescriptor>
|
|
</archive>
|
|
</configuration>
|
|
</plugin>
|
|
<!-- Source Plug-in -->
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-source-plugin</artifactId>
|
|
<version>3.0.1</version>
|
|
<executions>
|
|
<execution>
|
|
<id>attach-sources</id>
|
|
<phase>deploy</phase>
|
|
<goals>
|
|
<goal>jar-no-fork</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
<!-- Clean Plug-in -->
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-clean-plugin</artifactId>
|
|
<version>3.0.0</version>
|
|
<configuration>
|
|
<filesets>
|
|
<fileset>
|
|
<directory>${proto.folder}</directory>
|
|
</fileset>
|
|
</filesets>
|
|
</configuration>
|
|
</plugin>
|
|
<!-- Javadoc Plug-in -->
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-javadoc-plugin</artifactId>
|
|
<version>2.9.1</version>
|
|
<configuration>
|
|
<skip>${javadoc.skip}</skip>
|
|
</configuration>
|
|
<executions>
|
|
<execution>
|
|
<id>attach-javadocs</id>
|
|
<goals>
|
|
<goal>jar</goal>
|
|
</goals>
|
|
<configuration> <!-- add this to disable checking -->
|
|
<additionalparam>-Xdoclint:none</additionalparam>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
<!--GPG Signed Components-->
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-gpg-plugin</artifactId>
|
|
<version>1.5</version>
|
|
<configuration>
|
|
<keyname>Yifei Wu</keyname>
|
|
<skip>${gpg.skip}</skip>
|
|
</configuration>
|
|
<executions>
|
|
<execution>
|
|
<id>sign-artifacts</id>
|
|
<phase>verify</phase>
|
|
<goals>
|
|
<goal>sign</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
<!--- Needs to shade Protobuf 3 since other projects might use other version -->
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-shade-plugin</artifactId>
|
|
<version>3.1.0</version>
|
|
<executions>
|
|
<execution>
|
|
<phase>package</phase>
|
|
<goals>
|
|
<goal>shade</goal>
|
|
</goals>
|
|
<configuration>
|
|
<transformers>
|
|
<transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer"/>
|
|
</transformers>
|
|
<relocations>
|
|
<relocation>
|
|
<pattern>com.fasterxml</pattern>
|
|
<shadedPattern>shade.com.fasterxml.jackson</shadedPattern>
|
|
</relocation>
|
|
<relocation>
|
|
<pattern>io.grpc</pattern>
|
|
<shadedPattern>shade.io.grpc</shadedPattern>
|
|
</relocation>
|
|
<relocation>
|
|
<pattern>com.google.protobuf</pattern>
|
|
<shadedPattern>shade.com.google.protobuf</shadedPattern>
|
|
</relocation>
|
|
<relocation>
|
|
<pattern>io.netty</pattern>
|
|
<shadedPattern>shade.io.netty</shadedPattern>
|
|
</relocation>
|
|
<relocation>
|
|
<pattern>com.google.common</pattern>
|
|
<shadedPattern>shade.com.google.common</shadedPattern>
|
|
</relocation>
|
|
</relocations>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
<!-- Code coverage test -->
|
|
<plugin>
|
|
<groupId>org.codehaus.mojo</groupId>
|
|
<artifactId>cobertura-maven-plugin</artifactId>
|
|
<version>2.7</version>
|
|
<configuration>
|
|
<formats>
|
|
<format>html</format>
|
|
<format>xml</format>
|
|
</formats>
|
|
<check />
|
|
</configuration>
|
|
</plugin>
|
|
<!-- Google-java-format -->
|
|
<plugin>
|
|
<groupId>com.coveo</groupId>
|
|
<artifactId>fmt-maven-plugin</artifactId>
|
|
<version>2.6.0</version>
|
|
<configuration>
|
|
<sourceDirectory>src/main/java</sourceDirectory>
|
|
<testSourceDirectory>src/test/java</testSourceDirectory>
|
|
<verbose>true</verbose>
|
|
<filesNamePattern>.*\.java</filesNamePattern>
|
|
<skip>false</skip>
|
|
<skipSortingImports>false</skipSortingImports>
|
|
<style>google</style>
|
|
</configuration>
|
|
<executions>
|
|
<execution>
|
|
<goals>
|
|
<goal>format</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
</project>
|