HBASE-23861. Reconcile Hadoop version. (#1179)
[hbase.git] / hbase-examples / pom.xml
blobb73146b1a7b5df336699e407d85dbbc4b40a67bd
1 <?xml version="1.0"?>
2 <project xmlns="https://maven.apache.org/POM/4.0.0" xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="https://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
3   <!--
4 /**
5  * Licensed to the Apache Software Foundation (ASF) under one
6  * or more contributor license agreements.  See the NOTICE file
7  * distributed with this work for additional information
8  * regarding copyright ownership.  The ASF licenses this file
9  * to you under the Apache License, Version 2.0 (the
10  * "License"); you may not use this file except in compliance
11  * with the License.  You may obtain a copy of the License at
12  *
13  *     http://www.apache.org/licenses/LICENSE-2.0
14  *
15  * Unless required by applicable law or agreed to in writing, software
16  * distributed under the License is distributed on an "AS IS" BASIS,
17  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18  * See the License for the specific language governing permissions and
19  * limitations under the License.
20  */
21 -->
22   <modelVersion>4.0.0</modelVersion>
23   <parent>
24     <artifactId>hbase-build-configuration</artifactId>
25     <groupId>org.apache.hbase</groupId>
26     <version>3.0.0-SNAPSHOT</version>
27     <relativePath>../hbase-build-configuration</relativePath>
28   </parent>
29   <artifactId>hbase-examples</artifactId>
30   <name>Apache HBase - Examples</name>
31   <description>Examples of HBase usage</description>
32   <!--REMOVE-->
33   <build>
34     <plugins>
35       <plugin>
36         <!--Make it so assembly:single does nothing in here-->
37         <artifactId>maven-assembly-plugin</artifactId>
38         <configuration>
39           <skipAssembly>true</skipAssembly>
40         </configuration>
41       </plugin>
42       <plugin>
43         <artifactId>maven-surefire-plugin</artifactId>
44         <configuration>
45           <!-- Have to set the groups here because we only do
46                     split tests in this package, so groups on live in this module -->
47           <groups>${surefire.firstPartGroups}</groups>
48         </configuration>
49       </plugin>
50       <!-- Make a jar and put the sources in the jar -->
51       <plugin>
52         <groupId>org.apache.maven.plugins</groupId>
53         <artifactId>maven-source-plugin</artifactId>
54       </plugin>
55       <plugin>
56         <groupId>org.xolstice.maven.plugins</groupId>
57         <artifactId>protobuf-maven-plugin</artifactId>
58         <executions>
59           <execution>
60             <id>compile-protoc</id>
61             <phase>generate-sources</phase>
62             <goals>
63               <goal>compile</goal>
64             </goals>
65           </execution>
66         </executions>
67       </plugin>
68       <plugin>
69         <groupId>net.revelc.code</groupId>
70         <artifactId>warbucks-maven-plugin</artifactId>
71       </plugin>
72       <plugin>
73         <groupId>org.apache.maven.plugins</groupId>
74         <artifactId>maven-checkstyle-plugin</artifactId>
75         <configuration>
76           <failOnViolation>true</failOnViolation>
77         </configuration>
78       </plugin>
79     </plugins>
80   </build>
81   <dependencies>
82     <dependency>
83       <groupId>org.apache.hbase.thirdparty</groupId>
84       <artifactId>hbase-shaded-miscellaneous</artifactId>
85     </dependency>
86     <dependency>
87       <groupId>org.apache.hbase.thirdparty</groupId>
88       <artifactId>hbase-shaded-netty</artifactId>
89     </dependency>
90     <dependency>
91       <groupId>org.apache.hbase</groupId>
92       <artifactId>hbase-common</artifactId>
93     </dependency>
94     <dependency>
95       <groupId>org.apache.hbase</groupId>
96       <artifactId>hbase-protocol</artifactId>
97     </dependency>
98     <dependency>
99       <groupId>org.apache.hbase</groupId>
100       <artifactId>hbase-client</artifactId>
101     </dependency>
102     <dependency>
103       <groupId>org.apache.hbase</groupId>
104       <artifactId>hbase-server</artifactId>
105     </dependency>
106     <dependency>
107       <groupId>org.apache.hbase</groupId>
108       <artifactId>hbase-mapreduce</artifactId>
109     </dependency>
110     <dependency>
111       <groupId>org.apache.hbase</groupId>
112       <artifactId>hbase-endpoint</artifactId>
113     </dependency>
114     <dependency>
115       <groupId>org.apache.hbase</groupId>
116       <artifactId>hbase-thrift</artifactId>
117     </dependency>
118     <dependency>
119       <groupId>org.apache.hbase</groupId>
120       <artifactId>hbase-metrics-api</artifactId>
121     </dependency>
122     <dependency>
123       <groupId>org.apache.hbase</groupId>
124       <artifactId>hbase-testing-util</artifactId>
125       <scope>test</scope>
126     </dependency>
127     <dependency>
128       <groupId>org.apache.thrift</groupId>
129       <artifactId>libthrift</artifactId>
130     </dependency>
131     <dependency>
132       <groupId>commons-io</groupId>
133       <artifactId>commons-io</artifactId>
134     </dependency>
135     <dependency>
136       <groupId>org.slf4j</groupId>
137       <artifactId>slf4j-api</artifactId>
138     </dependency>
139     <dependency>
140       <groupId>org.apache.zookeeper</groupId>
141       <artifactId>zookeeper</artifactId>
142     </dependency>
143     <dependency>
144       <groupId>com.google.protobuf</groupId>
145       <artifactId>protobuf-java</artifactId>
146     </dependency>
147     <dependency>
148       <groupId>org.apache.curator</groupId>
149       <artifactId>curator-framework</artifactId>
150     </dependency>
151     <dependency>
152       <groupId>org.apache.curator</groupId>
153       <artifactId>curator-client</artifactId>
154     </dependency>
155     <dependency>
156       <groupId>org.apache.curator</groupId>
157       <artifactId>curator-recipes</artifactId>
158     </dependency>
159     <dependency>
160       <groupId>com.github.stephenc.findbugs</groupId>
161       <artifactId>findbugs-annotations</artifactId>
162     </dependency>
163     <dependency>
164       <groupId>org.apache.hbase</groupId>
165       <artifactId>hbase-rest</artifactId>
166     </dependency>
167     <dependency>
168       <groupId>junit</groupId>
169       <artifactId>junit</artifactId>
170       <scope>test</scope>
171     </dependency>
172     <dependency>
173       <groupId>org.mockito</groupId>
174       <artifactId>mockito-core</artifactId>
175       <scope>test</scope>
176     </dependency>
177     <dependency>
178       <groupId>org.apache.hadoop</groupId>
179       <artifactId>hadoop-minikdc</artifactId>
180       <scope>test</scope>
181       <exclusions>
182         <exclusion>
183           <groupId>bouncycastle</groupId>
184           <artifactId>bcprov-jdk15</artifactId>
185         </exclusion>
186       </exclusions>
187     </dependency>
188     <dependency>
189       <groupId>org.bouncycastle</groupId>
190       <artifactId>bcprov-jdk15on</artifactId>
191       <scope>test</scope>
192     </dependency>
193     <dependency>
194       <groupId>org.apache.hbase</groupId>
195       <artifactId>hbase-http</artifactId>
196       <scope>test</scope>
197       <type>test-jar</type>
198     </dependency>
199   </dependencies>
200   <profiles>
201     <!-- Skip the tests in this module -->
202     <profile>
203       <id>skipExamplesTests</id>
204       <activation>
205         <property>
206           <name>skipExamplesTests</name>
207         </property>
208       </activation>
209       <properties>
210         <surefire.skipFirstPart>true</surefire.skipFirstPart>
211         <surefire.skipSecondPart>true</surefire.skipSecondPart>
212       </properties>
213     </profile>
214     <!-- Profiles for building against different hadoop versions -->
215     <!-- There are a lot of common dependencies used here, should investigate
216          if we can combine these profiles somehow -->
217     <!-- profile for building against Hadoop 2.x.  This is the default -->
218     <profile>
219       <id>hadoop-2.0</id>
220       <activation>
221         <property>
222           <!--Below formatting for dev-support/generate-hadoopX-poms.sh-->
223           <!--h2-->
224           <name>!hadoop.profile</name>
225         </property>
226       </activation>
227       <dependencies>
228         <dependency>
229           <groupId>org.apache.hadoop</groupId>
230           <artifactId>hadoop-mapreduce-client-core</artifactId>
231         </dependency>
232         <dependency>
233           <groupId>org.apache.hadoop</groupId>
234           <artifactId>hadoop-common</artifactId>
235         </dependency>
236       </dependencies>
237       <build>
238         <plugins>
239           <plugin>
240             <artifactId>maven-dependency-plugin</artifactId>
241             <executions>
242               <execution>
243                 <id>create-mrapp-generated-classpath</id>
244                 <phase>generate-test-resources</phase>
245                 <goals>
246                   <goal>build-classpath</goal>
247                 </goals>
248                 <configuration>
249                   <!-- needed to run the unit test for DS to generate
250                                  the required classpath that is required in the env
251                                  of the launch container in the mini mr/yarn cluster
252                                  -->
253                   <outputFile>${project.build.directory}/test-classes/mrapp-generated-classpath</outputFile>
254                 </configuration>
255               </execution>
256             </executions>
257           </plugin>
258         </plugins>
259       </build>
260     </profile>
261     <!--
262        profile for building against Hadoop 3.0.x. Activate using:
263         mvn -Dhadoop.profile=3.0
264      -->
265     <profile>
266       <id>hadoop-3.0</id>
267       <activation>
268         <property>
269           <name>hadoop.profile</name>
270           <value>3.0</value>
271         </property>
272       </activation>
273       <properties>
274         <hadoop.version>3.0-SNAPSHOT</hadoop.version>
275       </properties>
276       <dependencies>
277         <dependency>
278           <groupId>org.apache.hadoop</groupId>
279           <artifactId>hadoop-common</artifactId>
280         </dependency>
281         <dependency>
282           <groupId>org.apache.hadoop</groupId>
283           <artifactId>hadoop-minicluster</artifactId>
284         </dependency>
285       </dependencies>
286       <build>
287         <plugins>
288           <plugin>
289             <artifactId>maven-dependency-plugin</artifactId>
290             <executions>
291               <execution>
292                 <id>create-mrapp-generated-classpath</id>
293                 <phase>generate-test-resources</phase>
294                 <goals>
295                   <goal>build-classpath</goal>
296                 </goals>
297                 <configuration>
298                   <!-- needed to run the unit test for DS to generate
299                                  the required classpath that is required in the env
300                                  of the launch container in the mini mr/yarn cluster
301                                  -->
302                   <outputFile>${project.build.directory}/test-classes/mrapp-generated-classpath</outputFile>
303                 </configuration>
304               </execution>
305             </executions>
306           </plugin>
307         </plugins>
308       </build>
309     </profile>
310     <profile>
311       <id>eclipse-specific</id>
312       <activation>
313         <property>
314           <name>m2e.version</name>
315         </property>
316       </activation>
317       <build>
318         <pluginManagement>
319           <plugins>
320             <!--This plugin's configuration is used to store Eclipse m2e settings
321                  only. It has no influence on the Maven build itself.-->
322             <plugin>
323               <groupId>org.eclipse.m2e</groupId>
324               <artifactId>lifecycle-mapping</artifactId>
325               <configuration>
326                 <lifecycleMappingMetadata>
327                   <pluginExecutions>
328                     <pluginExecution>
329                       <pluginExecutionFilter>
330                         <groupId>org.apache.maven.plugins</groupId>
331                         <artifactId>maven-dependency-plugin</artifactId>
332                         <versionRange>[2.8,)</versionRange>
333                         <goals>
334                           <goal>build-classpath</goal>
335                         </goals>
336                       </pluginExecutionFilter>
337                       <action>
338                         <ignore/>
339                       </action>
340                     </pluginExecution>
341                   </pluginExecutions>
342                 </lifecycleMappingMetadata>
343               </configuration>
344             </plugin>
345           </plugins>
346         </pluginManagement>
347       </build>
348     </profile>
349   </profiles>
350 </project>