pom.xml 9.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288
  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. https://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.5.0-SNAPSHOT</version>
  22. </parent>
  23. <artifactId>hadoop-hdds-common</artifactId>
  24. <version>0.5.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.5.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>org.apache.hadoop</groupId>
  37. <artifactId>hadoop-hdds-config</artifactId>
  38. </dependency>
  39. <dependency>
  40. <groupId>javax.annotation</groupId>
  41. <artifactId>javax.annotation-api</artifactId>
  42. <version>1.2</version>
  43. </dependency>
  44. <dependency>
  45. <groupId>org.fusesource.leveldbjni</groupId>
  46. <artifactId>leveldbjni-all</artifactId>
  47. </dependency>
  48. <dependency>
  49. <artifactId>ratis-server</artifactId>
  50. <groupId>org.apache.ratis</groupId>
  51. <exclusions>
  52. <exclusion>
  53. <groupId>org.slf4j</groupId>
  54. <artifactId>slf4j-log4j12</artifactId>
  55. </exclusion>
  56. <exclusion>
  57. <groupId>io.dropwizard.metrics</groupId>
  58. <artifactId>metrics-core</artifactId>
  59. </exclusion>
  60. <exclusion>
  61. <groupId>org.bouncycastle</groupId>
  62. <artifactId>bcprov-jdk15on</artifactId>
  63. </exclusion>
  64. </exclusions>
  65. </dependency>
  66. <dependency>
  67. <artifactId>ratis-netty</artifactId>
  68. <groupId>org.apache.ratis</groupId>
  69. </dependency>
  70. <dependency>
  71. <artifactId>ratis-grpc</artifactId>
  72. <groupId>org.apache.ratis</groupId>
  73. </dependency>
  74. <dependency>
  75. <groupId>com.google.errorprone</groupId>
  76. <artifactId>error_prone_annotations</artifactId>
  77. <version>2.2.0</version>
  78. <optional>true</optional>
  79. </dependency>
  80. <dependency>
  81. <groupId>org.rocksdb</groupId>
  82. <artifactId>rocksdbjni</artifactId>
  83. <version>6.0.1</version>
  84. </dependency>
  85. <dependency>
  86. <groupId>org.apache.hadoop</groupId>
  87. <artifactId>hadoop-common</artifactId>
  88. <scope>test</scope>
  89. <type>test-jar</type>
  90. </dependency>
  91. <dependency>
  92. <groupId>org.apache.logging.log4j</groupId>
  93. <artifactId>log4j-api</artifactId>
  94. <version>${log4j2.version}</version>
  95. </dependency>
  96. <dependency>
  97. <groupId>org.apache.logging.log4j</groupId>
  98. <artifactId>log4j-core</artifactId>
  99. <version>${log4j2.version}</version>
  100. </dependency>
  101. <dependency>
  102. <groupId>com.lmax</groupId>
  103. <artifactId>disruptor</artifactId>
  104. <version>${disruptor.version}</version>
  105. </dependency>
  106. <dependency>
  107. <groupId>org.apache.commons</groupId>
  108. <artifactId>commons-pool2</artifactId>
  109. <version>2.6.0</version>
  110. </dependency>
  111. <dependency>
  112. <groupId>org.bouncycastle</groupId>
  113. <artifactId>bcpkix-jdk15on</artifactId>
  114. <version>${bouncycastle.version}</version>
  115. </dependency>
  116. <!-- https://mvnrepository.com/artifact/commons-validator/commons-validator -->
  117. <dependency>
  118. <groupId>commons-validator</groupId>
  119. <artifactId>commons-validator</artifactId>
  120. <version>1.6</version>
  121. </dependency>
  122. <dependency>
  123. <groupId>org.junit.jupiter</groupId>
  124. <artifactId>junit-jupiter-api</artifactId>
  125. </dependency>
  126. <dependency>
  127. <groupId>io.jaegertracing</groupId>
  128. <artifactId>jaeger-client</artifactId>
  129. <version>0.33.1</version>
  130. </dependency>
  131. <dependency>
  132. <groupId>io.opentracing</groupId>
  133. <artifactId>opentracing-util</artifactId>
  134. <version>0.31.0</version>
  135. </dependency>
  136. <dependency>
  137. <groupId>org.yaml</groupId>
  138. <artifactId>snakeyaml</artifactId>
  139. <version>1.16</version>
  140. </dependency>
  141. </dependencies>
  142. <build>
  143. <resources>
  144. <resource>
  145. <directory>${basedir}/src/main/resources</directory>
  146. <excludes>
  147. <exclude>hdds-version-info.properties</exclude>
  148. </excludes>
  149. <filtering>false</filtering>
  150. </resource>
  151. <resource>
  152. <directory>${basedir}/src/main/resources</directory>
  153. <includes>
  154. <include>hdds-version-info.properties</include>
  155. </includes>
  156. <filtering>true</filtering>
  157. </resource>
  158. </resources>
  159. <extensions>
  160. <extension>
  161. <groupId>kr.motd.maven</groupId>
  162. <artifactId>os-maven-plugin</artifactId>
  163. <version>${os-maven-plugin.version}</version>
  164. </extension>
  165. </extensions>
  166. <plugins>
  167. <plugin>
  168. <groupId>org.xolstice.maven.plugins</groupId>
  169. <artifactId>protobuf-maven-plugin</artifactId>
  170. <version>${protobuf-maven-plugin.version}</version>
  171. <extensions>true</extensions>
  172. <configuration>
  173. <protocArtifact>
  174. com.google.protobuf:protoc:${protobuf-compile.version}:exe:${os.detected.classifier}
  175. </protocArtifact>
  176. <protoSourceRoot>${basedir}/src/main/proto/</protoSourceRoot>
  177. <includes>
  178. <include>DatanodeContainerProtocol.proto</include>
  179. </includes>
  180. <outputDirectory>target/generated-sources/java</outputDirectory>
  181. <clearOutputDirectory>false</clearOutputDirectory>
  182. </configuration>
  183. <executions>
  184. <execution>
  185. <id>compile-protoc</id>
  186. <goals>
  187. <goal>compile</goal>
  188. <goal>test-compile</goal>
  189. <goal>compile-custom</goal>
  190. <goal>test-compile-custom</goal>
  191. </goals>
  192. <configuration>
  193. <pluginId>grpc-java</pluginId>
  194. <pluginArtifact>
  195. io.grpc:protoc-gen-grpc-java:${grpc.version}:exe:${os.detected.classifier}
  196. </pluginArtifact>
  197. </configuration>
  198. </execution>
  199. </executions>
  200. </plugin>
  201. <plugin>
  202. <artifactId>maven-antrun-plugin</artifactId>
  203. <executions>
  204. <execution>
  205. <phase>generate-sources</phase>
  206. <configuration>
  207. <tasks>
  208. <replace token="com.google.protobuf" value="org.apache.ratis.thirdparty.com.google.protobuf"
  209. dir="target/generated-sources/java/org/apache/hadoop/hdds/protocol/datanode/proto">
  210. </replace>
  211. <replace token="io.grpc" value="org.apache.ratis.thirdparty.io.grpc"
  212. dir="target/generated-sources/java/org/apache/hadoop/hdds/protocol/datanode/proto">
  213. </replace>
  214. </tasks>
  215. </configuration>
  216. <goals>
  217. <goal>run</goal>
  218. </goals>
  219. </execution>
  220. </executions>
  221. </plugin>
  222. <plugin>
  223. <groupId>org.apache.hadoop</groupId>
  224. <artifactId>hadoop-maven-plugins</artifactId>
  225. <executions>
  226. <execution>
  227. <id>version-info</id>
  228. <phase>generate-resources</phase>
  229. <goals>
  230. <goal>version-info</goal>
  231. </goals>
  232. <configuration>
  233. <source>
  234. <directory>${basedir}/../</directory>
  235. <includes>
  236. <include>*/src/main/java/**/*.java</include>
  237. <include>*/src/main/proto/*.proto</include>
  238. </includes>
  239. </source>
  240. </configuration>
  241. </execution>
  242. <execution>
  243. <id>compile-protoc</id>
  244. <goals>
  245. <goal>protoc</goal>
  246. </goals>
  247. <configuration>
  248. <protocVersion>${protobuf.version}</protocVersion>
  249. <protocCommand>${protoc.path}</protocCommand>
  250. <imports>
  251. <param>
  252. ${basedir}/../../hadoop-common-project/hadoop-common/src/main/proto
  253. </param>
  254. <param>${basedir}/src/main/proto</param>
  255. </imports>
  256. <source>
  257. <directory>${basedir}/src/main/proto</directory>
  258. <includes>
  259. <include>StorageContainerLocationProtocol.proto</include>
  260. <include>hdds.proto</include>
  261. <include>ScmBlockLocationProtocol.proto</include>
  262. <include>SCMSecurityProtocol.proto</include>
  263. </includes>
  264. </source>
  265. </configuration>
  266. </execution>
  267. </executions>
  268. </plugin>
  269. <plugin>
  270. <groupId>org.codehaus.mojo</groupId>
  271. <artifactId>findbugs-maven-plugin</artifactId>
  272. <configuration>
  273. <excludeFilterFile>${basedir}/dev-support/findbugsExcludeFile.xml</excludeFilterFile>
  274. </configuration>
  275. </plugin>
  276. </plugins>
  277. </build>
  278. </project>