pom.xml 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530
  1. <?xml version="1.0"?>
  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. <parent>
  18. <artifactId>hadoop-yarn-server</artifactId>
  19. <groupId>org.apache.hadoop</groupId>
  20. <version>3.5.0-SNAPSHOT</version>
  21. </parent>
  22. <modelVersion>4.0.0</modelVersion>
  23. <artifactId>hadoop-yarn-server-resourcemanager</artifactId>
  24. <version>3.5.0-SNAPSHOT</version>
  25. <name>Apache Hadoop YARN ResourceManager</name>
  26. <properties>
  27. <!-- Needed for generating FindBugs warnings using parent pom -->
  28. <yarn.basedir>${project.parent.parent.basedir}</yarn.basedir>
  29. </properties>
  30. <dependencies>
  31. <dependency>
  32. <groupId>javax.servlet</groupId>
  33. <artifactId>javax.servlet-api</artifactId>
  34. </dependency>
  35. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  36. <dependency>
  37. <groupId>org.apache.hadoop</groupId>
  38. <artifactId>hadoop-common</artifactId>
  39. <scope>provided</scope>
  40. </dependency>
  41. <dependency>
  42. <groupId>org.slf4j</groupId>
  43. <artifactId>slf4j-api</artifactId>
  44. </dependency>
  45. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  46. <dependency>
  47. <groupId>org.apache.hadoop</groupId>
  48. <artifactId>hadoop-annotations</artifactId>
  49. </dependency>
  50. <dependency>
  51. <groupId>junit</groupId>
  52. <artifactId>junit</artifactId>
  53. <scope>test</scope>
  54. </dependency>
  55. <dependency>
  56. <groupId>org.assertj</groupId>
  57. <artifactId>assertj-core</artifactId>
  58. <scope>test</scope>
  59. </dependency>
  60. <dependency>
  61. <groupId>org.mockito</groupId>
  62. <artifactId>mockito-core</artifactId>
  63. <scope>test</scope>
  64. </dependency>
  65. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  66. <dependency>
  67. <groupId>org.apache.hadoop</groupId>
  68. <artifactId>hadoop-common</artifactId>
  69. <type>test-jar</type>
  70. <scope>test</scope>
  71. </dependency>
  72. <dependency>
  73. <groupId>com.google.inject.extensions</groupId>
  74. <artifactId>guice-servlet</artifactId>
  75. </dependency>
  76. <dependency>
  77. <groupId>com.google.protobuf</groupId>
  78. <artifactId>protobuf-java</artifactId>
  79. <scope>${transient.protobuf2.scope}</scope>
  80. </dependency>
  81. <dependency>
  82. <groupId>commons-io</groupId>
  83. <artifactId>commons-io</artifactId>
  84. </dependency>
  85. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  86. <dependency>
  87. <groupId>org.apache.hadoop</groupId>
  88. <artifactId>hadoop-hdfs</artifactId>
  89. <scope>test</scope>
  90. </dependency>
  91. <dependency>
  92. <groupId>org.apache.hadoop</groupId>
  93. <artifactId>hadoop-hdfs-client</artifactId>
  94. <scope>test</scope>
  95. </dependency>
  96. <dependency>
  97. <groupId>com.google.inject</groupId>
  98. <artifactId>guice</artifactId>
  99. </dependency>
  100. <dependency>
  101. <groupId>com.sun.jersey.jersey-test-framework</groupId>
  102. <artifactId>jersey-test-framework-core</artifactId>
  103. <scope>test</scope>
  104. </dependency>
  105. <dependency>
  106. <groupId>com.github.pjfanning</groupId>
  107. <artifactId>jersey-json</artifactId>
  108. <exclusions>
  109. <exclusion>
  110. <groupId>com.fasterxml.jackson.core</groupId>
  111. <artifactId>jackson-core</artifactId>
  112. </exclusion>
  113. <exclusion>
  114. <groupId>com.fasterxml.jackson.core</groupId>
  115. <artifactId>jackson-databind</artifactId>
  116. </exclusion>
  117. <exclusion>
  118. <groupId>com.fasterxml.jackson.jaxrs</groupId>
  119. <artifactId>jackson-jaxrs-json-provider</artifactId>
  120. </exclusion>
  121. <exclusion>
  122. <groupId>org.codehaus.jettison</groupId>
  123. <artifactId>jettison</artifactId>
  124. </exclusion>
  125. </exclusions>
  126. </dependency>
  127. <dependency>
  128. <groupId>com.sun.jersey.contribs</groupId>
  129. <artifactId>jersey-guice</artifactId>
  130. </dependency>
  131. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  132. <dependency>
  133. <groupId>org.apache.hadoop</groupId>
  134. <artifactId>hadoop-yarn-common</artifactId>
  135. <type>test-jar</type>
  136. <scope>test</scope>
  137. </dependency>
  138. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  139. <dependency>
  140. <groupId>org.apache.hadoop</groupId>
  141. <artifactId>hadoop-yarn-common</artifactId>
  142. </dependency>
  143. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  144. <dependency>
  145. <groupId>org.apache.hadoop</groupId>
  146. <artifactId>hadoop-yarn-api</artifactId>
  147. </dependency>
  148. <dependency>
  149. <groupId>javax.xml.bind</groupId>
  150. <artifactId>jaxb-api</artifactId>
  151. </dependency>
  152. <dependency>
  153. <groupId>org.codehaus.jettison</groupId>
  154. <artifactId>jettison</artifactId>
  155. </dependency>
  156. <dependency>
  157. <groupId>com.sun.jersey</groupId>
  158. <artifactId>jersey-core</artifactId>
  159. </dependency>
  160. <dependency>
  161. <groupId>com.sun.jersey</groupId>
  162. <artifactId>jersey-client</artifactId>
  163. </dependency>
  164. <dependency>
  165. <groupId>org.eclipse.jetty</groupId>
  166. <artifactId>jetty-util</artifactId>
  167. </dependency>
  168. <dependency>
  169. <groupId>org.eclipse.jetty</groupId>
  170. <artifactId>jetty-util-ajax</artifactId>
  171. </dependency>
  172. <dependency>
  173. <groupId>org.apache.hadoop.thirdparty</groupId>
  174. <artifactId>hadoop-shaded-guava</artifactId>
  175. </dependency>
  176. <dependency>
  177. <groupId>log4j</groupId>
  178. <artifactId>log4j</artifactId>
  179. </dependency>
  180. <dependency>
  181. <groupId>org.apache.hadoop</groupId>
  182. <artifactId>hadoop-yarn-server-timelineservice</artifactId>
  183. <scope>test</scope>
  184. <type>test-jar</type>
  185. </dependency>
  186. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  187. <dependency>
  188. <groupId>org.apache.hadoop</groupId>
  189. <artifactId>hadoop-yarn-server-common</artifactId>
  190. </dependency>
  191. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  192. <dependency>
  193. <groupId>org.apache.hadoop</groupId>
  194. <artifactId>hadoop-yarn-server-applicationhistoryservice</artifactId>
  195. <version>${project.version}</version>
  196. </dependency>
  197. <dependency>
  198. <groupId>org.apache.hadoop</groupId>
  199. <artifactId>hadoop-yarn-server-timelineservice</artifactId>
  200. <scope>provided</scope>
  201. </dependency>
  202. <dependency>
  203. <groupId>org.apache.hadoop</groupId>
  204. <artifactId>hadoop-yarn-server-web-proxy</artifactId>
  205. </dependency>
  206. <dependency>
  207. <groupId>org.apache.curator</groupId>
  208. <artifactId>curator-client</artifactId>
  209. </dependency>
  210. <dependency>
  211. <groupId>org.apache.curator</groupId>
  212. <artifactId>curator-test</artifactId>
  213. <scope>test</scope>
  214. </dependency>
  215. <dependency>
  216. <groupId>org.apache.zookeeper</groupId>
  217. <artifactId>zookeeper</artifactId>
  218. </dependency>
  219. <dependency>
  220. <groupId>io.dropwizard.metrics</groupId>
  221. <artifactId>metrics-core</artifactId>
  222. </dependency>
  223. <dependency>
  224. <groupId>org.xerial.snappy</groupId>
  225. <artifactId>snappy-java</artifactId>
  226. <scope>provided</scope>
  227. </dependency>
  228. <dependency>
  229. <groupId>${leveldbjni.group}</groupId>
  230. <artifactId>leveldbjni-all</artifactId>
  231. </dependency>
  232. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  233. <dependency>
  234. <groupId>org.apache.zookeeper</groupId>
  235. <artifactId>zookeeper</artifactId>
  236. <scope>test</scope>
  237. <type>test-jar</type>
  238. </dependency>
  239. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  240. <dependency>
  241. <groupId>org.apache.hadoop</groupId>
  242. <artifactId>hadoop-hdfs</artifactId>
  243. <type>test-jar</type>
  244. <scope>test</scope>
  245. </dependency>
  246. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  247. <dependency>
  248. <groupId>org.apache.hadoop</groupId>
  249. <artifactId>hadoop-minikdc</artifactId>
  250. <scope>test</scope>
  251. </dependency>
  252. <dependency>
  253. <groupId>org.apache.hadoop</groupId>
  254. <artifactId>hadoop-auth</artifactId>
  255. <scope>test</scope>
  256. <type>test-jar</type>
  257. <version>${project.version}</version>
  258. </dependency>
  259. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  260. <dependency>
  261. <groupId>com.sun.jersey.jersey-test-framework</groupId>
  262. <artifactId>jersey-test-framework-grizzly2</artifactId>
  263. <scope>test</scope>
  264. </dependency>
  265. <dependency>
  266. <groupId>com.github.stefanbirkner</groupId>
  267. <artifactId>system-rules</artifactId>
  268. <scope>test</scope>
  269. </dependency>
  270. <!-- Necessary to include jackson separately to avoid issues with
  271. maven enforcer plugin in "hadoop-client-check-test-invariants"
  272. -->
  273. <dependency>
  274. <groupId>org.jsonschema2pojo</groupId>
  275. <artifactId>jsonschema2pojo-core</artifactId>
  276. <exclusions>
  277. <exclusion>
  278. <groupId>joda-time</groupId>
  279. <artifactId>joda-time</artifactId>
  280. </exclusion>
  281. <exclusion>
  282. <groupId>com.google.code.findbugs</groupId>
  283. <artifactId>jsr305</artifactId>
  284. </exclusion>
  285. <exclusion>
  286. <groupId>com.fasterxml.jackson.core</groupId>
  287. <artifactId>*</artifactId>
  288. </exclusion>
  289. <exclusion>
  290. <groupId>com.fasterxml.jackson.dataformat</groupId>
  291. <artifactId>*</artifactId>
  292. </exclusion>
  293. <exclusion>
  294. <groupId>org.codehaus.jackson</groupId>
  295. <artifactId>*</artifactId>
  296. </exclusion>
  297. <exclusion>
  298. <groupId>com.google.code.gson</groupId>
  299. <artifactId>gson</artifactId>
  300. </exclusion>
  301. <exclusion>
  302. <groupId>com.google.code.findbugs</groupId>
  303. <artifactId>annotations</artifactId>
  304. </exclusion>
  305. <exclusion>
  306. <groupId>org.scala-lang</groupId>
  307. <artifactId>scala-library</artifactId>
  308. </exclusion>
  309. <exclusion>
  310. <groupId>org.jsonschema2pojo</groupId>
  311. <artifactId>jsonschema2pojo-scalagen</artifactId>
  312. </exclusion>
  313. <exclusion>
  314. <groupId>com.google.code.javaparser</groupId>
  315. <artifactId>javaparser</artifactId>
  316. </exclusion>
  317. <exclusion>
  318. <groupId>javax.validation</groupId>
  319. <artifactId>validation-api</artifactId>
  320. </exclusion>
  321. </exclusions>
  322. </dependency>
  323. <dependency>
  324. <groupId>com.fasterxml.jackson.core</groupId>
  325. <artifactId>jackson-databind</artifactId>
  326. </dependency>
  327. </dependencies>
  328. <build>
  329. <testResources>
  330. <testResource>
  331. <directory>${basedir}/src/test/resources</directory>
  332. </testResource>
  333. <testResource>
  334. <directory>${basedir}/conf</directory>
  335. <includes>
  336. <include>capacity-scheduler.xml</include>
  337. </includes>
  338. </testResource>
  339. </testResources>
  340. <plugins>
  341. <!-- Publish tests jar -->
  342. <plugin>
  343. <artifactId>maven-jar-plugin</artifactId>
  344. <executions>
  345. <execution>
  346. <goals>
  347. <goal>test-jar</goal>
  348. </goals>
  349. <phase>test-compile</phase>
  350. <configuration>
  351. <archive>
  352. <manifest>
  353. <mainClass>org.apache.hadoop.test.YarnTestDriver</mainClass>
  354. </manifest>
  355. </archive>
  356. <excludes>
  357. <exclude>**/core-site.xml</exclude>
  358. <exclude>**/yarn-site.xml</exclude>
  359. </excludes>
  360. </configuration>
  361. </execution>
  362. </executions>
  363. </plugin>
  364. <plugin>
  365. <groupId>org.xolstice.maven.plugins</groupId>
  366. <artifactId>protobuf-maven-plugin</artifactId>
  367. <executions>
  368. <execution>
  369. <id>src-compile-protoc</id>
  370. <configuration>
  371. <skip>false</skip>
  372. <additionalProtoPathElements>
  373. <additionalProtoPathElement>
  374. ${basedir}/../../../../hadoop-common-project/hadoop-common/src/main/proto
  375. </additionalProtoPathElement>
  376. <additionalProtoPathElement>
  377. ${basedir}/../../hadoop-yarn-api/src/main/proto
  378. </additionalProtoPathElement>
  379. <additionalProtoPathElement>
  380. ${basedir}/../../hadoop-yarn-common/src/main/proto
  381. </additionalProtoPathElement>
  382. <additionalProtoPathElement>
  383. ${basedir}/../hadoop-yarn-server-common/src/main/proto
  384. </additionalProtoPathElement>
  385. </additionalProtoPathElements>
  386. </configuration>
  387. </execution>
  388. <execution>
  389. <id>src-test-compile-protoc</id>
  390. <configuration>
  391. <skip>false</skip>
  392. <additionalProtoPathElements>
  393. <additionalProtoPathElement>
  394. ${basedir}/../../../../hadoop-common-project/hadoop-common/src/main/proto
  395. </additionalProtoPathElement>
  396. <additionalProtoPathElement>
  397. ${basedir}/../../hadoop-yarn-api/src/main/proto
  398. </additionalProtoPathElement>
  399. </additionalProtoPathElements>
  400. </configuration>
  401. </execution>
  402. </executions>
  403. </plugin>
  404. <plugin>
  405. <groupId>com.google.code.maven-replacer-plugin</groupId>
  406. <artifactId>replacer</artifactId>
  407. <executions>
  408. <execution>
  409. <id>replace-generated-sources</id>
  410. <configuration>
  411. <skip>false</skip>
  412. </configuration>
  413. </execution>
  414. <execution>
  415. <id>replace-sources</id>
  416. <configuration>
  417. <skip>false</skip>
  418. </configuration>
  419. </execution>
  420. <execution>
  421. <id>replace-generated-test-sources</id>
  422. <configuration>
  423. <skip>false</skip>
  424. </configuration>
  425. </execution>
  426. <execution>
  427. <id>replace-test-sources</id>
  428. <configuration>
  429. <skip>false</skip>
  430. </configuration>
  431. </execution>
  432. </executions>
  433. </plugin>
  434. <plugin>
  435. <groupId>org.apache.rat</groupId>
  436. <artifactId>apache-rat-plugin</artifactId>
  437. <configuration>
  438. <excludes>
  439. <exclude>src/test/resources/submit-reservation.json</exclude>
  440. <exclude>src/test/resources/delete-reservation.json</exclude>
  441. <exclude>src/test/resources/update-reservation.json</exclude>
  442. <exclude>src/test/resources/invariants.txt</exclude>
  443. <exclude>src/test/resources/invariants_jdk9.txt</exclude>
  444. <exclude>src/test/resources/profiles/sample-profiles-1.json</exclude>
  445. <exclude>src/test/resources/profiles/sample-profiles-2.json</exclude>
  446. <exclude>src/test/resources/profiles/illegal-profiles-1.json</exclude>
  447. <exclude>src/test/resources/profiles/illegal-profiles-2.json</exclude>
  448. <exclude>src/test/resources/profiles/illegal-profiles-3.json</exclude>
  449. <!-- these two files are generated by jsonschema2pojo
  450. during build time -->
  451. <exclude>src/main/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/placement/schema/MappingRulesDescription.java</exclude>
  452. <exclude>src/main/java/org/apache/hadoop/yarn/server/resourcemanager/scheduler/capacity/placement/schema/Rule.java</exclude>
  453. <exclude>src/test/resources/webapp/*.json</exclude>
  454. <exclude>src/test/resources/webapp/*.xml</exclude>
  455. </excludes>
  456. </configuration>
  457. </plugin>
  458. <plugin>
  459. <groupId>org.jsonschema2pojo</groupId>
  460. <artifactId>jsonschema2pojo-maven-plugin</artifactId>
  461. <configuration>
  462. <sourceDirectory>${basedir}/src/main/json_schema</sourceDirectory>
  463. <targetPackage>org.apache.hadoop.yarn.server.resourcemanager.scheduler.capacity.placement.schema</targetPackage>
  464. <outputDirectory>${basedir}/src/main/java</outputDirectory>
  465. </configuration>
  466. <executions>
  467. <execution>
  468. <goals>
  469. <goal>generate</goal>
  470. </goals>
  471. </execution>
  472. </executions>
  473. </plugin>
  474. </plugins>
  475. </build>
  476. <profiles>
  477. <profile>
  478. <id>visualize</id>
  479. <activation>
  480. <activeByDefault>false</activeByDefault>
  481. </activation>
  482. <build>
  483. <plugins>
  484. <plugin>
  485. <groupId>org.codehaus.mojo</groupId>
  486. <artifactId>exec-maven-plugin</artifactId>
  487. <executions>
  488. <execution>
  489. <phase>compile</phase>
  490. <goals>
  491. <goal>java</goal>
  492. </goals>
  493. <configuration>
  494. <mainClass>org.apache.hadoop.yarn.state.VisualizeStateMachine</mainClass>
  495. <classpathScope>compile</classpathScope>
  496. <arguments>
  497. <argument>ResourceManager</argument>
  498. <argument>org.apache.hadoop.yarn.server.resourcemanager.recovery.RMStateStore,
  499. org.apache.hadoop.yarn.server.resourcemanager.rmapp.attempt.RMAppAttemptImpl,
  500. org.apache.hadoop.yarn.server.resourcemanager.rmapp.RMAppImpl,
  501. org.apache.hadoop.yarn.server.resourcemanager.rmcontainer.RMContainerImpl,
  502. org.apache.hadoop.yarn.server.resourcemanager.rmnode.RMNodeImpl</argument>
  503. <argument>ResourceManager.gv</argument>
  504. </arguments>
  505. </configuration>
  506. </execution>
  507. </executions>
  508. </plugin>
  509. </plugins>
  510. </build>
  511. </profile>
  512. </profiles>
  513. </project>