pom.xml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!--
  3. ~ Licensed to the Apache Software Foundation (ASF) under one or more
  4. ~ contributor license agreements. See the NOTICE file distributed with
  5. ~ this work for additional information regarding copyright ownership.
  6. ~ The ASF licenses this file to You under the Apache License, Version 2.0
  7. ~ (the "License"); you may not use this file except in compliance with
  8. ~ the License. You may obtain a copy of the License at
  9. ~
  10. ~ http://www.apache.org/licenses/LICENSE-2.0
  11. ~
  12. ~ Unless required by applicable law or agreed to in writing, software
  13. ~ distributed under the License is distributed on an "AS IS" BASIS,
  14. ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. ~ See the License for the specific language governing permissions and
  16. ~ limitations under the License.
  17. -->
  18. <project xmlns="http://maven.apache.org/POM/4.0.0"
  19. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  20. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  21. <modelVersion>4.0.0</modelVersion>
  22. <parent>
  23. <groupId>org.apache.livy</groupId>
  24. <artifactId>livy-main</artifactId>
  25. <relativePath>../pom.xml</relativePath>
  26. <version>0.7.0-incubating-SNAPSHOT</version>
  27. </parent>
  28. <artifactId>livy-integration-test</artifactId>
  29. <version>0.7.0-incubating-SNAPSHOT</version>
  30. <packaging>jar</packaging>
  31. <properties>
  32. <!--
  33. Set this to the file containing the cluster description to use. By default a mini cluster
  34. with 1 DN and 1 NM will be run. Location is tried first in the classpath, then the file
  35. system.
  36. -->
  37. <cluster.spec>default</cluster.spec>
  38. <skipDeploy>true</skipDeploy>
  39. <livy.test.thrift.enabled>false</livy.test.thrift.enabled>
  40. </properties>
  41. <dependencies>
  42. <dependency>
  43. <groupId>${project.groupId}</groupId>
  44. <artifactId>livy-core_${scala.binary.version}</artifactId>
  45. <version>${project.version}</version>
  46. </dependency>
  47. <dependency>
  48. <groupId>${project.groupId}</groupId>
  49. <artifactId>livy-server</artifactId>
  50. <version>${project.version}</version>
  51. </dependency>
  52. <dependency>
  53. <groupId>${project.groupId}</groupId>
  54. <artifactId>livy-client-http</artifactId>
  55. <version>${project.version}</version>
  56. <scope>test</scope>
  57. </dependency>
  58. <dependency>
  59. <groupId>${project.groupId}</groupId>
  60. <artifactId>livy-test-lib</artifactId>
  61. <version>${project.version}</version>
  62. <scope>test</scope>
  63. </dependency>
  64. <dependency>
  65. <groupId>com.fasterxml.jackson.core</groupId>
  66. <artifactId>jackson-core</artifactId>
  67. </dependency>
  68. <dependency>
  69. <groupId>com.fasterxml.jackson.core</groupId>
  70. <artifactId>jackson-databind</artifactId>
  71. </dependency>
  72. <dependency>
  73. <groupId>com.fasterxml.jackson.module</groupId>
  74. <artifactId>jackson-module-scala_${scala.binary.version}</artifactId>
  75. </dependency>
  76. <dependency>
  77. <groupId>com.ning</groupId>
  78. <artifactId>async-http-client</artifactId>
  79. <version>1.9.38</version>
  80. </dependency>
  81. <dependency>
  82. <groupId>commons-io</groupId>
  83. <artifactId>commons-io</artifactId>
  84. <version>2.5</version>
  85. </dependency>
  86. <dependency>
  87. <groupId>org.apache.hadoop</groupId>
  88. <artifactId>hadoop-common</artifactId>
  89. <classifier>tests</classifier>
  90. </dependency>
  91. <dependency>
  92. <groupId>org.apache.hadoop</groupId>
  93. <artifactId>hadoop-hdfs</artifactId>
  94. <classifier>tests</classifier>
  95. </dependency>
  96. <dependency>
  97. <groupId>org.apache.hadoop</groupId>
  98. <artifactId>hadoop-yarn-client</artifactId>
  99. </dependency>
  100. <dependency>
  101. <groupId>org.apache.hadoop</groupId>
  102. <artifactId>hadoop-client</artifactId>
  103. <exclusions>
  104. <exclusion>
  105. <groupId>javax.servlet</groupId>
  106. <artifactId>servlet-api</artifactId>
  107. </exclusion>
  108. </exclusions>
  109. </dependency>
  110. <dependency>
  111. <groupId>org.apache.hadoop</groupId>
  112. <artifactId>hadoop-yarn-server-tests</artifactId>
  113. <classifier>tests</classifier>
  114. </dependency>
  115. <dependency>
  116. <groupId>org.apache.spark</groupId>
  117. <artifactId>spark-core_${scala.binary.version}</artifactId>
  118. <scope>test</scope>
  119. </dependency>
  120. <dependency>
  121. <groupId>org.apache.spark</groupId>
  122. <artifactId>spark-sql_${scala.binary.version}</artifactId>
  123. <scope>test</scope>
  124. </dependency>
  125. <dependency>
  126. <groupId>org.apache.spark</groupId>
  127. <artifactId>spark-streaming_${scala.binary.version}</artifactId>
  128. <scope>test</scope>
  129. </dependency>
  130. <dependency>
  131. <groupId>org.apache.spark</groupId>
  132. <artifactId>spark-hive_${scala.binary.version}</artifactId>
  133. <scope>test</scope>
  134. </dependency>
  135. <dependency>
  136. <groupId>org.scala-lang</groupId>
  137. <artifactId>scala-library</artifactId>
  138. </dependency>
  139. <dependency>
  140. <groupId>org.scalatest</groupId>
  141. <artifactId>scalatest_${scala.binary.version}</artifactId>
  142. <version>${scalatest.version}</version>
  143. <scope>compile</scope>
  144. </dependency>
  145. <dependency>
  146. <groupId>org.scalatra</groupId>
  147. <artifactId>scalatra-test_${scala.binary.version}</artifactId>
  148. </dependency>
  149. </dependencies>
  150. <build>
  151. <plugins>
  152. <plugin>
  153. <groupId>com.googlecode.maven-download-plugin</groupId>
  154. <artifactId>download-maven-plugin</artifactId>
  155. <executions>
  156. <execution>
  157. <id>download-spark-files</id>
  158. <goals>
  159. <goal>wget</goal>
  160. </goals>
  161. <configuration>
  162. <readTimeOut>60000</readTimeOut>
  163. <retries>5</retries>
  164. <url>${spark.bin.download.url}</url>
  165. <outputDirectory>${project.build.directory}</outputDirectory>
  166. <unpack>true</unpack>
  167. </configuration>
  168. </execution>
  169. </executions>
  170. </plugin>
  171. <plugin>
  172. <groupId>org.codehaus.mojo</groupId>
  173. <artifactId>build-helper-maven-plugin</artifactId>
  174. <executions>
  175. <execution>
  176. <id>parse-spark-version</id>
  177. <phase>process-test-sources</phase>
  178. <goals>
  179. <goal>parse-version</goal>
  180. </goals>
  181. <configuration>
  182. <propertyPrefix>spark</propertyPrefix>
  183. <versionString>${spark.version}</versionString>
  184. </configuration>
  185. </execution>
  186. <execution>
  187. <id>add-spark-version-specific-test</id>
  188. <phase>process-test-sources</phase>
  189. <goals>
  190. <goal>add-test-source</goal>
  191. </goals>
  192. <configuration>
  193. <sources>
  194. <source>${project.basedir}/src/test/spark${spark.majorVersion}/scala</source>
  195. </sources>
  196. </configuration>
  197. </execution>
  198. </executions>
  199. </plugin>
  200. <plugin>
  201. <groupId>org.apache.maven.plugins</groupId>
  202. <artifactId>maven-surefire-plugin</artifactId>
  203. <executions>
  204. <execution>
  205. <id>default-test</id>
  206. <phase>none</phase>
  207. </execution>
  208. </executions>
  209. </plugin>
  210. <plugin>
  211. <groupId>org.scalatest</groupId>
  212. <artifactId>scalatest-maven-plugin</artifactId>
  213. <executions>
  214. <!-- Unbind integration test from test phase and bind it to integration-test phase -->
  215. <execution>
  216. <id>test</id>
  217. <phase>none</phase>
  218. </execution>
  219. <execution>
  220. <id>integration-test</id>
  221. <phase>integration-test</phase>
  222. <goals>
  223. <goal>test</goal>
  224. </goals>
  225. </execution>
  226. </executions>
  227. <configuration>
  228. <environmentVariables>
  229. <LIVY_HOME>${execution.root}</LIVY_HOME>
  230. <LIVY_TEST>false</LIVY_TEST>
  231. <LIVY_INTEGRATION_TEST>true</LIVY_INTEGRATION_TEST>
  232. <SPARK_HOME>${project.build.directory}/${spark.bin.name}</SPARK_HOME>
  233. <LIVY_TEST_THRIFT_ENABLED>${livy.test.thrift.enabled}</LIVY_TEST_THRIFT_ENABLED>
  234. </environmentVariables>
  235. <systemProperties>
  236. <cluster.spec>${cluster.spec}</cluster.spec>
  237. </systemProperties>
  238. <skipTests>${skipITs}</skipTests>
  239. </configuration>
  240. </plugin>
  241. </plugins>
  242. </build>
  243. <profiles>
  244. <profile>
  245. <id>skip-integration-test</id>
  246. <activation>
  247. <property>
  248. <name>skipITs</name>
  249. <value>true</value>
  250. </property>
  251. </activation>
  252. </profile>
  253. <profile>
  254. <id>thriftserver</id>
  255. <properties>
  256. <livy.test.thrift.enabled>true</livy.test.thrift.enabled>
  257. </properties>
  258. <dependencies>
  259. <dependency>
  260. <groupId>${project.groupId}</groupId>
  261. <artifactId>livy-thriftserver</artifactId>
  262. <version>${project.version}</version>
  263. </dependency>
  264. <!-- needed for testing thriftserver -->
  265. <dependency>
  266. <groupId>org.apache.hive</groupId>
  267. <artifactId>hive-jdbc</artifactId>
  268. <version>${hive.version}</version>
  269. <scope>test</scope>
  270. <exclusions>
  271. <exclusion>
  272. <groupId>org.apache.zookeeper</groupId>
  273. <artifactId>zookeeper</artifactId>
  274. </exclusion>
  275. <exclusion>
  276. <groupId>io.netty</groupId>
  277. <artifactId>netty</artifactId>
  278. </exclusion>
  279. <exclusion>
  280. <groupId>org.apache.logging.log4j</groupId>
  281. <artifactId>log4j-slf4j-impl</artifactId>
  282. </exclusion>
  283. <exclusion>
  284. <groupId>org.slf4j</groupId>
  285. <artifactId>slf4j-log4j12</artifactId>
  286. </exclusion>
  287. </exclusions>
  288. </dependency>
  289. </dependencies>
  290. <build>
  291. <plugins>
  292. <plugin>
  293. <groupId>org.codehaus.mojo</groupId>
  294. <artifactId>build-helper-maven-plugin</artifactId>
  295. <executions>
  296. <execution>
  297. <id>add-scala-sources</id>
  298. <phase>generate-sources</phase>
  299. <goals>
  300. <goal>add-source</goal>
  301. </goals>
  302. <configuration>
  303. <sources>
  304. <source>${project.basedir}/src/thriftserver/main/scala</source>
  305. </sources>
  306. </configuration>
  307. </execution>
  308. <execution>
  309. <id>add-scala-test-sources</id>
  310. <phase>generate-test-sources</phase>
  311. <goals>
  312. <goal>add-test-source</goal>
  313. </goals>
  314. <configuration>
  315. <sources>
  316. <source>${project.basedir}/src/thriftserver/test/scala</source>
  317. </sources>
  318. </configuration>
  319. </execution>
  320. </executions>
  321. </plugin>
  322. </plugins>
  323. </build>
  324. </profile>
  325. </profiles>
  326. </project>