hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alejandro Abdelnur (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HADOOP-7506) hadoopcommon build version cant be set from the maven commandline
Date Wed, 03 Aug 2011 16:55:27 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-7506?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13078839#comment-13078839

Alejandro Abdelnur commented on HADOOP-7506:

Note Maven warning on this:

[WARNING] Some problems were encountered while building the effective model for org.apache.hadoop:hadoop-project:pom:0.23.0-SNAPSHOST
[WARNING] 'version' contains an expression but should be a constant. @ org.apache.hadoop:hadoop-project:${hadoop.version},
/Users/tucu/src/apache/hadoop/utrunk/hadoop-project/pom.xml, line 19, column 12

In addition, this won't work (I've tried this approach a couple of years ago when starting
with Oozie) for the following reason:

The installed/deployed POMs will have a variable as the version and Maven dependency resolution
won't be able to resolve that variable to a concrete value. Following there is a minimal POM
that fails after doing a 'mvn install' with the HADOOP-7506 patch. (Make sure you trash other
snapshots of hadoop-* and you are using -offline, to force the use of the just installed artifacts).

<?xml version="1.0" encoding="UTF-8"?>



One of the reasons for the failure is that the version is defined in hadoop-common's parent
POM (hadoop-project) and then Maven cannot determine the version of hadoop-project to use
because (chicken & egg problem).

The Maven way to take care of version upgrades through out the POMs is using the maven-release-plugin
(I've used it in the past and it works quite well in multi-module projects)

> hadoopcommon build version cant be set from the maven commandline
> -----------------------------------------------------------------
>                 Key: HADOOP-7506
>                 URL: https://issues.apache.org/jira/browse/HADOOP-7506
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: build
>    Affects Versions: 0.23.0
>            Reporter: Giridharan Kesavan
>            Assignee: Giridharan Kesavan
>         Attachments: HADOOP-7506.PATCH
> pom.xml had to introduce hadoop.version property with the default value set to the snapshot
version. If someone during build time want to override the version from maven command line
they can do so by passing -Dhadoop.version="". For ppl who doesnt want to change the default
version can continue building. 

This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message