pom.xml 41 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148
  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-project-dist</artifactId>
  21. <version>3.3.2-SNAPSHOT</version>
  22. <relativePath>../../hadoop-project-dist</relativePath>
  23. </parent>
  24. <artifactId>hadoop-common</artifactId>
  25. <version>3.3.2-SNAPSHOT</version>
  26. <description>Apache Hadoop Common</description>
  27. <name>Apache Hadoop Common</name>
  28. <packaging>jar</packaging>
  29. <properties>
  30. <hadoop.component>common</hadoop.component>
  31. <is.hadoop.component>true</is.hadoop.component>
  32. <is.hadoop.common.component>true</is.hadoop.common.component>
  33. <wsce.config.dir>../etc/hadoop</wsce.config.dir>
  34. <wsce.config.file>wsce-site.xml</wsce.config.file>
  35. </properties>
  36. <dependencies>
  37. <dependency>
  38. <groupId>org.apache.hadoop.thirdparty</groupId>
  39. <artifactId>hadoop-shaded-protobuf_3_7</artifactId>
  40. </dependency>
  41. <dependency>
  42. <groupId>org.apache.hadoop</groupId>
  43. <artifactId>hadoop-annotations</artifactId>
  44. <scope>compile</scope>
  45. </dependency>
  46. <dependency>
  47. <groupId>org.apache.hadoop.thirdparty</groupId>
  48. <artifactId>hadoop-shaded-guava</artifactId>
  49. </dependency>
  50. <!--Guava is required during runtime for curator-->
  51. <dependency>
  52. <groupId>com.google.guava</groupId>
  53. <artifactId>guava</artifactId>
  54. <scope>compile</scope>
  55. </dependency>
  56. <dependency>
  57. <groupId>commons-cli</groupId>
  58. <artifactId>commons-cli</artifactId>
  59. <scope>compile</scope>
  60. </dependency>
  61. <dependency>
  62. <groupId>org.apache.commons</groupId>
  63. <artifactId>commons-math3</artifactId>
  64. <scope>compile</scope>
  65. </dependency>
  66. <dependency>
  67. <groupId>org.apache.httpcomponents</groupId>
  68. <artifactId>httpclient</artifactId>
  69. <scope>compile</scope>
  70. </dependency>
  71. <dependency>
  72. <groupId>commons-codec</groupId>
  73. <artifactId>commons-codec</artifactId>
  74. <scope>compile</scope>
  75. </dependency>
  76. <dependency>
  77. <groupId>commons-io</groupId>
  78. <artifactId>commons-io</artifactId>
  79. <scope>compile</scope>
  80. </dependency>
  81. <dependency>
  82. <groupId>commons-net</groupId>
  83. <artifactId>commons-net</artifactId>
  84. <scope>compile</scope>
  85. </dependency>
  86. <dependency>
  87. <groupId>commons-collections</groupId>
  88. <artifactId>commons-collections</artifactId>
  89. <scope>compile</scope>
  90. </dependency>
  91. <dependency>
  92. <groupId>javax.servlet</groupId>
  93. <artifactId>javax.servlet-api</artifactId>
  94. <scope>compile</scope>
  95. </dependency>
  96. <dependency>
  97. <groupId>jakarta.activation</groupId>
  98. <artifactId>jakarta.activation-api</artifactId>
  99. <scope>runtime</scope>
  100. </dependency>
  101. <dependency>
  102. <groupId>org.eclipse.jetty</groupId>
  103. <artifactId>jetty-server</artifactId>
  104. <scope>compile</scope>
  105. </dependency>
  106. <dependency>
  107. <groupId>org.eclipse.jetty</groupId>
  108. <artifactId>jetty-util</artifactId>
  109. <scope>compile</scope>
  110. </dependency>
  111. <dependency>
  112. <groupId>org.eclipse.jetty</groupId>
  113. <artifactId>jetty-servlet</artifactId>
  114. <scope>compile</scope>
  115. </dependency>
  116. <dependency>
  117. <groupId>org.eclipse.jetty</groupId>
  118. <artifactId>jetty-webapp</artifactId>
  119. <scope>compile</scope>
  120. </dependency>
  121. <dependency>
  122. <groupId>org.eclipse.jetty</groupId>
  123. <artifactId>jetty-util-ajax</artifactId>
  124. <scope>test</scope>
  125. </dependency>
  126. <dependency>
  127. <groupId>javax.servlet.jsp</groupId>
  128. <artifactId>jsp-api</artifactId>
  129. <scope>runtime</scope>
  130. </dependency>
  131. <dependency>
  132. <groupId>com.sun.jersey</groupId>
  133. <artifactId>jersey-core</artifactId>
  134. <scope>compile</scope>
  135. </dependency>
  136. <dependency>
  137. <groupId>com.sun.jersey</groupId>
  138. <artifactId>jersey-servlet</artifactId>
  139. <scope>compile</scope>
  140. </dependency>
  141. <dependency>
  142. <!-- Used, even though 'mvn dependency:analyze' doesn't find it -->
  143. <groupId>com.sun.jersey</groupId>
  144. <artifactId>jersey-json</artifactId>
  145. <scope>compile</scope>
  146. </dependency>
  147. <dependency>
  148. <groupId>com.sun.jersey</groupId>
  149. <artifactId>jersey-server</artifactId>
  150. <scope>compile</scope>
  151. </dependency>
  152. <dependency>
  153. <groupId>commons-logging</groupId>
  154. <artifactId>commons-logging</artifactId>
  155. <scope>compile</scope>
  156. </dependency>
  157. <dependency>
  158. <groupId>log4j</groupId>
  159. <artifactId>log4j</artifactId>
  160. <scope>compile</scope>
  161. </dependency>
  162. <dependency>
  163. <groupId>junit</groupId>
  164. <artifactId>junit</artifactId>
  165. <scope>test</scope>
  166. </dependency>
  167. <dependency>
  168. <groupId>org.assertj</groupId>
  169. <artifactId>assertj-core</artifactId>
  170. <scope>test</scope>
  171. </dependency>
  172. <dependency>
  173. <groupId>org.glassfish.grizzly</groupId>
  174. <artifactId>grizzly-http-servlet</artifactId>
  175. <scope>test</scope>
  176. </dependency>
  177. <dependency>
  178. <groupId>commons-beanutils</groupId>
  179. <artifactId>commons-beanutils</artifactId>
  180. <scope>compile</scope>
  181. </dependency>
  182. <dependency>
  183. <groupId>org.apache.commons</groupId>
  184. <artifactId>commons-configuration2</artifactId>
  185. <scope>compile</scope>
  186. </dependency>
  187. <dependency>
  188. <groupId>org.apache.commons</groupId>
  189. <artifactId>commons-lang3</artifactId>
  190. <scope>compile</scope>
  191. </dependency>
  192. <dependency>
  193. <groupId>org.apache.commons</groupId>
  194. <artifactId>commons-text</artifactId>
  195. <scope>compile</scope>
  196. </dependency>
  197. <dependency>
  198. <groupId>org.slf4j</groupId>
  199. <artifactId>slf4j-api</artifactId>
  200. <scope>compile</scope>
  201. </dependency>
  202. <dependency>
  203. <groupId>org.slf4j</groupId>
  204. <artifactId>slf4j-log4j12</artifactId>
  205. <scope>compile</scope>
  206. </dependency>
  207. <dependency>
  208. <groupId>org.mockito</groupId>
  209. <artifactId>mockito-core</artifactId>
  210. <scope>test</scope>
  211. </dependency>
  212. <dependency>
  213. <groupId>org.apache.avro</groupId>
  214. <artifactId>avro</artifactId>
  215. <scope>compile</scope>
  216. </dependency>
  217. <dependency>
  218. <groupId>org.apache.ant</groupId>
  219. <artifactId>ant</artifactId>
  220. <scope>test</scope>
  221. </dependency>
  222. <dependency>
  223. <groupId>com.google.re2j</groupId>
  224. <artifactId>re2j</artifactId>
  225. <scope>compile</scope>
  226. </dependency>
  227. <dependency>
  228. <groupId>com.google.protobuf</groupId>
  229. <artifactId>protobuf-java</artifactId>
  230. <scope>compile</scope>
  231. </dependency>
  232. <dependency>
  233. <groupId>com.google.code.gson</groupId>
  234. <artifactId>gson</artifactId>
  235. </dependency>
  236. <dependency>
  237. <groupId>org.apache.hadoop</groupId>
  238. <artifactId>hadoop-auth</artifactId>
  239. <scope>compile</scope>
  240. </dependency>
  241. <dependency>
  242. <groupId>org.apache.hadoop</groupId>
  243. <artifactId>hadoop-auth</artifactId>
  244. <type>test-jar</type>
  245. <scope>test</scope>
  246. </dependency>
  247. <dependency>
  248. <groupId>org.apache.hadoop</groupId>
  249. <artifactId>hadoop-minikdc</artifactId>
  250. <scope>test</scope>
  251. </dependency>
  252. <dependency>
  253. <groupId>com.jcraft</groupId>
  254. <artifactId>jsch</artifactId>
  255. </dependency>
  256. <dependency>
  257. <groupId>org.apache.curator</groupId>
  258. <artifactId>curator-test</artifactId>
  259. <scope>test</scope>
  260. </dependency>
  261. <dependency>
  262. <groupId>org.apache.curator</groupId>
  263. <artifactId>curator-client</artifactId>
  264. </dependency>
  265. <dependency>
  266. <groupId>org.apache.curator</groupId>
  267. <artifactId>curator-recipes</artifactId>
  268. </dependency>
  269. <dependency>
  270. <groupId>com.google.code.findbugs</groupId>
  271. <artifactId>jsr305</artifactId>
  272. <scope>compile</scope>
  273. </dependency>
  274. <dependency>
  275. <groupId>org.apache.sshd</groupId>
  276. <artifactId>sshd-core</artifactId>
  277. <scope>test</scope>
  278. </dependency>
  279. <dependency>
  280. <groupId>org.apache.ftpserver</groupId>
  281. <artifactId>ftpserver-core</artifactId>
  282. <scope>test</scope>
  283. </dependency>
  284. <dependency>
  285. <groupId>org.apache.htrace</groupId>
  286. <artifactId>htrace-core4</artifactId>
  287. </dependency>
  288. <dependency>
  289. <groupId>org.apache.zookeeper</groupId>
  290. <artifactId>zookeeper</artifactId>
  291. <exclusions>
  292. <exclusion>
  293. <groupId>org.jboss.netty</groupId>
  294. <artifactId>netty</artifactId>
  295. </exclusion>
  296. <exclusion>
  297. <!-- otherwise seems to drag in junit 3.8.1 via jline -->
  298. <groupId>junit</groupId>
  299. <artifactId>junit</artifactId>
  300. </exclusion>
  301. <exclusion>
  302. <groupId>com.sun.jdmk</groupId>
  303. <artifactId>jmxtools</artifactId>
  304. </exclusion>
  305. <exclusion>
  306. <groupId>com.sun.jmx</groupId>
  307. <artifactId>jmxri</artifactId>
  308. </exclusion>
  309. </exclusions>
  310. </dependency>
  311. <dependency>
  312. <groupId>org.apache.zookeeper</groupId>
  313. <artifactId>zookeeper</artifactId>
  314. <type>test-jar</type>
  315. <scope>test</scope>
  316. </dependency>
  317. <dependency>
  318. <groupId>org.apache.commons</groupId>
  319. <artifactId>commons-compress</artifactId>
  320. </dependency>
  321. <dependency>
  322. <groupId>org.bouncycastle</groupId>
  323. <artifactId>bcprov-jdk15on</artifactId>
  324. <scope>test</scope>
  325. </dependency>
  326. <dependency>
  327. <groupId>org.apache.kerby</groupId>
  328. <artifactId>kerb-core</artifactId>
  329. </dependency>
  330. <dependency>
  331. <groupId>com.fasterxml.jackson.core</groupId>
  332. <artifactId>jackson-databind</artifactId>
  333. </dependency>
  334. <dependency>
  335. <groupId>org.codehaus.woodstox</groupId>
  336. <artifactId>stax2-api</artifactId>
  337. <scope>compile</scope>
  338. </dependency>
  339. <dependency>
  340. <groupId>com.fasterxml.woodstox</groupId>
  341. <artifactId>woodstox-core</artifactId>
  342. <scope>compile</scope>
  343. </dependency>
  344. <dependency>
  345. <groupId>com.squareup.okhttp3</groupId>
  346. <artifactId>mockwebserver</artifactId>
  347. <scope>test</scope>
  348. </dependency>
  349. <dependency>
  350. <groupId>dnsjava</groupId>
  351. <artifactId>dnsjava</artifactId>
  352. <scope>compile</scope>
  353. </dependency>
  354. <dependency>
  355. <groupId>org.wildfly.openssl</groupId>
  356. <artifactId>wildfly-openssl</artifactId>
  357. <scope>test</scope>
  358. </dependency>
  359. <dependency>
  360. <groupId>org.wildfly.openssl</groupId>
  361. <artifactId>wildfly-openssl-java</artifactId>
  362. <scope>provided</scope>
  363. </dependency>
  364. <dependency>
  365. <groupId>org.xerial.snappy</groupId>
  366. <artifactId>snappy-java</artifactId>
  367. <scope>compile</scope>
  368. </dependency>
  369. <dependency>
  370. <groupId>org.lz4</groupId>
  371. <artifactId>lz4-java</artifactId>
  372. <scope>provided</scope>
  373. </dependency>
  374. </dependencies>
  375. <build>
  376. <!--
  377. Include all files in src/main/resources. By default, do not apply property
  378. substitution (filtering=false), but do apply property substitution to
  379. common-version-info.properties (filtering=true). This will substitute the
  380. version information correctly, but prevent Maven from altering other files
  381. like core-default.xml.
  382. -->
  383. <resources>
  384. <resource>
  385. <directory>${basedir}/src/main/resources</directory>
  386. <excludes>
  387. <exclude>common-version-info.properties</exclude>
  388. </excludes>
  389. <filtering>false</filtering>
  390. </resource>
  391. <resource>
  392. <directory>${basedir}/src/main/resources</directory>
  393. <includes>
  394. <include>common-version-info.properties</include>
  395. </includes>
  396. <filtering>true</filtering>
  397. </resource>
  398. </resources>
  399. <plugins>
  400. <plugin>
  401. <groupId>org.xolstice.maven.plugins</groupId>
  402. <artifactId>protobuf-maven-plugin</artifactId>
  403. <executions>
  404. <execution>
  405. <id>src-compile-protoc</id>
  406. <configuration>
  407. <skip>false</skip>
  408. <excludes>
  409. <exclude>ProtobufRpcEngine.proto</exclude>
  410. </excludes>
  411. </configuration>
  412. </execution>
  413. <execution>
  414. <id>src-test-compile-protoc</id>
  415. <configuration>
  416. <skip>false</skip>
  417. <excludes>
  418. <exclude>*legacy.proto</exclude>
  419. </excludes>
  420. </configuration>
  421. </execution>
  422. </executions>
  423. </plugin>
  424. <plugin>
  425. <groupId>com.google.code.maven-replacer-plugin</groupId>
  426. <artifactId>replacer</artifactId>
  427. <executions>
  428. <execution>
  429. <id>replace-generated-sources</id>
  430. <configuration>
  431. <skip>false</skip>
  432. <excludes>
  433. <exclude>**/ProtobufRpcEngineProtos.java</exclude>
  434. </excludes>
  435. </configuration>
  436. </execution>
  437. <execution>
  438. <id>replace-generated-test-sources</id>
  439. <configuration>
  440. <skip>false</skip>
  441. <excludes>
  442. <exclude>**/TestProtosLegacy.java</exclude>
  443. <exclude>**/TestRpcServiceProtosLegacy.java</exclude>
  444. </excludes>
  445. </configuration>
  446. </execution>
  447. <execution>
  448. <id>replace-sources</id>
  449. <configuration>
  450. <skip>false</skip>
  451. <!--These classes have direct Protobuf references for backward compatibility reasons-->
  452. <excludes>
  453. <exclude>**/ProtobufHelper.java</exclude>
  454. <exclude>**/RpcWritable.java</exclude>
  455. <exclude>**/ProtobufRpcEngineCallback.java</exclude>
  456. <exclude>**/ProtobufRpcEngine.java</exclude>
  457. <exclude>**/ProtobufRpcEngine2.java</exclude>
  458. <exclude>**/ProtobufRpcEngineProtos.java</exclude>
  459. </excludes>
  460. </configuration>
  461. </execution>
  462. <execution>
  463. <id>replace-test-sources</id>
  464. <configuration>
  465. <skip>false</skip>
  466. <excludes>
  467. <exclude>**/TestProtoBufRpc.java</exclude>
  468. </excludes>
  469. </configuration>
  470. </execution>
  471. </executions>
  472. </plugin>
  473. <plugin>
  474. <groupId>org.apache.hadoop</groupId>
  475. <artifactId>hadoop-maven-plugins</artifactId>
  476. <executions>
  477. <execution>
  478. <id>version-info</id>
  479. <phase>generate-resources</phase>
  480. <goals>
  481. <goal>version-info</goal>
  482. </goals>
  483. <configuration>
  484. <source>
  485. <directory>${basedir}/src/main</directory>
  486. <includes>
  487. <include>java/**/*.java</include>
  488. <include>proto/**/*.proto</include>
  489. </includes>
  490. </source>
  491. </configuration>
  492. </execution>
  493. <execution>
  494. <id>resource-gz</id>
  495. <phase>generate-resources</phase>
  496. <goals>
  497. <goal>resource-gz</goal>
  498. </goals>
  499. <configuration>
  500. <inputDirectory>${basedir}/src/main/webapps/static</inputDirectory>
  501. <outputDirectory>${basedir}/target/webapps/static</outputDirectory>
  502. <extensions>js,css</extensions>
  503. </configuration>
  504. </execution>
  505. </executions>
  506. </plugin>
  507. <plugin>
  508. <groupId>org.apache.maven.plugins</groupId>
  509. <artifactId>maven-surefire-plugin</artifactId>
  510. <configuration>
  511. <systemPropertyVariables>
  512. <runningWithNative>${runningWithNative}</runningWithNative>
  513. </systemPropertyVariables>
  514. <properties>
  515. <property>
  516. <name>listener</name>
  517. <value>org.apache.hadoop.test.TimedOutTestsListener</value>
  518. </property>
  519. </properties>
  520. </configuration>
  521. </plugin>
  522. <plugin>
  523. <groupId>org.apache.avro</groupId>
  524. <artifactId>avro-maven-plugin</artifactId>
  525. <executions>
  526. <execution>
  527. <id>generate-avro-test-sources</id>
  528. <phase>generate-test-sources</phase>
  529. <goals>
  530. <goal>schema</goal>
  531. </goals>
  532. </execution>
  533. </executions>
  534. <configuration>
  535. <testOutputDirectory>${project.build.directory}/generated-test-sources/java</testOutputDirectory>
  536. </configuration>
  537. </plugin>
  538. <plugin>
  539. <groupId>org.apache.maven.plugins</groupId>
  540. <artifactId>maven-antrun-plugin</artifactId>
  541. <executions>
  542. <execution>
  543. <id>create-log-dir</id>
  544. <phase>process-test-resources</phase>
  545. <goals>
  546. <goal>run</goal>
  547. </goals>
  548. <configuration>
  549. <target>
  550. <!--
  551. TODO: there are tests (TestLocalFileSystem#testCopy) that fail if data
  552. TODO: from a previous run is present
  553. -->
  554. <delete dir="${test.build.data}"/>
  555. <mkdir dir="${test.build.data}"/>
  556. <mkdir dir="${hadoop.log.dir}"/>
  557. <copy toDir="${project.build.directory}/test-classes">
  558. <fileset dir="${basedir}/src/main/conf"/>
  559. </copy>
  560. </target>
  561. </configuration>
  562. </execution>
  563. <execution>
  564. <phase>pre-site</phase>
  565. <goals>
  566. <goal>run</goal>
  567. </goals>
  568. <configuration>
  569. <target>
  570. <copy file="src/main/resources/core-default.xml" todir="src/site/resources"/>
  571. <copy file="src/main/xsl/configuration.xsl" todir="src/site/resources"/>
  572. </target>
  573. </configuration>
  574. </execution>
  575. </executions>
  576. </plugin>
  577. <plugin>
  578. <groupId>org.apache.rat</groupId>
  579. <artifactId>apache-rat-plugin</artifactId>
  580. <configuration>
  581. <excludes>
  582. <exclude>.idea/**</exclude>
  583. <exclude>src/main/conf/*</exclude>
  584. <exclude>dev-support/jdiff/**</exclude>
  585. <exclude>src/main/native/*</exclude>
  586. <exclude>src/main/native/config/*</exclude>
  587. <exclude>src/main/native/m4/*</exclude>
  588. <exclude>src/test/empty-file</exclude>
  589. <exclude>src/test/all-tests</exclude>
  590. <exclude>src/main/native/gtest/**/*</exclude>
  591. <exclude>src/test/resources/test-untar.tgz</exclude>
  592. <exclude>src/test/resources/test.har/_SUCCESS</exclude>
  593. <exclude>src/test/resources/test.har/_index</exclude>
  594. <exclude>src/test/resources/test.har/_masterindex</exclude>
  595. <exclude>src/test/resources/test.har/part-0</exclude>
  596. <exclude>src/test/resources/javakeystoreprovider.password</exclude>
  597. <exclude>dev-support/jdiff-workaround.patch</exclude>
  598. </excludes>
  599. </configuration>
  600. </plugin>
  601. <plugin>
  602. <groupId>org.codehaus.mojo</groupId>
  603. <artifactId>exec-maven-plugin</artifactId>
  604. <executions>
  605. <execution>
  606. <id>shelldocs</id>
  607. <phase>pre-site</phase>
  608. <goals>
  609. <goal>exec</goal>
  610. </goals>
  611. <configuration>
  612. <executable>${basedir}/../../dev-support/bin/shelldocs</executable>
  613. <workingDirectory>src/site/markdown</workingDirectory>
  614. <arguments>
  615. <argument>--skipprnorep</argument>
  616. <argument>--output</argument>
  617. <argument>${basedir}/src/site/markdown/UnixShellAPI.md</argument>
  618. <argument>--input</argument>
  619. <argument>${basedir}/src/main/bin/hadoop-functions.sh</argument>
  620. </arguments>
  621. </configuration>
  622. </execution>
  623. </executions>
  624. </plugin>
  625. <plugin>
  626. <artifactId>maven-clean-plugin</artifactId>
  627. <configuration>
  628. <filesets>
  629. <fileset>
  630. <directory>src/site/markdown</directory>
  631. <includes>
  632. <include>UnixShellAPI.md</include>
  633. </includes>
  634. <followSymlinks>false</followSymlinks>
  635. </fileset>
  636. <fileset>
  637. <directory>src/site/resources</directory>
  638. <includes>
  639. <include>configuration.xsl</include>
  640. <include>core-default.xml</include>
  641. </includes>
  642. <followSymlinks>false</followSymlinks>
  643. </fileset>
  644. </filesets>
  645. </configuration>
  646. </plugin>
  647. </plugins>
  648. </build>
  649. <profiles>
  650. <profile>
  651. <id>native</id>
  652. <activation>
  653. <activeByDefault>false</activeByDefault>
  654. </activation>
  655. <properties>
  656. <require.bzip2>false</require.bzip2>
  657. <zstd.prefix></zstd.prefix>
  658. <zstd.lib></zstd.lib>
  659. <zstd.include></zstd.include>
  660. <require.zstd>false</require.zstd>
  661. <openssl.prefix></openssl.prefix>
  662. <openssl.lib></openssl.lib>
  663. <openssl.include></openssl.include>
  664. <require.isal>false</require.isal>
  665. <isal.prefix></isal.prefix>
  666. <isal.lib></isal.lib>
  667. <require.openssl>false</require.openssl>
  668. <runningWithNative>true</runningWithNative>
  669. <bundle.openssl.in.bin>false</bundle.openssl.in.bin>
  670. <extra.libhadoop.rpath></extra.libhadoop.rpath>
  671. </properties>
  672. <build>
  673. <plugins>
  674. <plugin>
  675. <groupId>org.apache.maven.plugins</groupId>
  676. <artifactId>maven-enforcer-plugin</artifactId>
  677. <executions>
  678. <execution>
  679. <id>enforce-os</id>
  680. <goals>
  681. <goal>enforce</goal>
  682. </goals>
  683. <configuration>
  684. <rules>
  685. <requireOS>
  686. <family>mac</family>
  687. <family>unix</family>
  688. <message>native build only supported on Mac or Unix</message>
  689. </requireOS>
  690. </rules>
  691. <fail>true</fail>
  692. </configuration>
  693. </execution>
  694. </executions>
  695. </plugin>
  696. <plugin>
  697. <groupId>org.apache.hadoop</groupId>
  698. <artifactId>hadoop-maven-plugins</artifactId>
  699. <executions>
  700. <execution>
  701. <id>cmake-compile</id>
  702. <phase>compile</phase>
  703. <goals><goal>cmake-compile</goal></goals>
  704. <configuration>
  705. <source>${basedir}/src</source>
  706. <vars>
  707. <GENERATED_JAVAH>${project.build.directory}/native/javah</GENERATED_JAVAH>
  708. <JVM_ARCH_DATA_MODEL>${sun.arch.data.model}</JVM_ARCH_DATA_MODEL>
  709. <REQUIRE_BZIP2>${require.bzip2}</REQUIRE_BZIP2>
  710. <REQUIRE_ZSTD>${require.zstd}</REQUIRE_ZSTD>
  711. <CUSTOM_ZSTD_PREFIX>${zstd.prefix}</CUSTOM_ZSTD_PREFIX>
  712. <CUSTOM_ZSTD_LIB>${zstd.lib} </CUSTOM_ZSTD_LIB>
  713. <CUSTOM_ZSTD_INCLUDE>${zstd.include} </CUSTOM_ZSTD_INCLUDE>
  714. <REQUIRE_ISAL>${require.isal} </REQUIRE_ISAL>
  715. <CUSTOM_ISAL_PREFIX>${isal.prefix} </CUSTOM_ISAL_PREFIX>
  716. <CUSTOM_ISAL_LIB>${isal.lib} </CUSTOM_ISAL_LIB>
  717. <REQUIRE_PMDK>${require.pmdk}</REQUIRE_PMDK>
  718. <CUSTOM_PMDK_LIB>${pmdk.lib}</CUSTOM_PMDK_LIB>
  719. <REQUIRE_OPENSSL>${require.openssl} </REQUIRE_OPENSSL>
  720. <CUSTOM_OPENSSL_PREFIX>${openssl.prefix} </CUSTOM_OPENSSL_PREFIX>
  721. <CUSTOM_OPENSSL_LIB>${openssl.lib} </CUSTOM_OPENSSL_LIB>
  722. <CUSTOM_OPENSSL_INCLUDE>${openssl.include} </CUSTOM_OPENSSL_INCLUDE>
  723. <EXTRA_LIBHADOOP_RPATH>${extra.libhadoop.rpath}</EXTRA_LIBHADOOP_RPATH>
  724. </vars>
  725. </configuration>
  726. </execution>
  727. <execution>
  728. <id>test_bulk_crc32</id>
  729. <goals><goal>cmake-test</goal></goals>
  730. <phase>test</phase>
  731. <configuration>
  732. <binary>${project.build.directory}/native/test_bulk_crc32</binary>
  733. <timeout>1200</timeout>
  734. <results>${project.build.directory}/native-results</results>
  735. </configuration>
  736. </execution>
  737. <execution>
  738. <id>erasure_code_test</id>
  739. <goals><goal>cmake-test</goal></goals>
  740. <phase>test</phase>
  741. <configuration>
  742. <binary>${project.build.directory}/native/erasure_code_test</binary>
  743. <timeout>300</timeout>
  744. <results>${project.build.directory}/native-results</results>
  745. <skipIfMissing>true</skipIfMissing>
  746. <env>
  747. <LD_LIBRARY_PATH>${LD_LIBRARY_PATH}:${isal.lib}:${isal.prefix}:/usr/lib</LD_LIBRARY_PATH>
  748. </env>
  749. </configuration>
  750. </execution>
  751. </executions>
  752. </plugin>
  753. </plugins>
  754. </build>
  755. </profile>
  756. <profile>
  757. <id>native-win</id>
  758. <activation>
  759. <os>
  760. <family>Windows</family>
  761. </os>
  762. </activation>
  763. <properties>
  764. <require.isal>false</require.isal>
  765. <isal.prefix></isal.prefix>
  766. <isal.lib></isal.lib>
  767. <zstd.prefix></zstd.prefix>
  768. <zstd.lib></zstd.lib>
  769. <zstd.include></zstd.include>
  770. <require.zstd>false</require.zstd>
  771. <bundle.zstd.in.bin>true</bundle.zstd.in.bin>
  772. <openssl.prefix></openssl.prefix>
  773. <openssl.lib></openssl.lib>
  774. <openssl.include></openssl.include>
  775. <require.openssl>false</require.openssl>
  776. <runningWithNative>true</runningWithNative>
  777. <bundle.openssl.in.bin>false</bundle.openssl.in.bin>
  778. </properties>
  779. <build>
  780. <plugins>
  781. <plugin>
  782. <groupId>org.apache.maven.plugins</groupId>
  783. <artifactId>maven-enforcer-plugin</artifactId>
  784. <executions>
  785. <execution>
  786. <id>enforce-os</id>
  787. <goals>
  788. <goal>enforce</goal>
  789. </goals>
  790. <configuration>
  791. <rules>
  792. <requireOS>
  793. <family>windows</family>
  794. <message>native-win build only supported on Windows</message>
  795. </requireOS>
  796. </rules>
  797. <fail>true</fail>
  798. </configuration>
  799. </execution>
  800. </executions>
  801. </plugin>
  802. <plugin>
  803. <groupId>org.codehaus.mojo</groupId>
  804. <artifactId>exec-maven-plugin</artifactId>
  805. <executions>
  806. <execution>
  807. <id>convert-ms-winutils</id>
  808. <phase>generate-sources</phase>
  809. <goals>
  810. <goal>exec</goal>
  811. </goals>
  812. <configuration>
  813. <executable>${basedir}\..\..\dev-support\bin\win-vs-upgrade.cmd</executable>
  814. <arguments>
  815. <argument>${basedir}\src\main\winutils</argument>
  816. <argument>${project.build.directory}</argument>
  817. </arguments>
  818. </configuration>
  819. </execution>
  820. <execution>
  821. <id>compile-ms-winutils</id>
  822. <phase>compile</phase>
  823. <goals>
  824. <goal>exec</goal>
  825. </goals>
  826. <configuration>
  827. <executable>msbuild</executable>
  828. <arguments>
  829. <argument>${basedir}/src/main/winutils/winutils.sln</argument>
  830. <argument>/nologo</argument>
  831. <argument>/p:Configuration=Release</argument>
  832. <argument>/p:OutDir=${project.build.directory}/bin/</argument>
  833. <argument>/p:IntermediateOutputPath=${project.build.directory}/winutils/</argument>
  834. <argument>/p:WsceConfigDir=${wsce.config.dir}</argument>
  835. <argument>/p:WsceConfigFile=${wsce.config.file}</argument>
  836. </arguments>
  837. </configuration>
  838. </execution>
  839. <execution>
  840. <id>convert-ms-native-dll</id>
  841. <phase>generate-sources</phase>
  842. <goals>
  843. <goal>exec</goal>
  844. </goals>
  845. <configuration>
  846. <executable>${basedir}\..\..\dev-support\bin\win-vs-upgrade.cmd</executable>
  847. <arguments>
  848. <argument>${basedir}\src\main\native</argument>
  849. <argument>${project.build.directory}</argument>
  850. </arguments>
  851. </configuration>
  852. </execution>
  853. <execution>
  854. <id>compile-ms-native-dll</id>
  855. <phase>compile</phase>
  856. <goals>
  857. <goal>exec</goal>
  858. </goals>
  859. <configuration>
  860. <executable>msbuild</executable>
  861. <arguments>
  862. <argument>${basedir}/src/main/native/native.sln</argument>
  863. <argument>/nologo</argument>
  864. <argument>/p:Configuration=Release</argument>
  865. <argument>/p:OutDir=${project.build.directory}/bin/</argument>
  866. <argument>/p:CustomZstdPrefix=${zstd.prefix}</argument>
  867. <argument>/p:CustomZstdLib=${zstd.lib}</argument>
  868. <argument>/p:CustomZstdInclude=${zstd.include}</argument>
  869. <argument>/p:RequireZstd=${require.zstd}</argument>
  870. <argument>/p:CustomOpensslPrefix=${openssl.prefix}</argument>
  871. <argument>/p:CustomOpensslLib=${openssl.lib}</argument>
  872. <argument>/p:CustomOpensslInclude=${openssl.include}</argument>
  873. <argument>/p:RequireOpenssl=${require.openssl}</argument>
  874. <argument>/p:RequireIsal=${require.isal}</argument>
  875. <argument>/p:CustomIsalPrefix=${isal.prefix}</argument>
  876. <argument>/p:CustomIsalLib=${isal.lib}</argument>
  877. </arguments>
  878. </configuration>
  879. </execution>
  880. </executions>
  881. </plugin>
  882. </plugins>
  883. </build>
  884. </profile>
  885. <profile>
  886. <id>parallel-tests</id>
  887. <build>
  888. <plugins>
  889. <plugin>
  890. <groupId>org.apache.hadoop</groupId>
  891. <artifactId>hadoop-maven-plugins</artifactId>
  892. <executions>
  893. <execution>
  894. <id>parallel-tests-createdir</id>
  895. <phase>process-test-resources</phase>
  896. <goals>
  897. <goal>parallel-tests-createdir</goal>
  898. </goals>
  899. <configuration>
  900. <testBuildData>${test.build.data}</testBuildData>
  901. </configuration>
  902. </execution>
  903. </executions>
  904. </plugin>
  905. <plugin>
  906. <groupId>org.apache.maven.plugins</groupId>
  907. <artifactId>maven-surefire-plugin</artifactId>
  908. <configuration>
  909. <testFailureIgnore>${ignoreTestFailure}</testFailureIgnore>
  910. <forkCount>${testsThreadCount}</forkCount>
  911. <reuseForks>false</reuseForks>
  912. <argLine>${maven-surefire-plugin.argLine} -DminiClusterDedicatedDirs=true</argLine>
  913. <systemPropertyVariables>
  914. <testsThreadCount>${testsThreadCount}</testsThreadCount>
  915. <test.build.data>${test.build.data}/${surefire.forkNumber}</test.build.data>
  916. <test.build.dir>${test.build.dir}/${surefire.forkNumber}</test.build.dir>
  917. <hadoop.tmp.dir>${hadoop.tmp.dir}/${surefire.forkNumber}</hadoop.tmp.dir>
  918. <!-- Due to a Maven quirk, setting this to just -->
  919. <!-- surefire.forkNumber won't do the parameter substitution. -->
  920. <!-- Putting a prefix in front of it like "fork-" makes it -->
  921. <!-- work. -->
  922. <test.unique.fork.id>fork-${surefire.forkNumber}</test.unique.fork.id>
  923. </systemPropertyVariables>
  924. </configuration>
  925. </plugin>
  926. </plugins>
  927. </build>
  928. </profile>
  929. <profile>
  930. <id>releasedocs</id>
  931. <activation>
  932. <activeByDefault>false</activeByDefault>
  933. </activation>
  934. <build>
  935. <plugins>
  936. <plugin>
  937. <groupId>org.codehaus.mojo</groupId>
  938. <artifactId>exec-maven-plugin</artifactId>
  939. <executions>
  940. <execution>
  941. <id>releasedocs</id>
  942. <phase>pre-site</phase>
  943. <goals>
  944. <goal>exec</goal>
  945. </goals>
  946. <configuration>
  947. <executable>${basedir}/../../dev-support/bin/releasedocmaker</executable>
  948. <requiresOnline>true</requiresOnline>
  949. <arguments>
  950. <argument>--index</argument>
  951. <argument>--license</argument>
  952. <argument>--outputdir</argument>
  953. <argument>${basedir}/src/site/markdown/release</argument>
  954. <argument>--project</argument>
  955. <argument>HADOOP</argument>
  956. <argument>--project</argument>
  957. <argument>HDFS</argument>
  958. <argument>--project</argument>
  959. <argument>MAPREDUCE</argument>
  960. <argument>--project</argument>
  961. <argument>YARN</argument>
  962. <argument>--projecttitle</argument>
  963. <argument>Apache Hadoop</argument>
  964. <argument>--usetoday</argument>
  965. <argument>--fileversions</argument>
  966. <argument>--dirversions</argument>
  967. <argument>--version</argument>
  968. <argument>${project.version}</argument>
  969. </arguments>
  970. </configuration>
  971. </execution>
  972. </executions>
  973. </plugin>
  974. <plugin>
  975. <artifactId>maven-clean-plugin</artifactId>
  976. <configuration>
  977. <filesets>
  978. <fileset>
  979. <directory>src/site/markdown/release</directory>
  980. <includes>
  981. <include>${project.version}/</include>
  982. <include>index.md</include>
  983. </includes>
  984. <followSymlinks>false</followSymlinks>
  985. </fileset>
  986. </filesets>
  987. </configuration>
  988. </plugin>
  989. </plugins>
  990. </build>
  991. </profile>
  992. <!-- profile to test shell code -->
  993. <profile>
  994. <id>shelltest</id>
  995. <activation>
  996. <property>
  997. <name>!skipTests</name>
  998. </property>
  999. </activation>
  1000. <build>
  1001. <plugins>
  1002. <plugin>
  1003. <artifactId>maven-antrun-plugin</artifactId>
  1004. <executions>
  1005. <execution>
  1006. <id>common-test-bats-driver</id>
  1007. <phase>test</phase>
  1008. <goals>
  1009. <goal>run</goal>
  1010. </goals>
  1011. <configuration>
  1012. <target>
  1013. <exec dir="src/test/scripts"
  1014. executable="bash"
  1015. failonerror="true">
  1016. <arg value="./run-bats.sh" />
  1017. </exec>
  1018. </target>
  1019. </configuration>
  1020. </execution>
  1021. </executions>
  1022. </plugin>
  1023. </plugins>
  1024. </build>
  1025. </profile>
  1026. <!-- profile to use already generated protobuf code using 2.5.0 for aarch64-->
  1027. <profile>
  1028. <id>aarch64</id>
  1029. <activation>
  1030. <activeByDefault>false</activeByDefault>
  1031. <os>
  1032. <arch>aarch64</arch>
  1033. </os>
  1034. </activation>
  1035. <build>
  1036. <plugins>
  1037. <plugin>
  1038. <groupId>org.codehaus.mojo</groupId>
  1039. <artifactId>build-helper-maven-plugin</artifactId>
  1040. <executions>
  1041. <execution>
  1042. <id>add-source-legacy-protobuf</id>
  1043. <phase>generate-sources</phase>
  1044. <goals>
  1045. <goal>add-source</goal>
  1046. </goals>
  1047. <configuration>
  1048. <sources>
  1049. <source>${basedir}/src/main/arm-java</source>
  1050. </sources>
  1051. </configuration>
  1052. </execution>
  1053. <execution>
  1054. <id>add-test-source-legacy-protobuf</id>
  1055. <phase>generate-test-sources</phase>
  1056. <goals>
  1057. <goal>add-test-source</goal>
  1058. </goals>
  1059. <configuration>
  1060. <sources>
  1061. <source>${basedir}/src/test/arm-java</source>
  1062. </sources>
  1063. </configuration>
  1064. </execution>
  1065. </executions>
  1066. </plugin>
  1067. </plugins>
  1068. </build>
  1069. </profile>
  1070. <!-- profile to generate protobuf code using 2.5.0-->
  1071. <profile>
  1072. <id>x86_64</id>
  1073. <activation>
  1074. <activeByDefault>false</activeByDefault>
  1075. <os>
  1076. <arch>!aarch64</arch>
  1077. </os>
  1078. </activation>
  1079. <build>
  1080. <plugins>
  1081. <plugin>
  1082. <groupId>org.xolstice.maven.plugins</groupId>
  1083. <artifactId>protobuf-maven-plugin</artifactId>
  1084. <executions>
  1085. <execution>
  1086. <id>src-compile-protoc-legacy</id>
  1087. <phase>generate-sources</phase>
  1088. <goals>
  1089. <goal>compile</goal>
  1090. </goals>
  1091. <configuration>
  1092. <skip>false</skip>
  1093. <!--Generating with old protobuf version for backward compatibility-->
  1094. <protocArtifact>
  1095. com.google.protobuf:protoc:${protobuf.version}:exe:${os.detected.classifier}
  1096. </protocArtifact>
  1097. <includeDependenciesInDescriptorSet>false</includeDependenciesInDescriptorSet>
  1098. <protoSourceRoot>${basedir}/src/main/proto</protoSourceRoot>
  1099. <outputDirectory>${project.build.directory}/generated-sources/java</outputDirectory>
  1100. <clearOutputDirectory>false</clearOutputDirectory>
  1101. <includes>
  1102. <include>ProtobufRpcEngine.proto</include>
  1103. </includes>
  1104. </configuration>
  1105. </execution>
  1106. <execution>
  1107. <id>src-test-compile-protoc-legacy</id>
  1108. <phase>generate-test-sources</phase>
  1109. <goals>
  1110. <goal>compile</goal>
  1111. </goals>
  1112. <configuration>
  1113. <skip>false</skip>
  1114. <!--Generating with old protobuf version for backward compatibility-->
  1115. <protocArtifact>
  1116. com.google.protobuf:protoc:${protobuf.version}:exe:${os.detected.classifier}
  1117. </protocArtifact>
  1118. <includeDependenciesInDescriptorSet>false</includeDependenciesInDescriptorSet>
  1119. <protoSourceRoot>${basedir}/src/test/proto</protoSourceRoot>
  1120. <outputDirectory>${project.build.directory}/generated-test-sources/java</outputDirectory>
  1121. <clearOutputDirectory>false</clearOutputDirectory>
  1122. <includes>
  1123. <include>test_legacy.proto</include>
  1124. <include>test_rpc_service_legacy.proto</include>
  1125. </includes>
  1126. </configuration>
  1127. </execution>
  1128. </executions>
  1129. </plugin>
  1130. </plugins>
  1131. </build>
  1132. </profile>
  1133. </profiles>
  1134. </project>