pom.xml 9.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!--
  3. Licensed under the Apache License, Version 2.0 (the "License");
  4. you may not use this file except in compliance with the License.
  5. You may obtain a copy of the License at
  6. http://www.apache.org/licenses/LICENSE-2.0
  7. Unless required by applicable law or agreed to in writing, software
  8. distributed under the License is distributed on an "AS IS" BASIS,
  9. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  10. See the License for the specific language governing permissions and
  11. limitations under the License. See accompanying LICENSE file.
  12. -->
  13. <project xmlns="http://maven.apache.org/POM/4.0.0"
  14. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  15. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
  16. http://maven.apache.org/xsd/maven-4.0.0.xsd">
  17. <modelVersion>4.0.0</modelVersion>
  18. <parent>
  19. <groupId>org.apache.hadoop</groupId>
  20. <artifactId>hadoop-hdds</artifactId>
  21. <version>0.4.0-SNAPSHOT</version>
  22. </parent>
  23. <artifactId>hadoop-hdds-common</artifactId>
  24. <version>0.4.0-SNAPSHOT</version>
  25. <description>Apache Hadoop Distributed Data Store Common</description>
  26. <name>Apache Hadoop HDDS Common</name>
  27. <packaging>jar</packaging>
  28. <properties>
  29. <hdds.version>0.4.0-SNAPSHOT</hdds.version>
  30. <log4j2.version>2.11.0</log4j2.version>
  31. <disruptor.version>3.4.2</disruptor.version>
  32. <declared.hdds.version>${hdds.version}</declared.hdds.version>
  33. </properties>
  34. <dependencies>
  35. <dependency>
  36. <groupId>javax.annotation</groupId>
  37. <artifactId>javax.annotation-api</artifactId>
  38. <version>1.2</version>
  39. </dependency>
  40. <dependency>
  41. <groupId>org.fusesource.leveldbjni</groupId>
  42. <artifactId>leveldbjni-all</artifactId>
  43. </dependency>
  44. <dependency>
  45. <artifactId>ratis-server</artifactId>
  46. <groupId>org.apache.ratis</groupId>
  47. <exclusions>
  48. <exclusion>
  49. <groupId>org.slf4j</groupId>
  50. <artifactId>slf4j-log4j12</artifactId>
  51. </exclusion>
  52. <exclusion>
  53. <groupId>io.dropwizard.metrics</groupId>
  54. <artifactId>metrics-core</artifactId>
  55. </exclusion>
  56. <exclusion>
  57. <groupId>org.bouncycastle</groupId>
  58. <artifactId>bcprov-jdk15on</artifactId>
  59. </exclusion>
  60. </exclusions>
  61. </dependency>
  62. <dependency>
  63. <artifactId>ratis-netty</artifactId>
  64. <groupId>org.apache.ratis</groupId>
  65. </dependency>
  66. <dependency>
  67. <artifactId>ratis-grpc</artifactId>
  68. <groupId>org.apache.ratis</groupId>
  69. </dependency>
  70. <dependency>
  71. <groupId>com.google.errorprone</groupId>
  72. <artifactId>error_prone_annotations</artifactId>
  73. <version>2.2.0</version>
  74. <optional>true</optional>
  75. </dependency>
  76. <dependency>
  77. <groupId>org.rocksdb</groupId>
  78. <artifactId>rocksdbjni</artifactId>
  79. <version>5.14.2</version>
  80. </dependency>
  81. <dependency>
  82. <groupId>org.apache.hadoop</groupId>
  83. <artifactId>hadoop-common</artifactId>
  84. <scope>test</scope>
  85. <type>test-jar</type>
  86. </dependency>
  87. <dependency>
  88. <groupId>org.apache.logging.log4j</groupId>
  89. <artifactId>log4j-api</artifactId>
  90. <version>${log4j2.version}</version>
  91. </dependency>
  92. <dependency>
  93. <groupId>org.apache.logging.log4j</groupId>
  94. <artifactId>log4j-core</artifactId>
  95. <version>${log4j2.version}</version>
  96. </dependency>
  97. <dependency>
  98. <groupId>com.lmax</groupId>
  99. <artifactId>disruptor</artifactId>
  100. <version>${disruptor.version}</version>
  101. </dependency>
  102. <dependency>
  103. <groupId>org.apache.commons</groupId>
  104. <artifactId>commons-pool2</artifactId>
  105. <version>2.6.0</version>
  106. </dependency>
  107. <dependency>
  108. <groupId>org.bouncycastle</groupId>
  109. <artifactId>bcpkix-jdk15on</artifactId>
  110. <version>${bouncycastle.version}</version>
  111. </dependency>
  112. <!-- https://mvnrepository.com/artifact/commons-validator/commons-validator -->
  113. <dependency>
  114. <groupId>commons-validator</groupId>
  115. <artifactId>commons-validator</artifactId>
  116. <version>1.6</version>
  117. </dependency>
  118. <dependency>
  119. <groupId>org.junit.jupiter</groupId>
  120. <artifactId>junit-jupiter-api</artifactId>
  121. </dependency>
  122. <dependency>
  123. <groupId>io.jaegertracing</groupId>
  124. <artifactId>jaeger-client</artifactId>
  125. <version>0.33.1</version>
  126. </dependency>
  127. <dependency>
  128. <groupId>io.opentracing</groupId>
  129. <artifactId>opentracing-util</artifactId>
  130. <version>0.31.0</version>
  131. </dependency>
  132. </dependencies>
  133. <build>
  134. <resources>
  135. <resource>
  136. <directory>${basedir}/src/main/resources</directory>
  137. <excludes>
  138. <exclude>hdds-version-info.properties</exclude>
  139. </excludes>
  140. <filtering>false</filtering>
  141. </resource>
  142. <resource>
  143. <directory>${basedir}/src/main/resources</directory>
  144. <includes>
  145. <include>hdds-version-info.properties</include>
  146. </includes>
  147. <filtering>true</filtering>
  148. </resource>
  149. </resources>
  150. <extensions>
  151. <extension>
  152. <groupId>kr.motd.maven</groupId>
  153. <artifactId>os-maven-plugin</artifactId>
  154. <version>${os-maven-plugin.version}</version>
  155. </extension>
  156. </extensions>
  157. <plugins>
  158. <plugin>
  159. <groupId>org.xolstice.maven.plugins</groupId>
  160. <artifactId>protobuf-maven-plugin</artifactId>
  161. <version>${protobuf-maven-plugin.version}</version>
  162. <extensions>true</extensions>
  163. <configuration>
  164. <protocArtifact>
  165. com.google.protobuf:protoc:${protobuf-compile.version}:exe:${os.detected.classifier}
  166. </protocArtifact>
  167. <protoSourceRoot>${basedir}/src/main/proto/</protoSourceRoot>
  168. <includes>
  169. <include>DatanodeContainerProtocol.proto</include>
  170. </includes>
  171. <outputDirectory>target/generated-sources/java</outputDirectory>
  172. <clearOutputDirectory>false</clearOutputDirectory>
  173. </configuration>
  174. <executions>
  175. <execution>
  176. <id>compile-protoc</id>
  177. <goals>
  178. <goal>compile</goal>
  179. <goal>test-compile</goal>
  180. <goal>compile-custom</goal>
  181. <goal>test-compile-custom</goal>
  182. </goals>
  183. <configuration>
  184. <pluginId>grpc-java</pluginId>
  185. <pluginArtifact>
  186. io.grpc:protoc-gen-grpc-java:${grpc.version}:exe:${os.detected.classifier}
  187. </pluginArtifact>
  188. </configuration>
  189. </execution>
  190. </executions>
  191. </plugin>
  192. <plugin>
  193. <artifactId>maven-antrun-plugin</artifactId>
  194. <executions>
  195. <execution>
  196. <phase>generate-sources</phase>
  197. <configuration>
  198. <tasks>
  199. <replace token="com.google.protobuf" value="org.apache.ratis.thirdparty.com.google.protobuf"
  200. dir="target/generated-sources/java/org/apache/hadoop/hdds/protocol/datanode/proto">
  201. </replace>
  202. <replace token="io.grpc" value="org.apache.ratis.thirdparty.io.grpc"
  203. dir="target/generated-sources/java/org/apache/hadoop/hdds/protocol/datanode/proto">
  204. </replace>
  205. </tasks>
  206. </configuration>
  207. <goals>
  208. <goal>run</goal>
  209. </goals>
  210. </execution>
  211. </executions>
  212. </plugin>
  213. <plugin>
  214. <groupId>org.apache.hadoop</groupId>
  215. <artifactId>hadoop-maven-plugins</artifactId>
  216. <executions>
  217. <execution>
  218. <id>version-info</id>
  219. <phase>generate-resources</phase>
  220. <goals>
  221. <goal>version-info</goal>
  222. </goals>
  223. <configuration>
  224. <source>
  225. <directory>${basedir}/../</directory>
  226. <includes>
  227. <include>*/src/main/java/**/*.java</include>
  228. <include>*/src/main/proto/*.proto</include>
  229. </includes>
  230. </source>
  231. </configuration>
  232. </execution>
  233. <execution>
  234. <id>compile-protoc</id>
  235. <goals>
  236. <goal>protoc</goal>
  237. </goals>
  238. <configuration>
  239. <protocVersion>${protobuf.version}</protocVersion>
  240. <protocCommand>${protoc.path}</protocCommand>
  241. <imports>
  242. <param>
  243. ${basedir}/../../hadoop-common-project/hadoop-common/src/main/proto
  244. </param>
  245. <param>${basedir}/src/main/proto</param>
  246. </imports>
  247. <source>
  248. <directory>${basedir}/src/main/proto</directory>
  249. <includes>
  250. <include>StorageContainerLocationProtocol.proto</include>
  251. <include>hdds.proto</include>
  252. <include>ScmBlockLocationProtocol.proto</include>
  253. <include>SCMSecurityProtocol.proto</include>
  254. </includes>
  255. </source>
  256. </configuration>
  257. </execution>
  258. </executions>
  259. </plugin>
  260. <plugin>
  261. <groupId>org.codehaus.mojo</groupId>
  262. <artifactId>findbugs-maven-plugin</artifactId>
  263. <configuration>
  264. <excludeFilterFile>${basedir}/dev-support/findbugsExcludeFile.xml</excludeFilterFile>
  265. </configuration>
  266. </plugin>
  267. </plugins>
  268. </build>
  269. </project>