pom.xml 48 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296
  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.5.0-SNAPSHOT</version>
  22. <relativePath>../../hadoop-project-dist</relativePath>
  23. </parent>
  24. <artifactId>hadoop-common</artifactId>
  25. <version>3.5.0-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_23</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. <exclusions>
  141. <exclusion>
  142. <groupId>javax.enterprise</groupId>
  143. <artifactId>cdi-api</artifactId>
  144. </exclusion>
  145. <exclusion>
  146. <groupId>javax.servlet</groupId>
  147. <artifactId>servlet-api</artifactId>
  148. </exclusion>
  149. <exclusion>
  150. <groupId>ch.qos.cal10n</groupId>
  151. <artifactId>cal10n-api</artifactId>
  152. </exclusion>
  153. </exclusions>
  154. </dependency>
  155. <dependency>
  156. <groupId>com.github.pjfanning</groupId>
  157. <artifactId>jersey-json</artifactId>
  158. <scope>compile</scope>
  159. <exclusions>
  160. <exclusion>
  161. <groupId>com.fasterxml.jackson.core</groupId>
  162. <artifactId>jackson-core</artifactId>
  163. </exclusion>
  164. <exclusion>
  165. <groupId>com.fasterxml.jackson.core</groupId>
  166. <artifactId>jackson-databind</artifactId>
  167. </exclusion>
  168. <exclusion>
  169. <groupId>com.fasterxml.jackson.jaxrs</groupId>
  170. <artifactId>jackson-jaxrs-json-provider</artifactId>
  171. </exclusion>
  172. <exclusion>
  173. <groupId>org.codehaus.jettison</groupId>
  174. <artifactId>jettison</artifactId>
  175. </exclusion>
  176. </exclusions>
  177. </dependency>
  178. <dependency>
  179. <!--
  180. adding jettison as direct dependency (as jersey-json's jettison dependency is vulnerable with verison 1.1),
  181. so those who depends on hadoop-common externally will get the non-vulnerable jettison
  182. -->
  183. <groupId>org.codehaus.jettison</groupId>
  184. <artifactId>jettison</artifactId>
  185. </dependency>
  186. <dependency>
  187. <groupId>com.sun.jersey</groupId>
  188. <artifactId>jersey-server</artifactId>
  189. <scope>compile</scope>
  190. </dependency>
  191. <dependency>
  192. <groupId>ch.qos.reload4j</groupId>
  193. <artifactId>reload4j</artifactId>
  194. <scope>compile</scope>
  195. </dependency>
  196. <dependency>
  197. <groupId>junit</groupId>
  198. <artifactId>junit</artifactId>
  199. <scope>test</scope>
  200. </dependency>
  201. <dependency>
  202. <groupId>org.assertj</groupId>
  203. <artifactId>assertj-core</artifactId>
  204. <scope>test</scope>
  205. </dependency>
  206. <dependency>
  207. <groupId>commons-beanutils</groupId>
  208. <artifactId>commons-beanutils</artifactId>
  209. <scope>compile</scope>
  210. </dependency>
  211. <dependency>
  212. <groupId>org.apache.commons</groupId>
  213. <artifactId>commons-configuration2</artifactId>
  214. <scope>compile</scope>
  215. <exclusions>
  216. <exclusion>
  217. <groupId>javax.servlet</groupId>
  218. <artifactId>servlet-api</artifactId>
  219. </exclusion>
  220. </exclusions>
  221. </dependency>
  222. <dependency>
  223. <groupId>org.apache.commons</groupId>
  224. <artifactId>commons-lang3</artifactId>
  225. <scope>compile</scope>
  226. </dependency>
  227. <dependency>
  228. <groupId>org.apache.commons</groupId>
  229. <artifactId>commons-text</artifactId>
  230. <scope>compile</scope>
  231. </dependency>
  232. <dependency>
  233. <groupId>org.slf4j</groupId>
  234. <artifactId>slf4j-api</artifactId>
  235. <scope>compile</scope>
  236. </dependency>
  237. <dependency>
  238. <groupId>org.slf4j</groupId>
  239. <artifactId>slf4j-reload4j</artifactId>
  240. <scope>compile</scope>
  241. </dependency>
  242. <dependency>
  243. <groupId>org.mockito</groupId>
  244. <artifactId>mockito-core</artifactId>
  245. <scope>test</scope>
  246. </dependency>
  247. <dependency>
  248. <groupId>org.apache.avro</groupId>
  249. <artifactId>avro</artifactId>
  250. <scope>compile</scope>
  251. </dependency>
  252. <dependency>
  253. <groupId>org.apache.ant</groupId>
  254. <artifactId>ant</artifactId>
  255. <scope>test</scope>
  256. </dependency>
  257. <dependency>
  258. <groupId>com.google.re2j</groupId>
  259. <artifactId>re2j</artifactId>
  260. <scope>compile</scope>
  261. </dependency>
  262. <!-- Needed for compilation, though no longer in production. -->
  263. <dependency>
  264. <groupId>com.google.protobuf</groupId>
  265. <artifactId>protobuf-java</artifactId>
  266. <scope>${common.protobuf2.scope}</scope>
  267. </dependency>
  268. <dependency>
  269. <groupId>com.google.code.gson</groupId>
  270. <artifactId>gson</artifactId>
  271. </dependency>
  272. <dependency>
  273. <groupId>org.apache.hadoop</groupId>
  274. <artifactId>hadoop-auth</artifactId>
  275. <scope>compile</scope>
  276. </dependency>
  277. <dependency>
  278. <groupId>org.apache.hadoop</groupId>
  279. <artifactId>hadoop-auth</artifactId>
  280. <type>test-jar</type>
  281. <scope>test</scope>
  282. </dependency>
  283. <dependency>
  284. <groupId>org.apache.hadoop</groupId>
  285. <artifactId>hadoop-minikdc</artifactId>
  286. <scope>test</scope>
  287. </dependency>
  288. <dependency>
  289. <groupId>com.jcraft</groupId>
  290. <artifactId>jsch</artifactId>
  291. </dependency>
  292. <dependency>
  293. <groupId>org.apache.curator</groupId>
  294. <artifactId>curator-test</artifactId>
  295. <scope>test</scope>
  296. </dependency>
  297. <dependency>
  298. <groupId>org.apache.curator</groupId>
  299. <artifactId>curator-client</artifactId>
  300. </dependency>
  301. <dependency>
  302. <groupId>org.apache.curator</groupId>
  303. <artifactId>curator-recipes</artifactId>
  304. </dependency>
  305. <dependency>
  306. <groupId>com.google.code.findbugs</groupId>
  307. <artifactId>jsr305</artifactId>
  308. <scope>compile</scope>
  309. </dependency>
  310. <dependency>
  311. <groupId>org.apache.sshd</groupId>
  312. <artifactId>sshd-core</artifactId>
  313. <scope>test</scope>
  314. </dependency>
  315. <dependency>
  316. <groupId>org.apache.sshd</groupId>
  317. <artifactId>sshd-sftp</artifactId>
  318. <scope>test</scope>
  319. </dependency>
  320. <dependency>
  321. <groupId>org.apache.ftpserver</groupId>
  322. <artifactId>ftpserver-core</artifactId>
  323. <scope>test</scope>
  324. </dependency>
  325. <dependency>
  326. <groupId>org.apache.zookeeper</groupId>
  327. <artifactId>zookeeper</artifactId>
  328. <exclusions>
  329. <exclusion>
  330. <groupId>org.jboss.netty</groupId>
  331. <artifactId>netty</artifactId>
  332. </exclusion>
  333. <exclusion>
  334. <!-- otherwise seems to drag in junit 3.8.1 via jline -->
  335. <groupId>junit</groupId>
  336. <artifactId>junit</artifactId>
  337. </exclusion>
  338. <exclusion>
  339. <groupId>com.sun.jdmk</groupId>
  340. <artifactId>jmxtools</artifactId>
  341. </exclusion>
  342. <exclusion>
  343. <groupId>com.sun.jmx</groupId>
  344. <artifactId>jmxri</artifactId>
  345. </exclusion>
  346. </exclusions>
  347. </dependency>
  348. <dependency>
  349. <groupId>io.netty</groupId>
  350. <artifactId>netty-handler</artifactId>
  351. </dependency>
  352. <dependency>
  353. <groupId>io.netty</groupId>
  354. <artifactId>netty-transport-native-epoll</artifactId>
  355. </dependency>
  356. <dependency>
  357. <groupId>io.dropwizard.metrics</groupId>
  358. <artifactId>metrics-core</artifactId>
  359. </dependency>
  360. <dependency>
  361. <groupId>org.apache.zookeeper</groupId>
  362. <artifactId>zookeeper</artifactId>
  363. <type>test-jar</type>
  364. <scope>test</scope>
  365. </dependency>
  366. <dependency>
  367. <groupId>org.apache.commons</groupId>
  368. <artifactId>commons-compress</artifactId>
  369. </dependency>
  370. <dependency>
  371. <groupId>org.bouncycastle</groupId>
  372. <artifactId>bcprov-jdk18on</artifactId>
  373. </dependency>
  374. <dependency>
  375. <groupId>org.apache.kerby</groupId>
  376. <artifactId>kerb-core</artifactId>
  377. </dependency>
  378. <dependency>
  379. <groupId>com.fasterxml.jackson.core</groupId>
  380. <artifactId>jackson-databind</artifactId>
  381. </dependency>
  382. <dependency>
  383. <groupId>org.codehaus.woodstox</groupId>
  384. <artifactId>stax2-api</artifactId>
  385. <scope>compile</scope>
  386. </dependency>
  387. <dependency>
  388. <groupId>com.fasterxml.woodstox</groupId>
  389. <artifactId>woodstox-core</artifactId>
  390. <scope>compile</scope>
  391. </dependency>
  392. <dependency>
  393. <groupId>com.squareup.okhttp3</groupId>
  394. <artifactId>mockwebserver</artifactId>
  395. <scope>test</scope>
  396. </dependency>
  397. <dependency>
  398. <groupId>org.jetbrains.kotlin</groupId>
  399. <artifactId>kotlin-stdlib-jdk8</artifactId>
  400. <scope>test</scope>
  401. </dependency>
  402. <dependency>
  403. <groupId>dnsjava</groupId>
  404. <artifactId>dnsjava</artifactId>
  405. <scope>compile</scope>
  406. </dependency>
  407. <dependency>
  408. <groupId>org.wildfly.openssl</groupId>
  409. <artifactId>wildfly-openssl</artifactId>
  410. <scope>test</scope>
  411. </dependency>
  412. <dependency>
  413. <groupId>org.wildfly.openssl</groupId>
  414. <artifactId>wildfly-openssl-java</artifactId>
  415. <scope>provided</scope>
  416. </dependency>
  417. <dependency>
  418. <groupId>org.xerial.snappy</groupId>
  419. <artifactId>snappy-java</artifactId>
  420. <scope>compile</scope>
  421. </dependency>
  422. <dependency>
  423. <groupId>org.lz4</groupId>
  424. <artifactId>lz4-java</artifactId>
  425. <scope>provided</scope>
  426. </dependency>
  427. </dependencies>
  428. <build>
  429. <!--
  430. Include all files in src/main/resources. By default, do not apply property
  431. substitution (filtering=false), but do apply property substitution to
  432. common-version-info.properties (filtering=true). This will substitute the
  433. version information correctly, but prevent Maven from altering other files
  434. like core-default.xml.
  435. -->
  436. <resources>
  437. <resource>
  438. <directory>${basedir}/src/main/resources</directory>
  439. <excludes>
  440. <exclude>common-version-info.properties</exclude>
  441. </excludes>
  442. <filtering>false</filtering>
  443. </resource>
  444. <resource>
  445. <directory>${basedir}/src/main/resources</directory>
  446. <includes>
  447. <include>common-version-info.properties</include>
  448. </includes>
  449. <filtering>true</filtering>
  450. </resource>
  451. </resources>
  452. <plugins>
  453. <plugin>
  454. <groupId>org.xolstice.maven.plugins</groupId>
  455. <artifactId>protobuf-maven-plugin</artifactId>
  456. <executions>
  457. <execution>
  458. <id>src-compile-protoc</id>
  459. <configuration>
  460. <skip>false</skip>
  461. <excludes>
  462. <exclude>ProtobufRpcEngine.proto</exclude>
  463. </excludes>
  464. </configuration>
  465. </execution>
  466. <execution>
  467. <id>src-test-compile-protoc</id>
  468. <configuration>
  469. <skip>false</skip>
  470. <excludes>
  471. <exclude>*legacy.proto</exclude>
  472. </excludes>
  473. </configuration>
  474. </execution>
  475. </executions>
  476. </plugin>
  477. <plugin>
  478. <groupId>com.google.code.maven-replacer-plugin</groupId>
  479. <artifactId>replacer</artifactId>
  480. <executions>
  481. <execution>
  482. <id>replace-generated-sources</id>
  483. <configuration>
  484. <skip>false</skip>
  485. <excludes>
  486. <exclude>**/ProtobufRpcEngineProtos.java</exclude>
  487. </excludes>
  488. </configuration>
  489. </execution>
  490. <execution>
  491. <id>replace-generated-test-sources</id>
  492. <configuration>
  493. <skip>false</skip>
  494. <excludes>
  495. <exclude>**/TestProtosLegacy.java</exclude>
  496. <exclude>**/TestRpcServiceProtosLegacy.java</exclude>
  497. </excludes>
  498. </configuration>
  499. </execution>
  500. <execution>
  501. <id>replace-sources</id>
  502. <configuration>
  503. <skip>false</skip>
  504. <!--These classes have direct Protobuf references for backward compatibility reasons-->
  505. <excludes>
  506. <exclude>**/ProtobufHelper.java</exclude>
  507. <exclude>**/ProtobufRpcEngineCallback.java</exclude>
  508. <exclude>**/ProtobufRpcEngine.java</exclude>
  509. <exclude>**/ProtobufRpcEngine2.java</exclude>
  510. <exclude>**/ProtobufRpcEngineProtos.java</exclude>
  511. <exclude>**/ProtobufWrapperLegacy.java</exclude>
  512. </excludes>
  513. </configuration>
  514. </execution>
  515. <execution>
  516. <id>replace-test-sources</id>
  517. <configuration>
  518. <skip>false</skip>
  519. <excludes>
  520. <exclude>**/TestProtoBufRpc.java</exclude>
  521. </excludes>
  522. </configuration>
  523. </execution>
  524. </executions>
  525. </plugin>
  526. <plugin>
  527. <groupId>org.apache.hadoop</groupId>
  528. <artifactId>hadoop-maven-plugins</artifactId>
  529. <executions>
  530. <execution>
  531. <id>version-info</id>
  532. <phase>generate-resources</phase>
  533. <goals>
  534. <goal>version-info</goal>
  535. </goals>
  536. <configuration>
  537. <source>
  538. <directory>${basedir}/src/main</directory>
  539. <includes>
  540. <include>java/**/*.java</include>
  541. <include>proto/**/*.proto</include>
  542. </includes>
  543. </source>
  544. </configuration>
  545. </execution>
  546. <execution>
  547. <id>resource-gz</id>
  548. <phase>generate-resources</phase>
  549. <goals>
  550. <goal>resource-gz</goal>
  551. </goals>
  552. <configuration>
  553. <inputDirectory>${basedir}/src/main/webapps/static</inputDirectory>
  554. <outputDirectory>${basedir}/target/webapps/static</outputDirectory>
  555. <extensions>js,css</extensions>
  556. </configuration>
  557. </execution>
  558. </executions>
  559. </plugin>
  560. <plugin>
  561. <groupId>org.apache.maven.plugins</groupId>
  562. <artifactId>maven-surefire-plugin</artifactId>
  563. <configuration>
  564. <systemPropertyVariables>
  565. <runningWithNative>${runningWithNative}</runningWithNative>
  566. </systemPropertyVariables>
  567. <properties>
  568. <property>
  569. <name>listener</name>
  570. <value>org.apache.hadoop.test.TimedOutTestsListener</value>
  571. </property>
  572. </properties>
  573. </configuration>
  574. </plugin>
  575. <plugin>
  576. <groupId>org.apache.avro</groupId>
  577. <artifactId>avro-maven-plugin</artifactId>
  578. <executions>
  579. <execution>
  580. <id>generate-avro-test-sources</id>
  581. <phase>generate-test-sources</phase>
  582. <goals>
  583. <goal>schema</goal>
  584. </goals>
  585. </execution>
  586. </executions>
  587. <configuration>
  588. <testOutputDirectory>${project.build.directory}/generated-test-sources/java</testOutputDirectory>
  589. </configuration>
  590. </plugin>
  591. <plugin>
  592. <groupId>org.apache.maven.plugins</groupId>
  593. <artifactId>maven-antrun-plugin</artifactId>
  594. <executions>
  595. <execution>
  596. <id>create-log-dir</id>
  597. <phase>process-test-resources</phase>
  598. <goals>
  599. <goal>run</goal>
  600. </goals>
  601. <configuration>
  602. <target>
  603. <!--
  604. TODO: there are tests (TestLocalFileSystem#testCopy) that fail if data
  605. TODO: from a previous run is present
  606. -->
  607. <delete dir="${test.build.data}"/>
  608. <mkdir dir="${test.build.data}"/>
  609. <mkdir dir="${hadoop.log.dir}"/>
  610. <copy toDir="${project.build.directory}/test-classes">
  611. <fileset dir="${basedir}/src/main/conf"/>
  612. </copy>
  613. </target>
  614. </configuration>
  615. </execution>
  616. <execution>
  617. <phase>pre-site</phase>
  618. <goals>
  619. <goal>run</goal>
  620. </goals>
  621. <configuration>
  622. <target>
  623. <copy file="src/main/resources/core-default.xml" todir="src/site/resources"/>
  624. <copy file="src/main/xsl/configuration.xsl" todir="src/site/resources"/>
  625. </target>
  626. </configuration>
  627. </execution>
  628. </executions>
  629. </plugin>
  630. <plugin>
  631. <groupId>org.apache.rat</groupId>
  632. <artifactId>apache-rat-plugin</artifactId>
  633. <configuration>
  634. <excludes>
  635. <exclude>.idea/**</exclude>
  636. <exclude>src/main/conf/*</exclude>
  637. <exclude>dev-support/jdiff/**</exclude>
  638. <exclude>src/main/native/*</exclude>
  639. <exclude>src/main/native/config/*</exclude>
  640. <exclude>src/main/native/m4/*</exclude>
  641. <exclude>src/main/winutils/winutils.sln</exclude>
  642. <exclude>src/test/empty-file</exclude>
  643. <exclude>src/test/all-tests</exclude>
  644. <exclude>src/main/native/gtest/**/*</exclude>
  645. <exclude>src/test/resources/test-untar.tgz</exclude>
  646. <exclude>src/test/resources/test.har/_SUCCESS</exclude>
  647. <exclude>src/test/resources/test.har/_index</exclude>
  648. <exclude>src/test/resources/test.har/_masterindex</exclude>
  649. <exclude>src/test/resources/test.har/part-0</exclude>
  650. <exclude>src/test/resources/javakeystoreprovider.password</exclude>
  651. <exclude>src/test/resources/lz4/sequencefile</exclude>
  652. <exclude>dev-support/jdiff-workaround.patch</exclude>
  653. </excludes>
  654. </configuration>
  655. </plugin>
  656. <plugin>
  657. <groupId>org.codehaus.mojo</groupId>
  658. <artifactId>exec-maven-plugin</artifactId>
  659. <executions>
  660. <execution>
  661. <id>shelldocs</id>
  662. <phase>pre-site</phase>
  663. <goals>
  664. <goal>exec</goal>
  665. </goals>
  666. <configuration>
  667. <executable>${shell-executable}</executable>
  668. <workingDirectory>src/site/markdown</workingDirectory>
  669. <arguments>
  670. <argument>${basedir}/../../dev-support/bin/shelldocs</argument>
  671. <argument>--skipprnorep</argument>
  672. <argument>--output</argument>
  673. <argument>${basedir}/src/site/markdown/UnixShellAPI.md</argument>
  674. <argument>--input</argument>
  675. <argument>${basedir}/src/main/bin/hadoop-functions.sh</argument>
  676. </arguments>
  677. </configuration>
  678. </execution>
  679. </executions>
  680. </plugin>
  681. <plugin>
  682. <artifactId>maven-clean-plugin</artifactId>
  683. <configuration>
  684. <filesets>
  685. <fileset>
  686. <directory>src/site/markdown</directory>
  687. <includes>
  688. <include>UnixShellAPI.md</include>
  689. </includes>
  690. <followSymlinks>false</followSymlinks>
  691. </fileset>
  692. <fileset>
  693. <directory>src/site/resources</directory>
  694. <includes>
  695. <include>configuration.xsl</include>
  696. <include>core-default.xml</include>
  697. </includes>
  698. <followSymlinks>false</followSymlinks>
  699. </fileset>
  700. </filesets>
  701. </configuration>
  702. </plugin>
  703. </plugins>
  704. </build>
  705. <profiles>
  706. <profile>
  707. <id>native</id>
  708. <activation>
  709. <activeByDefault>false</activeByDefault>
  710. </activation>
  711. <properties>
  712. <require.bzip2>false</require.bzip2>
  713. <zstd.prefix></zstd.prefix>
  714. <zstd.lib></zstd.lib>
  715. <zstd.include></zstd.include>
  716. <require.zstd>false</require.zstd>
  717. <openssl.prefix></openssl.prefix>
  718. <openssl.lib></openssl.lib>
  719. <openssl.include></openssl.include>
  720. <require.isal>false</require.isal>
  721. <isal.prefix></isal.prefix>
  722. <isal.lib></isal.lib>
  723. <require.openssl>false</require.openssl>
  724. <runningWithNative>true</runningWithNative>
  725. <bundle.openssl.in.bin>false</bundle.openssl.in.bin>
  726. <extra.libhadoop.rpath></extra.libhadoop.rpath>
  727. </properties>
  728. <build>
  729. <plugins>
  730. <plugin>
  731. <groupId>org.apache.maven.plugins</groupId>
  732. <artifactId>maven-enforcer-plugin</artifactId>
  733. <executions>
  734. <execution>
  735. <id>enforce-os</id>
  736. <goals>
  737. <goal>enforce</goal>
  738. </goals>
  739. <configuration>
  740. <rules>
  741. <requireOS>
  742. <family>mac</family>
  743. <family>unix</family>
  744. <message>native build only supported on Mac or Unix</message>
  745. </requireOS>
  746. </rules>
  747. <fail>true</fail>
  748. </configuration>
  749. </execution>
  750. </executions>
  751. </plugin>
  752. <plugin>
  753. <groupId>org.apache.hadoop</groupId>
  754. <artifactId>hadoop-maven-plugins</artifactId>
  755. <executions>
  756. <execution>
  757. <id>cmake-compile</id>
  758. <phase>compile</phase>
  759. <goals><goal>cmake-compile</goal></goals>
  760. <configuration>
  761. <source>${basedir}/src</source>
  762. <vars>
  763. <GENERATED_JAVAH>${project.build.directory}/native/javah</GENERATED_JAVAH>
  764. <JVM_ARCH_DATA_MODEL>${sun.arch.data.model}</JVM_ARCH_DATA_MODEL>
  765. <REQUIRE_BZIP2>${require.bzip2}</REQUIRE_BZIP2>
  766. <REQUIRE_ZSTD>${require.zstd}</REQUIRE_ZSTD>
  767. <CUSTOM_ZSTD_PREFIX>${zstd.prefix}</CUSTOM_ZSTD_PREFIX>
  768. <CUSTOM_ZSTD_LIB>${zstd.lib} </CUSTOM_ZSTD_LIB>
  769. <CUSTOM_ZSTD_INCLUDE>${zstd.include} </CUSTOM_ZSTD_INCLUDE>
  770. <REQUIRE_ISAL>${require.isal} </REQUIRE_ISAL>
  771. <CUSTOM_ISAL_PREFIX>${isal.prefix} </CUSTOM_ISAL_PREFIX>
  772. <CUSTOM_ISAL_LIB>${isal.lib} </CUSTOM_ISAL_LIB>
  773. <REQUIRE_PMDK>${require.pmdk}</REQUIRE_PMDK>
  774. <CUSTOM_PMDK_LIB>${pmdk.lib}</CUSTOM_PMDK_LIB>
  775. <REQUIRE_OPENSSL>${require.openssl} </REQUIRE_OPENSSL>
  776. <CUSTOM_OPENSSL_PREFIX>${openssl.prefix} </CUSTOM_OPENSSL_PREFIX>
  777. <CUSTOM_OPENSSL_LIB>${openssl.lib} </CUSTOM_OPENSSL_LIB>
  778. <CUSTOM_OPENSSL_INCLUDE>${openssl.include} </CUSTOM_OPENSSL_INCLUDE>
  779. <EXTRA_LIBHADOOP_RPATH>${extra.libhadoop.rpath}</EXTRA_LIBHADOOP_RPATH>
  780. </vars>
  781. </configuration>
  782. </execution>
  783. <execution>
  784. <id>test_bulk_crc32</id>
  785. <goals><goal>cmake-test</goal></goals>
  786. <phase>test</phase>
  787. <configuration>
  788. <binary>${project.build.directory}/native/test_bulk_crc32</binary>
  789. <timeout>1200</timeout>
  790. <results>${project.build.directory}/native-results</results>
  791. </configuration>
  792. </execution>
  793. <execution>
  794. <id>erasure_code_test</id>
  795. <goals><goal>cmake-test</goal></goals>
  796. <phase>test</phase>
  797. <configuration>
  798. <binary>${project.build.directory}/native/erasure_code_test</binary>
  799. <timeout>300</timeout>
  800. <results>${project.build.directory}/native-results</results>
  801. <skipIfMissing>true</skipIfMissing>
  802. <env>
  803. <LD_LIBRARY_PATH>${LD_LIBRARY_PATH}:${isal.lib}:${isal.prefix}:/usr/lib</LD_LIBRARY_PATH>
  804. </env>
  805. </configuration>
  806. </execution>
  807. </executions>
  808. </plugin>
  809. </plugins>
  810. </build>
  811. </profile>
  812. <profile>
  813. <id>native-win</id>
  814. <activation>
  815. <os>
  816. <family>Windows</family>
  817. </os>
  818. </activation>
  819. <properties>
  820. <require.isal>false</require.isal>
  821. <isal.prefix></isal.prefix>
  822. <isal.lib></isal.lib>
  823. <zstd.prefix></zstd.prefix>
  824. <zstd.lib></zstd.lib>
  825. <zstd.include></zstd.include>
  826. <require.zstd>false</require.zstd>
  827. <bundle.zstd.in.bin>true</bundle.zstd.in.bin>
  828. <openssl.prefix></openssl.prefix>
  829. <openssl.lib></openssl.lib>
  830. <openssl.include></openssl.include>
  831. <require.openssl>false</require.openssl>
  832. <runningWithNative>true</runningWithNative>
  833. <bundle.openssl.in.bin>false</bundle.openssl.in.bin>
  834. </properties>
  835. <build>
  836. <plugins>
  837. <plugin>
  838. <groupId>org.apache.maven.plugins</groupId>
  839. <artifactId>maven-enforcer-plugin</artifactId>
  840. <executions>
  841. <execution>
  842. <id>enforce-os</id>
  843. <goals>
  844. <goal>enforce</goal>
  845. </goals>
  846. <configuration>
  847. <rules>
  848. <requireOS>
  849. <family>windows</family>
  850. <message>native-win build only supported on Windows</message>
  851. </requireOS>
  852. </rules>
  853. <fail>true</fail>
  854. </configuration>
  855. </execution>
  856. </executions>
  857. </plugin>
  858. <plugin>
  859. <!--Sets the skip.platformToolsetDetection to true if use.platformToolsetVersion is specified.
  860. This implies that the automatic detection of which platform toolset to use will be skipped
  861. and the one specified with use.platformToolsetVersion will be used.-->
  862. <groupId>org.apache.maven.plugins</groupId>
  863. <artifactId>maven-antrun-plugin</artifactId>
  864. <version>1.8</version>
  865. <executions>
  866. <execution>
  867. <phase>validate</phase>
  868. <goals>
  869. <goal>run</goal>
  870. </goals>
  871. <configuration>
  872. <exportAntProperties>true</exportAntProperties>
  873. <target>
  874. <condition property="skip.platformToolsetDetection" value="true" else="false">
  875. <isset property="use.platformToolsetVersion"/>
  876. </condition>
  877. <!--Unfortunately, Maven doesn't have a way to negate a flag, thus we declare a
  878. property which holds the negated value of skip.platformToolsetDetection.-->
  879. <condition property="skip.platformToolsetDetection.negated" value="false" else="true">
  880. <isset property="use.platformToolsetVersion"/>
  881. </condition>
  882. <echo>Skip platform toolset version detection = ${skip.platformToolsetDetection}</echo>
  883. </target>
  884. </configuration>
  885. </execution>
  886. </executions>
  887. </plugin>
  888. <plugin>
  889. <groupId>org.codehaus.mojo</groupId>
  890. <artifactId>exec-maven-plugin</artifactId>
  891. <executions>
  892. <execution>
  893. <id>convert-ms-winutils</id>
  894. <phase>generate-sources</phase>
  895. <goals>
  896. <goal>exec</goal>
  897. </goals>
  898. <configuration>
  899. <skip>${skip.platformToolsetDetection}</skip>
  900. <executable>${basedir}\..\..\dev-support\bin\win-vs-upgrade.cmd</executable>
  901. <arguments>
  902. <argument>${basedir}\src\main\winutils</argument>
  903. <argument>${project.build.directory}</argument>
  904. </arguments>
  905. </configuration>
  906. </execution>
  907. <execution>
  908. <id>compile-ms-winutils</id>
  909. <phase>compile</phase>
  910. <goals>
  911. <goal>exec</goal>
  912. </goals>
  913. <configuration>
  914. <skip>${skip.platformToolsetDetection}</skip>
  915. <executable>msbuild</executable>
  916. <arguments>
  917. <argument>${basedir}/src/main/winutils/winutils.sln</argument>
  918. <argument>/nologo</argument>
  919. <argument>/p:Configuration=Release</argument>
  920. <argument>/p:OutDir=${project.build.directory}/bin/</argument>
  921. <argument>/p:IntermediateOutputPath=${project.build.directory}/winutils/</argument>
  922. <argument>/p:WsceConfigDir=${wsce.config.dir}</argument>
  923. <argument>/p:WsceConfigFile=${wsce.config.file}</argument>
  924. </arguments>
  925. </configuration>
  926. </execution>
  927. <execution>
  928. <id>compile-ms-winutils-using-build-tools</id>
  929. <phase>compile</phase>
  930. <goals>
  931. <goal>exec</goal>
  932. </goals>
  933. <configuration>
  934. <skip>${skip.platformToolsetDetection.negated}</skip>
  935. <executable>msbuild</executable>
  936. <arguments>
  937. <argument>${basedir}/src/main/winutils/winutils.sln</argument>
  938. <argument>/nologo</argument>
  939. <argument>/p:Configuration=Release</argument>
  940. <argument>/p:OutDir=${project.build.directory}/bin/</argument>
  941. <argument>/p:IntermediateOutputPath=${project.build.directory}/winutils/</argument>
  942. <argument>/p:WsceConfigDir=${wsce.config.dir}</argument>
  943. <argument>/p:WsceConfigFile=${wsce.config.file}</argument>
  944. <argument>/p:PlatformToolset=${use.platformToolsetVersion}</argument>
  945. </arguments>
  946. </configuration>
  947. </execution>
  948. <execution>
  949. <id>convert-ms-native-dll</id>
  950. <phase>generate-sources</phase>
  951. <goals>
  952. <goal>exec</goal>
  953. </goals>
  954. <configuration>
  955. <skip>${skip.platformToolsetDetection}</skip>
  956. <executable>${basedir}\..\..\dev-support\bin\win-vs-upgrade.cmd</executable>
  957. <arguments>
  958. <argument>${basedir}\src\main\native</argument>
  959. <argument>${project.build.directory}</argument>
  960. </arguments>
  961. </configuration>
  962. </execution>
  963. <execution>
  964. <id>compile-ms-native-dll</id>
  965. <phase>compile</phase>
  966. <goals>
  967. <goal>exec</goal>
  968. </goals>
  969. <configuration>
  970. <skip>${skip.platformToolsetDetection}</skip>
  971. <executable>msbuild</executable>
  972. <arguments>
  973. <argument>${basedir}/src/main/native/native.sln</argument>
  974. <argument>/nologo</argument>
  975. <argument>/p:Configuration=Release</argument>
  976. <argument>/p:OutDir=${project.build.directory}/bin/</argument>
  977. <argument>/p:CustomZstdPrefix=${zstd.prefix}</argument>
  978. <argument>/p:CustomZstdLib=${zstd.lib}</argument>
  979. <argument>/p:CustomZstdInclude=${zstd.include}</argument>
  980. <argument>/p:RequireZstd=${require.zstd}</argument>
  981. <argument>/p:CustomOpensslPrefix=${openssl.prefix}</argument>
  982. <argument>/p:CustomOpensslLib=${openssl.lib}</argument>
  983. <argument>/p:CustomOpensslInclude=${openssl.include}</argument>
  984. <argument>/p:RequireOpenssl=${require.openssl}</argument>
  985. <argument>/p:RequireIsal=${require.isal}</argument>
  986. <argument>/p:CustomIsalPrefix=${isal.prefix}</argument>
  987. <argument>/p:CustomIsalLib=${isal.lib}</argument>
  988. </arguments>
  989. </configuration>
  990. </execution>
  991. <execution>
  992. <id>compile-ms-native-dll-using-build-tools</id>
  993. <phase>compile</phase>
  994. <goals>
  995. <goal>exec</goal>
  996. </goals>
  997. <configuration>
  998. <skip>${skip.platformToolsetDetection.negated}</skip>
  999. <executable>msbuild</executable>
  1000. <arguments>
  1001. <argument>${basedir}/src/main/native/native.sln</argument>
  1002. <argument>/nologo</argument>
  1003. <argument>/p:Configuration=Release</argument>
  1004. <argument>/p:OutDir=${project.build.directory}/bin/</argument>
  1005. <argument>/p:CustomZstdPrefix=${zstd.prefix}</argument>
  1006. <argument>/p:CustomZstdLib=${zstd.lib}</argument>
  1007. <argument>/p:CustomZstdInclude=${zstd.include}</argument>
  1008. <argument>/p:RequireZstd=${require.zstd}</argument>
  1009. <argument>/p:CustomOpensslPrefix=${openssl.prefix}</argument>
  1010. <argument>/p:CustomOpensslLib=${openssl.lib}</argument>
  1011. <argument>/p:CustomOpensslInclude=${openssl.include}</argument>
  1012. <argument>/p:RequireOpenssl=${require.openssl}</argument>
  1013. <argument>/p:RequireIsal=${require.isal}</argument>
  1014. <argument>/p:CustomIsalPrefix=${isal.prefix}</argument>
  1015. <argument>/p:CustomIsalLib=${isal.lib}</argument>
  1016. <argument>/p:PlatformToolset=${use.platformToolsetVersion}</argument>
  1017. </arguments>
  1018. </configuration>
  1019. </execution>
  1020. </executions>
  1021. </plugin>
  1022. </plugins>
  1023. </build>
  1024. </profile>
  1025. <profile>
  1026. <id>parallel-tests</id>
  1027. <build>
  1028. <plugins>
  1029. <plugin>
  1030. <groupId>org.apache.hadoop</groupId>
  1031. <artifactId>hadoop-maven-plugins</artifactId>
  1032. <executions>
  1033. <execution>
  1034. <id>parallel-tests-createdir</id>
  1035. <phase>process-test-resources</phase>
  1036. <goals>
  1037. <goal>parallel-tests-createdir</goal>
  1038. </goals>
  1039. <configuration>
  1040. <testBuildData>${test.build.data}</testBuildData>
  1041. </configuration>
  1042. </execution>
  1043. </executions>
  1044. </plugin>
  1045. <plugin>
  1046. <groupId>org.apache.maven.plugins</groupId>
  1047. <artifactId>maven-surefire-plugin</artifactId>
  1048. <configuration>
  1049. <forkCount>${testsThreadCount}</forkCount>
  1050. <reuseForks>false</reuseForks>
  1051. <argLine>${maven-surefire-plugin.argLine} -DminiClusterDedicatedDirs=true</argLine>
  1052. <systemPropertyVariables>
  1053. <testsThreadCount>${testsThreadCount}</testsThreadCount>
  1054. <test.build.data>${test.build.data}/${surefire.forkNumber}</test.build.data>
  1055. <test.build.dir>${test.build.dir}/${surefire.forkNumber}</test.build.dir>
  1056. <hadoop.tmp.dir>${hadoop.tmp.dir}/${surefire.forkNumber}</hadoop.tmp.dir>
  1057. <!-- Due to a Maven quirk, setting this to just -->
  1058. <!-- surefire.forkNumber won't do the parameter substitution. -->
  1059. <!-- Putting a prefix in front of it like "fork-" makes it -->
  1060. <!-- work. -->
  1061. <test.unique.fork.id>fork-${surefire.forkNumber}</test.unique.fork.id>
  1062. </systemPropertyVariables>
  1063. </configuration>
  1064. </plugin>
  1065. </plugins>
  1066. </build>
  1067. </profile>
  1068. <profile>
  1069. <id>releasedocs</id>
  1070. <activation>
  1071. <activeByDefault>false</activeByDefault>
  1072. </activation>
  1073. <build>
  1074. <plugins>
  1075. <plugin>
  1076. <groupId>org.codehaus.mojo</groupId>
  1077. <artifactId>exec-maven-plugin</artifactId>
  1078. <executions>
  1079. <execution>
  1080. <id>releasedocs</id>
  1081. <phase>pre-site</phase>
  1082. <goals>
  1083. <goal>exec</goal>
  1084. </goals>
  1085. <configuration>
  1086. <executable>${basedir}/../../dev-support/bin/releasedocmaker</executable>
  1087. <arguments>
  1088. <argument>--index</argument>
  1089. <argument>--license</argument>
  1090. <argument>--outputdir</argument>
  1091. <argument>${basedir}/src/site/markdown/release</argument>
  1092. <argument>--project</argument>
  1093. <argument>HADOOP</argument>
  1094. <argument>--project</argument>
  1095. <argument>HDFS</argument>
  1096. <argument>--project</argument>
  1097. <argument>MAPREDUCE</argument>
  1098. <argument>--project</argument>
  1099. <argument>YARN</argument>
  1100. <argument>--projecttitle</argument>
  1101. <argument>Apache Hadoop</argument>
  1102. <argument>--usetoday</argument>
  1103. <argument>--fileversions</argument>
  1104. <argument>--dirversions</argument>
  1105. <argument>--version</argument>
  1106. <argument>${project.version}</argument>
  1107. </arguments>
  1108. </configuration>
  1109. </execution>
  1110. </executions>
  1111. </plugin>
  1112. <plugin>
  1113. <artifactId>maven-clean-plugin</artifactId>
  1114. <configuration>
  1115. <filesets>
  1116. <fileset>
  1117. <directory>src/site/markdown/release</directory>
  1118. <includes>
  1119. <include>${project.version}/</include>
  1120. <include>index.md</include>
  1121. </includes>
  1122. <followSymlinks>false</followSymlinks>
  1123. </fileset>
  1124. </filesets>
  1125. </configuration>
  1126. </plugin>
  1127. </plugins>
  1128. </build>
  1129. </profile>
  1130. <!-- profile to test shell code -->
  1131. <profile>
  1132. <id>shelltest</id>
  1133. <activation>
  1134. <property>
  1135. <name>!skipTests</name>
  1136. </property>
  1137. </activation>
  1138. <build>
  1139. <plugins>
  1140. <plugin>
  1141. <artifactId>maven-antrun-plugin</artifactId>
  1142. <executions>
  1143. <execution>
  1144. <id>common-test-bats-driver</id>
  1145. <phase>test</phase>
  1146. <goals>
  1147. <goal>run</goal>
  1148. </goals>
  1149. <configuration>
  1150. <target>
  1151. <exec dir="src/test/scripts"
  1152. executable="bash"
  1153. failonerror="true">
  1154. <arg value="./run-bats.sh" />
  1155. </exec>
  1156. </target>
  1157. </configuration>
  1158. </execution>
  1159. </executions>
  1160. </plugin>
  1161. </plugins>
  1162. </build>
  1163. </profile>
  1164. <!-- profile to use already generated protobuf code using 2.5.0 for aarch64-->
  1165. <profile>
  1166. <id>aarch64</id>
  1167. <activation>
  1168. <activeByDefault>false</activeByDefault>
  1169. <os>
  1170. <arch>aarch64</arch>
  1171. </os>
  1172. </activation>
  1173. <build>
  1174. <plugins>
  1175. <plugin>
  1176. <groupId>org.codehaus.mojo</groupId>
  1177. <artifactId>build-helper-maven-plugin</artifactId>
  1178. <executions>
  1179. <execution>
  1180. <id>add-source-legacy-protobuf</id>
  1181. <phase>generate-sources</phase>
  1182. <goals>
  1183. <goal>add-source</goal>
  1184. </goals>
  1185. <configuration>
  1186. <sources>
  1187. <source>${basedir}/src/main/arm-java</source>
  1188. </sources>
  1189. </configuration>
  1190. </execution>
  1191. <execution>
  1192. <id>add-test-source-legacy-protobuf</id>
  1193. <phase>generate-test-sources</phase>
  1194. <goals>
  1195. <goal>add-test-source</goal>
  1196. </goals>
  1197. <configuration>
  1198. <sources>
  1199. <source>${basedir}/src/test/arm-java</source>
  1200. </sources>
  1201. </configuration>
  1202. </execution>
  1203. </executions>
  1204. </plugin>
  1205. </plugins>
  1206. </build>
  1207. </profile>
  1208. <!-- profile to generate protobuf code using 2.5.0-->
  1209. <profile>
  1210. <id>x86_64</id>
  1211. <activation>
  1212. <activeByDefault>false</activeByDefault>
  1213. <os>
  1214. <arch>!aarch64</arch>
  1215. </os>
  1216. </activation>
  1217. <build>
  1218. <plugins>
  1219. <plugin>
  1220. <groupId>org.xolstice.maven.plugins</groupId>
  1221. <artifactId>protobuf-maven-plugin</artifactId>
  1222. <executions>
  1223. <execution>
  1224. <id>src-compile-protoc-legacy</id>
  1225. <phase>generate-sources</phase>
  1226. <goals>
  1227. <goal>compile</goal>
  1228. </goals>
  1229. <configuration>
  1230. <skip>false</skip>
  1231. <!--Generating with old protobuf version for backward compatibility-->
  1232. <protocArtifact>
  1233. com.google.protobuf:protoc:${protobuf.version}:exe:${os.detected.classifier}
  1234. </protocArtifact>
  1235. <includeDependenciesInDescriptorSet>false</includeDependenciesInDescriptorSet>
  1236. <protoSourceRoot>${basedir}/src/main/proto</protoSourceRoot>
  1237. <outputDirectory>${project.build.directory}/generated-sources/java</outputDirectory>
  1238. <clearOutputDirectory>false</clearOutputDirectory>
  1239. <includes>
  1240. <include>ProtobufRpcEngine.proto</include>
  1241. </includes>
  1242. </configuration>
  1243. </execution>
  1244. <execution>
  1245. <id>src-test-compile-protoc-legacy</id>
  1246. <phase>generate-test-sources</phase>
  1247. <goals>
  1248. <goal>test-compile</goal>
  1249. </goals>
  1250. <configuration>
  1251. <skip>false</skip>
  1252. <!--Generating with old protobuf version for backward compatibility-->
  1253. <protocArtifact>
  1254. com.google.protobuf:protoc:${protobuf.version}:exe:${os.detected.classifier}
  1255. </protocArtifact>
  1256. <includeDependenciesInDescriptorSet>false</includeDependenciesInDescriptorSet>
  1257. <protoTestSourceRoot>${basedir}/src/test/proto</protoTestSourceRoot>
  1258. <outputDirectory>${project.build.directory}/generated-test-sources/java</outputDirectory>
  1259. <clearOutputDirectory>false</clearOutputDirectory>
  1260. <includes>
  1261. <include>test_legacy.proto</include>
  1262. <include>test_rpc_service_legacy.proto</include>
  1263. </includes>
  1264. </configuration>
  1265. </execution>
  1266. </executions>
  1267. </plugin>
  1268. <plugin>
  1269. <groupId>org.apache.maven.plugins</groupId>
  1270. <artifactId>maven-javadoc-plugin</artifactId>
  1271. <configuration>
  1272. <sourceFileExcludes>
  1273. <sourceFileExclude>**/FSProtos.java</sourceFileExclude>
  1274. </sourceFileExcludes>
  1275. <excludePackageNames>*.proto:*.tracing:*.protobuf</excludePackageNames>
  1276. </configuration>
  1277. </plugin>
  1278. </plugins>
  1279. </build>
  1280. </profile>
  1281. </profiles>
  1282. </project>