pom.xml 18 KB

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