pom.xml 18 KB

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