Maven配置cloudera源下载CDH依赖包

由于Cloudera Manager自动安装部署的HadoopHbaseZookeeper等组件与Apache提供的会有差异,所以需要配置为对应CDH版本的依赖包。

添加cloudera仓库

pom.xmlproject标签内开头添加如下仓库:

  <repositories>
    <repository>
      <id>clouderaid>
      <url>https://repository.cloudera.com/artifactory/cloudera-repos/url>
    repository>
  repositories>

添加特定版本的CDH依赖

	<dependency>
      <groupId>org.apache.hbasegroupId>
      <artifactId>hbase-clientartifactId>
      <version>1.1.0-cdh5.8.5version>
    dependency>
    <dependency>
      <groupId>org.apache.hbasegroupId>
      <artifactId>hbase-commonartifactId>
      <version>1.1.0-cdh5.8.5version>
	dependency>
	<dependency>
		<groupId>org.apache.zookeepergroupId>
		<artifactId>zookeeperartifactId>
		<version>3.4.5-cdh5.8.5version>
	dependency>
	<dependency>
        <groupId>org.apache.hadoopgroupId>
        <artifactId>hadoop-commonartifactId>
        <version>2.6.0-cdh5.8.5version>
	dependency>

参考链接

Cloudera Enterprise 5.x Release Notes
Maven Artifacts for CDH 5.8.x Releases

你可能感兴趣的:(Cloudera,cloudera,maven)