-
-
Save kadel/4067186 to your computer and use it in GitHub Desktop.
A sample POM for setting up a basic Maven project for CDH application development
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<!-- Replace the group ID with your group ID --> | |
<groupId>com.mycompany.hadoopproject</groupId> | |
<!-- Replace the artifact ID with the name of your project --> | |
<artifactId>my-hadoop-project</artifactId> | |
<version>1.0-SNAPSHOT</version> | |
<packaging>jar</packaging> | |
<!-- The name should likely match the artifact ID --> | |
<name>my-hadoop-project</name> | |
<url>http://maven.apache.org</url> | |
<properties> | |
<hadoop.version>2.0.0-mr1-cdh4.1.2</hadoop.version> | |
</properties> | |
<build> | |
<pluginManagement> | |
<plugins> | |
<plugin> | |
<groupId>org.apache.maven.plugins</groupId> | |
<artifactId>maven-compiler-plugin</artifactId> | |
<version>2.3.2</version> | |
<configuration> | |
<source>1.6</source> | |
<target>1.6</target> | |
</configuration> | |
</plugin> | |
</plugins> | |
</pluginManagement> | |
<plugins> | |
<plugin> | |
<groupId>org.apache.maven.plugins</groupId> | |
<artifactId>maven-shade-plugin</artifactId> | |
<version>1.7.1</version> | |
<executions> | |
<execution> | |
<phase>package</phase> | |
<goals> | |
<goal>shade</goal> | |
</goals> | |
</execution> | |
</executions> | |
</plugin> | |
<plugin> | |
<groupId>org.apache.maven.plugins</groupId> | |
<artifactId>maven-eclipse-plugin</artifactId> | |
<version>2.9</version> | |
<configuration> | |
<buildOutputDirectory>eclipse-classes</buildOutputDirectory> | |
<downloadSources>true</downloadSources> | |
<downloadJavadocs>false</downloadJavadocs> | |
</configuration> | |
</plugin> | |
</plugins> | |
</build> | |
<dependencies> | |
<dependency> | |
<groupId>junit</groupId> | |
<artifactId>junit</artifactId> | |
<version>4.8.2</version> | |
<scope>test</scope> | |
</dependency> | |
<dependency> | |
<groupId>org.apache.hadoop</groupId> | |
<artifactId>hadoop-client</artifactId> | |
<version>${hadoop.version}</version> | |
<scope>provided</scope> | |
</dependency> | |
</dependencies> | |
<repositories> | |
<repository> | |
<id>cloudera</id> | |
<url>https://repository.cloudera.com/artifactory/cloudera-repos</url> | |
<releases> | |
<enabled>true</enabled> | |
</releases> | |
<snapshots> | |
<enabled>false</enabled> | |
</snapshots> | |
</repository> | |
</repositories> | |
</project> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment