pom.xml 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428
  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-nodemanager</artifactId>
  24. <version>3.5.0-SNAPSHOT</version>
  25. <name>Apache Hadoop YARN NodeManager</name>
  26. <properties>
  27. <!-- Basedir eeded for generating FindBugs warnings using parent pom -->
  28. <yarn.basedir>${project.parent.parent.basedir}</yarn.basedir>
  29. <container-executor.conf.dir>../etc/hadoop</container-executor.conf.dir>
  30. <container-executor.additional_cflags></container-executor.additional_cflags>
  31. </properties>
  32. <dependencies>
  33. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  34. <dependency>
  35. <groupId>org.apache.hadoop</groupId>
  36. <artifactId>hadoop-common</artifactId>
  37. <scope>provided</scope>
  38. </dependency>
  39. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  40. <dependency>
  41. <groupId>org.apache.hadoop</groupId>
  42. <artifactId>hadoop-yarn-common</artifactId>
  43. </dependency>
  44. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  45. <dependency>
  46. <groupId>org.apache.hadoop</groupId>
  47. <artifactId>hadoop-yarn-api</artifactId>
  48. </dependency>
  49. <dependency>
  50. <groupId>org.apache.hadoop</groupId>
  51. <artifactId>hadoop-registry</artifactId>
  52. </dependency>
  53. <dependency>
  54. <groupId>javax.xml.bind</groupId>
  55. <artifactId>jaxb-api</artifactId>
  56. </dependency>
  57. <dependency>
  58. <groupId>org.codehaus.jettison</groupId>
  59. <artifactId>jettison</artifactId>
  60. </dependency>
  61. <dependency>
  62. <groupId>javax.servlet</groupId>
  63. <artifactId>javax.servlet-api</artifactId>
  64. </dependency>
  65. <dependency>
  66. <groupId>commons-codec</groupId>
  67. <artifactId>commons-codec</artifactId>
  68. </dependency>
  69. <dependency>
  70. <groupId>com.sun.jersey</groupId>
  71. <artifactId>jersey-core</artifactId>
  72. </dependency>
  73. <dependency>
  74. <groupId>com.sun.jersey</groupId>
  75. <artifactId>jersey-client</artifactId>
  76. </dependency>
  77. <dependency>
  78. <groupId>org.eclipse.jetty</groupId>
  79. <artifactId>jetty-util</artifactId>
  80. </dependency>
  81. <dependency>
  82. <groupId>org.eclipse.jetty.websocket</groupId>
  83. <artifactId>javax-websocket-server-impl</artifactId>
  84. </dependency>
  85. <dependency>
  86. <groupId>org.apache.hadoop.thirdparty</groupId>
  87. <artifactId>hadoop-shaded-guava</artifactId>
  88. </dependency>
  89. <dependency>
  90. <groupId>org.slf4j</groupId>
  91. <artifactId>slf4j-api</artifactId>
  92. </dependency>
  93. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  94. <dependency>
  95. <groupId>org.apache.hadoop</groupId>
  96. <artifactId>hadoop-annotations</artifactId>
  97. </dependency>
  98. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  99. <dependency>
  100. <groupId>org.apache.hadoop</groupId>
  101. <artifactId>hadoop-common</artifactId>
  102. <type>test-jar</type>
  103. <scope>test</scope>
  104. </dependency>
  105. <dependency>
  106. <groupId>com.google.inject.extensions</groupId>
  107. <artifactId>guice-servlet</artifactId>
  108. </dependency>
  109. <dependency>
  110. <groupId>io.dropwizard.metrics</groupId>
  111. <artifactId>metrics-core</artifactId>
  112. </dependency>
  113. <dependency>
  114. <groupId>junit</groupId>
  115. <artifactId>junit</artifactId>
  116. <scope>test</scope>
  117. </dependency>
  118. <dependency>
  119. <groupId>org.junit.jupiter</groupId>
  120. <artifactId>junit-jupiter-params</artifactId>
  121. <scope>test</scope>
  122. </dependency>
  123. <dependency>
  124. <groupId>org.mockito</groupId>
  125. <artifactId>mockito-core</artifactId>
  126. <scope>test</scope>
  127. </dependency>
  128. <dependency>
  129. <groupId>org.assertj</groupId>
  130. <artifactId>assertj-core</artifactId>
  131. <scope>test</scope>
  132. </dependency>
  133. <dependency>
  134. <groupId>com.google.inject</groupId>
  135. <artifactId>guice</artifactId>
  136. </dependency>
  137. <dependency>
  138. <groupId>com.sun.jersey.jersey-test-framework</groupId>
  139. <artifactId>jersey-test-framework-grizzly2</artifactId>
  140. <scope>test</scope>
  141. </dependency>
  142. <dependency>
  143. <groupId>com.github.pjfanning</groupId>
  144. <artifactId>jersey-json</artifactId>
  145. <exclusions>
  146. <exclusion>
  147. <groupId>com.fasterxml.jackson.core</groupId>
  148. <artifactId>jackson-core</artifactId>
  149. </exclusion>
  150. <exclusion>
  151. <groupId>com.fasterxml.jackson.core</groupId>
  152. <artifactId>jackson-databind</artifactId>
  153. </exclusion>
  154. <exclusion>
  155. <groupId>com.fasterxml.jackson.jaxrs</groupId>
  156. <artifactId>jackson-jaxrs-json-provider</artifactId>
  157. </exclusion>
  158. <exclusion>
  159. <groupId>org.codehaus.jettison</groupId>
  160. <artifactId>jettison</artifactId>
  161. </exclusion>
  162. </exclusions>
  163. </dependency>
  164. <dependency>
  165. <groupId>com.sun.jersey.contribs</groupId>
  166. <artifactId>jersey-guice</artifactId>
  167. </dependency>
  168. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  169. <dependency>
  170. <groupId>org.apache.hadoop</groupId>
  171. <artifactId>hadoop-yarn-common</artifactId>
  172. <type>test-jar</type>
  173. <scope>test</scope>
  174. </dependency>
  175. <!-- 'mvn dependency:analyze' fails to detect use of this dependency -->
  176. <dependency>
  177. <groupId>org.apache.hadoop</groupId>
  178. <artifactId>hadoop-yarn-server-common</artifactId>
  179. </dependency>
  180. <dependency>
  181. <groupId>${leveldbjni.group}</groupId>
  182. <artifactId>leveldbjni-all</artifactId>
  183. </dependency>
  184. <dependency>
  185. <groupId>net.java.dev.jna</groupId>
  186. <artifactId>jna</artifactId>
  187. </dependency>
  188. <dependency>
  189. <groupId>org.apache.hadoop</groupId>
  190. <artifactId>hadoop-yarn-server-common</artifactId>
  191. <type>test-jar</type>
  192. <scope>test</scope>
  193. </dependency>
  194. <dependency>
  195. <groupId>org.apache.hadoop</groupId>
  196. <artifactId>hadoop-minikdc</artifactId>
  197. <scope>test</scope>
  198. </dependency>
  199. </dependencies>
  200. <profiles>
  201. <profile>
  202. <id>native</id>
  203. <build>
  204. <plugins>
  205. <plugin>
  206. <groupId>org.apache.hadoop</groupId>
  207. <artifactId>hadoop-maven-plugins</artifactId>
  208. <executions>
  209. <execution>
  210. <id>cmake-compile</id>
  211. <phase>compile</phase>
  212. <goals><goal>cmake-compile</goal></goals>
  213. <configuration>
  214. <source>${basedir}/src</source>
  215. <vars>
  216. <HADOOP_CONF_DIR>${container-executor.conf.dir}</HADOOP_CONF_DIR>
  217. <JVM_ARCH_DATA_MODEL>${sun.arch.data.model}</JVM_ARCH_DATA_MODEL>
  218. </vars>
  219. <env>
  220. <CFLAGS>${container-executor.additional_cflags}</CFLAGS>
  221. </env>
  222. </configuration>
  223. </execution>
  224. <execution>
  225. <id>test-container-executor</id>
  226. <goals><goal>cmake-test</goal></goals>
  227. <phase>test</phase>
  228. <configuration>
  229. <binary>${project.build.directory}/native/target/usr/local/bin/test-container-executor</binary>
  230. <timeout>300</timeout>
  231. <results>${project.build.directory}/native-results</results>
  232. </configuration>
  233. </execution>
  234. <execution>
  235. <id>cetest</id>
  236. <goals><goal>cmake-test</goal></goals>
  237. <phase>test</phase>
  238. <configuration>
  239. <!-- this should match the xml name without the TEST-part down below -->
  240. <testName>cetest</testName>
  241. <workingDirectory>${project.build.directory}/native/test</workingDirectory>
  242. <source>${basedir}/src</source>
  243. <binary>${project.build.directory}/native/test/cetest</binary>
  244. <args>
  245. <arg>--gtest_filter=-Perf.</arg>
  246. <arg>--gtest_output=xml:${project.build.directory}/surefire-reports/TEST-cetest.xml</arg>
  247. </args>
  248. <results>${project.build.directory}/surefire-reports</results>
  249. </configuration>
  250. </execution>
  251. </executions>
  252. </plugin>
  253. <plugin>
  254. <groupId>org.apache.maven.plugins</groupId>
  255. <artifactId>maven-antrun-plugin</artifactId>
  256. <executions>
  257. <execution>
  258. <id>make</id>
  259. <phase>compile</phase>
  260. <goals>
  261. <goal>run</goal>
  262. </goals>
  263. <configuration>
  264. <target>
  265. <copy todir="${project.build.directory}/native/test/"
  266. overwrite="true">
  267. <fileset dir="${basedir}/src/main/native/container-executor/resources/test" />
  268. </copy>
  269. </target>
  270. </configuration>
  271. </execution>
  272. </executions>
  273. </plugin>
  274. </plugins>
  275. </build>
  276. <activation>
  277. <activeByDefault>false</activeByDefault>
  278. </activation>
  279. </profile>
  280. <profile>
  281. <id>visualize</id>
  282. <activation>
  283. <activeByDefault>false</activeByDefault>
  284. </activation>
  285. <build>
  286. <plugins>
  287. <plugin>
  288. <groupId>org.codehaus.mojo</groupId>
  289. <artifactId>exec-maven-plugin</artifactId>
  290. <executions>
  291. <execution>
  292. <phase>compile</phase>
  293. <goals>
  294. <goal>java</goal>
  295. </goals>
  296. <configuration>
  297. <mainClass>org.apache.hadoop.yarn.state.VisualizeStateMachine</mainClass>
  298. <classpathScope>compile</classpathScope>
  299. <arguments>
  300. <argument>NodeManager</argument>
  301. <argument>org.apache.hadoop.yarn.server.nodemanager.containermanager.application.ApplicationImpl,
  302. org.apache.hadoop.yarn.server.nodemanager.containermanager.container.ContainerImpl,
  303. org.apache.hadoop.yarn.server.nodemanager.containermanager.localizer.LocalizedResource</argument>
  304. <argument>NodeManager.gv</argument>
  305. </arguments>
  306. </configuration>
  307. </execution>
  308. </executions>
  309. </plugin>
  310. </plugins>
  311. </build>
  312. </profile>
  313. <profile>
  314. <id>native-win</id>
  315. <activation>
  316. <os>
  317. <family>Windows</family>
  318. </os>
  319. </activation>
  320. <build>
  321. <plugins>
  322. <plugin>
  323. <groupId>org.apache.maven.plugins</groupId>
  324. <artifactId>maven-surefire-plugin</artifactId>
  325. <configuration>
  326. <excludes>
  327. <exclude>org.apache.hadoop.yarn.server.nodemanager.containermanager.linux.**</exclude>
  328. </excludes>
  329. </configuration>
  330. </plugin>
  331. </plugins>
  332. </build>
  333. </profile>
  334. </profiles>
  335. <build>
  336. <plugins>
  337. <plugin>
  338. <artifactId>maven-surefire-plugin</artifactId>
  339. <configuration>
  340. <systemPropertyVariables>
  341. <property>
  342. <name>container-executor.path</name>
  343. <value>${container-executor.path}</value>
  344. </property>
  345. <property>
  346. <name>application.submitter</name>
  347. <value>${application.submitter}</value>
  348. </property>
  349. <property>
  350. <name>yarn.log.dir</name>
  351. <value>${maven.project.build.directory}/logs</value>
  352. </property>
  353. </systemPropertyVariables>
  354. <excludes>
  355. <exclude>**/TestFSDownload.java</exclude>
  356. </excludes>
  357. </configuration>
  358. </plugin>
  359. <plugin>
  360. <groupId>org.apache.rat</groupId>
  361. <artifactId>apache-rat-plugin</artifactId>
  362. <configuration>
  363. <excludes>
  364. <exclude>src/main/native/container-executor/impl/compat/fstatat.h</exclude>
  365. <exclude>src/main/native/container-executor/impl/compat/openat.h</exclude>
  366. <exclude>src/main/native/container-executor/impl/compat/unlinkat.h</exclude>
  367. <exclude>src/main/resources/TERMINAL/xterm/**/*</exclude>
  368. </excludes>
  369. </configuration>
  370. </plugin>
  371. <plugin>
  372. <groupId>org.xolstice.maven.plugins</groupId>
  373. <artifactId>protobuf-maven-plugin</artifactId>
  374. <executions>
  375. <execution>
  376. <id>src-compile-protoc</id>
  377. <configuration>
  378. <skip>false</skip>
  379. <additionalProtoPathElements>
  380. <additionalProtoPathElement>
  381. ${basedir}/../../../../hadoop-common-project/hadoop-common/src/main/proto
  382. </additionalProtoPathElement>
  383. <additionalProtoPathElement>
  384. ${basedir}/../../hadoop-yarn-api/src/main/proto
  385. </additionalProtoPathElement>
  386. </additionalProtoPathElements>
  387. </configuration>
  388. </execution>
  389. </executions>
  390. </plugin>
  391. <plugin>
  392. <groupId>com.google.code.maven-replacer-plugin</groupId>
  393. <artifactId>replacer</artifactId>
  394. <executions>
  395. <execution>
  396. <id>replace-generated-sources</id>
  397. <configuration>
  398. <skip>false</skip>
  399. </configuration>
  400. </execution>
  401. <execution>
  402. <id>replace-sources</id>
  403. <configuration>
  404. <skip>false</skip>
  405. </configuration>
  406. </execution>
  407. <execution>
  408. <id>replace-test-sources</id>
  409. <configuration>
  410. <skip>false</skip>
  411. </configuration>
  412. </execution>
  413. </executions>
  414. </plugin>
  415. </plugins>
  416. </build>
  417. </project>