| <!-- |
| |
| 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/maven-v4_0_0.xsd"> |
| <modelVersion>4.0.0</modelVersion> |
| <groupId>org.apache.pegasus</groupId> |
| <artifactId>pegasus-client</artifactId> |
| <packaging>jar</packaging> |
| <version>2.4-SNAPSHOT</version> |
| <name>Pegasus Java Client</name> |
| |
| <licenses> |
| <license> |
| <name>Apache License, Version 2.0</name> |
| <url>https://www.apache.org/licenses/LICENSE-2.0.txt</url> |
| <distribution>repo</distribution> |
| </license> |
| </licenses> |
| |
| <developers> |
| <developer> |
| <organization>Apache Pegasus developers</organization> |
| <organizationUrl>https://pegasus.apache.org/</organizationUrl> |
| </developer> |
| </developers> |
| |
| <issueManagement> |
| <system>Github</system> |
| <url>https://github.com/apache/incubator-pegasus/issues</url> |
| </issueManagement> |
| |
| <dependencies> |
| <dependency> |
| <groupId>org.junit.jupiter</groupId> |
| <artifactId>junit-jupiter-engine</artifactId> |
| <version>5.3.2</version> |
| <scope>test</scope> |
| </dependency> |
| <dependency> |
| <groupId>org.junit.platform</groupId> |
| <artifactId>junit-platform-runner</artifactId> |
| <version>1.3.0</version> |
| <scope>test</scope> |
| </dependency> |
| <dependency> |
| <groupId>com.google.guava</groupId> |
| <artifactId>guava</artifactId> |
| <version>28.1-jre</version> |
| </dependency> |
| <dependency> |
| <groupId>org.mockito</groupId> |
| <artifactId>mockito-core</artifactId> |
| <version>2.24.5</version> |
| <scope>test</scope> |
| </dependency> |
| <dependency> |
| <groupId>io.dropwizard.metrics</groupId> |
| <artifactId>metrics-core</artifactId> |
| <version>3.1.2</version> |
| </dependency> |
| <dependency> |
| <groupId>org.apache.commons</groupId> |
| <artifactId>commons-configuration2</artifactId> |
| <version>2.7</version> |
| </dependency> |
| <dependency> |
| <groupId>org.slf4j</groupId> |
| <artifactId>slf4j-api</artifactId> |
| <version>1.7.2</version> |
| </dependency> |
| <dependency> |
| <groupId>org.apache.commons</groupId> |
| <artifactId>commons-lang3</artifactId> |
| <version>3.1</version> |
| </dependency> |
| <dependency> |
| <groupId>com.101tec</groupId> |
| <artifactId>zkclient</artifactId> |
| <version>0.2</version> |
| </dependency> |
| <!-- https://mvnrepository.com/artifact/io.netty/netty-buffer --> |
| <dependency> |
| <groupId>io.netty</groupId> |
| <artifactId>netty-buffer</artifactId> |
| <version>4.1.42.Final</version> |
| </dependency> |
| <!-- https://mvnrepository.com/artifact/io.netty/netty-transport --> |
| <dependency> |
| <groupId>io.netty</groupId> |
| <artifactId>netty-transport</artifactId> |
| <version>4.1.42.Final</version> |
| </dependency> |
| <!-- https://mvnrepository.com/artifact/io.netty/netty-codec --> |
| <dependency> |
| <groupId>io.netty</groupId> |
| <artifactId>netty-codec</artifactId> |
| <version>4.1.42.Final</version> |
| </dependency> |
| <!-- https://mvnrepository.com/artifact/io.netty/netty-codec-http --> |
| <dependency> |
| <groupId>io.netty</groupId> |
| <artifactId>netty-codec-http</artifactId> |
| <version>4.1.42.Final</version> |
| </dependency> |
| <dependency> |
| <groupId>org.json</groupId> |
| <artifactId>json</artifactId> |
| <version>20160810</version> |
| </dependency> |
| <dependency> |
| <groupId>com.github.luben</groupId> |
| <artifactId>zstd-jni</artifactId> |
| <version>1.3.7-1</version> |
| </dependency> |
| <dependency> |
| <groupId>org.apache.thrift</groupId> |
| <artifactId>libthrift</artifactId> |
| <version>0.11.0</version> |
| </dependency> |
| <dependency> |
| <groupId>javax.annotation</groupId> |
| <artifactId>javax.annotation-api</artifactId> |
| <version>1.3.2</version> |
| </dependency> |
| </dependencies> |
| <reporting> |
| <plugins> |
| <plugin> |
| <groupId>org.codehaus.mojo</groupId> |
| <artifactId>cobertura-maven-plugin</artifactId> |
| <version>2.7</version> |
| </plugin> |
| </plugins> |
| </reporting> |
| <properties> |
| <pegasus.shade.name>org.apache.pegasus.thirdparty</pegasus.shade.name> |
| </properties> |
| <build> |
| <sourceDirectory>${project.basedir}/src/main/java</sourceDirectory> |
| <testSourceDirectory>${project.basedir}/src/test/java</testSourceDirectory> |
| <directory>${project.basedir}/target</directory> |
| <outputDirectory>${project.basedir}/target/classes</outputDirectory> |
| <testOutputDirectory>${project.basedir}/target/test-classes</testOutputDirectory> |
| <plugins> |
| |
| <!--maven-shade-plugin--> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-shade-plugin</artifactId> |
| <version>3.2.4</version> |
| <executions> |
| <execution> |
| <phase>package</phase> |
| <goals> |
| <goal>shade</goal> |
| </goals> |
| <configuration> |
| <artifactSet> |
| <includes> |
| <include>com.101tec</include> |
| <include>com.google.guava</include> |
| <include>org.apache.thrift</include> |
| </includes> |
| </artifactSet> |
| <relocations> |
| <relocation> |
| <pattern>com.google</pattern> |
| <shadedPattern>${pegasus.shade.name}.com.google</shadedPattern> |
| </relocation> |
| <relocation> |
| <pattern>org.I0Itec</pattern> |
| <shadedPattern>${pegasus.shade.name}.org.I0Itec</shadedPattern> |
| </relocation> |
| <relocation> |
| <pattern>org.apache.thrift</pattern> |
| <shadedPattern>${pegasus.shade.name}.org.apache.thrift</shadedPattern> |
| </relocation> |
| </relocations> |
| </configuration> |
| </execution> |
| </executions> |
| </plugin> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-compiler-plugin</artifactId> |
| <version>3.5.1</version> |
| <configuration> |
| <source>1.8</source> |
| <target>1.8</target> |
| <fork>true</fork> |
| <verbose>true</verbose> |
| <encoding>UTF-8</encoding> |
| </configuration> |
| </plugin> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-surefire-plugin</artifactId> |
| <version>2.19.1</version> |
| <configuration> |
| <skipTests>${skipTests}</skipTests> |
| <additionalClasspathElements> |
| <additionalClasspathElement>${project.basedir}/configuration</additionalClasspathElement> |
| </additionalClasspathElements> |
| </configuration> |
| </plugin> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-dependency-plugin</artifactId> |
| <version>2.10</version> |
| <executions> |
| <execution> |
| <id>copy-dependencies</id> |
| <phase>package</phase> |
| <goals> |
| <goal>copy-dependencies</goal> |
| </goals> |
| <configuration> |
| <outputDirectory>${project.build.directory}/library</outputDirectory> |
| <excludeArtifactIds>gossip</excludeArtifactIds> |
| </configuration> |
| </execution> |
| </executions> |
| </plugin> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-assembly-plugin</artifactId> |
| <version>2.5.3</version> |
| <configuration> |
| <descriptor>src/assembly/dep.xml</descriptor> |
| </configuration> |
| <executions> |
| <execution> |
| <id>create-archive</id> |
| <phase>package</phase> |
| <goals> |
| <goal>single</goal> |
| </goals> |
| </execution> |
| </executions> |
| </plugin> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-jar-plugin</artifactId> |
| <version>3.2.0</version> |
| <configuration> |
| <archive> |
| <manifest> |
| <addDefaultImplementationEntries>true</addDefaultImplementationEntries> |
| </manifest> |
| </archive> |
| </configuration> |
| </plugin> |
| <plugin> |
| <groupId>org.apache.maven.plugins</groupId> |
| <artifactId>maven-source-plugin</artifactId> |
| <version>3.0.1</version> |
| <executions> |
| <execution> |
| <id>attach-sources</id> |
| <goals> |
| <goal>jar</goal> |
| </goals> |
| </execution> |
| </executions> |
| </plugin> |
| |
| <!-- Checkstyle --> |
| <plugin> |
| <artifactId>maven-checkstyle-plugin</artifactId> |
| <version>3.1.0</version> |
| <dependencies> |
| <dependency> |
| <groupId>com.puppycrawl.tools</groupId> |
| <artifactId>checkstyle</artifactId> |
| <version>8.29</version> |
| </dependency> |
| </dependencies> |
| <executions> |
| <execution> |
| <id>checkstyle</id> |
| <phase>validate</phase> |
| <configuration> |
| <configLocation>dev-support/google-checks.xml</configLocation> |
| <suppressionsLocation>dev-support/checkstyle-suppressions.xml</suppressionsLocation> |
| <encoding>UTF-8</encoding> |
| <consoleOutput>true</consoleOutput> |
| <failOnViolation>true</failOnViolation> |
| <violationSeverity>warning</violationSeverity> |
| <failsOnError>true</failsOnError> |
| <excludes> |
| org/apache/pegasus/apps/*, |
| org/apache/pegasus/base/*, |
| org/apache/pegasus/replication/*, |
| </excludes> |
| </configuration> |
| <goals> |
| <goal>check</goal> |
| </goals> |
| </execution> |
| </executions> |
| </plugin> |
| |
| <!-- FindBugs --> |
| <plugin> |
| <groupId>org.codehaus.mojo</groupId> |
| <artifactId>findbugs-maven-plugin</artifactId> |
| <version>3.0.4</version> |
| <configuration> |
| <excludeFilterFile>dev-support/findbugs-exclude.xml</excludeFilterFile> |
| <!-- |
| Enables analysis which takes more memory but finds more bugs. |
| If you run out of memory, changes the value of the effort element |
| to 'Low'. |
| --> |
| <effort>Max</effort> |
| <failOnError>true</failOnError> |
| <threshold>Low</threshold> |
| <findbugsXmlOutput>true</findbugsXmlOutput> |
| <xmlOutput>true</xmlOutput> |
| </configuration> |
| <executions> |
| <execution> |
| <id>findbugs</id> |
| <phase>validate</phase> |
| <goals> |
| <goal>check</goal> |
| </goals> |
| </execution> |
| </executions> |
| </plugin> |
| |
| <!--License Maven Plugin |
| mycila/license-maven-plugin provides a stricter license check compared to apache-rat. |
| But it's a convention to include apache-rat in apache projects. |
| This plugin is run on every PR by Github Action. |
| |
| Documentation: |
| https://github.com/mycila/license-maven-plugin |
| Check if source files have apache header: |
| mvn license:check |
| Reformat files if apache header is missing: |
| mvn license:format |
| --> |
| <plugin> |
| <groupId>com.mycila</groupId> |
| <artifactId>license-maven-plugin</artifactId> |
| <version>3.0</version> |
| <configuration> |
| <header>dev-support/license-header.txt</header> |
| <excludes> |
| <exclude>LICENSE</exclude> |
| <!--auto-generated by thrift compiler--> |
| <exclude>src/main/java/org/apache/pegasus/apps/*</exclude> |
| <exclude>src/main/java/org/apache/pegasus/replication/*</exclude> |
| |
| <!--TODO(wutao): fix all the following files--> |
| <exclude>dev-support/*</exclude> |
| <exclude>src/assembly/*</exclude> |
| <exclude>src/test/resource/pegasus.properties</exclude> |
| <exclude>src/test/java/org/apache/pegasus/client/*</exclude> |
| <exclude>src/test/java/org/apache/pegasus/operator/*</exclude> |
| <exclude>src/main/java/org/apache/pegasus/client/**</exclude> |
| <exclude>src/main/java/org/apache/pegasus/tools/*</exclude> |
| <exclude>src/main/java/org/apache/pegasus/operator/*</exclude> |
| <exclude>src/main/java/org/apache/pegasus/base/*</exclude> |
| <exclude>idl/*</exclude> |
| <exclude>configuration/*</exclude> |
| <exclude>dev-support/*</exclude> |
| </excludes> |
| |
| <mapping> |
| <java>SLASHSTAR_STYLE</java> |
| </mapping> |
| </configuration> |
| </plugin> |
| |
| <!--Apache Rat |
| Use Rat to improve accuracy and efficiency when checking releases for licenses. |
| Usage: |
| mvn apache-rat:check |
| # the result will be generated to ./target/rat.txt |
| --> |
| <plugin> |
| <groupId>org.apache.rat</groupId> |
| <artifactId>apache-rat-plugin</artifactId> |
| <version>0.13</version> |
| </plugin> |
| |
| <plugin> |
| <groupId>com.diffplug.spotless</groupId> |
| <artifactId>spotless-maven-plugin</artifactId> |
| <version>2.12.2</version> |
| <configuration> |
| <formats> |
| <format> |
| <includes> |
| <include>*.md</include> |
| <include>.gitignore</include> |
| </includes> |
| <trimTrailingWhitespace/> |
| <endWithNewline/> |
| <indent> |
| <tabs>true</tabs> |
| <spacesPerTab>4</spacesPerTab> |
| </indent> |
| </format> |
| </formats> |
| <java> |
| <excludes> |
| <exclude>src/main/java/org/apache/infra/pegasus/apps/*</exclude> |
| <exclude>src/main/java/org/apache/infra/pegasus/replication/*</exclude> |
| </excludes> |
| <googleJavaFormat> |
| <version>1.7</version> |
| <style>GOOGLE</style> |
| </googleJavaFormat> |
| </java> |
| </configuration> |
| <executions> |
| <execution> |
| <goals> |
| <goal>check</goal> |
| </goals> |
| <phase>compile</phase> |
| </execution> |
| </executions> |
| </plugin> |
| </plugins> |
| </build> |
| </project> |