Maven 1

maven seems not to evaluate .properties of parent pom

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 1.0.1
  • Fix Version/s: 1.0.2
  • Component/s: core
  • Labels:
    None
  • Environment:
  • Number of attachments :
    0

Description

My pop extends an other pom.
<extend>../../project-defaults.xml</extend>
In that directory, there exists a project.properties.

This property file defines a company local, remote repository.

maven.repo.remote= http://maven.<company-domain>/repo

Using maven 1.0, this repository is used.
When using 1.0.1, it is not used.

Issue Links

Activity

Hide
Brett Porter added a comment -

this is a regression resulting from fixing >1 level of inheritence. It only fails for build in properties (most importantly, maven.repo.remote).

Show
Brett Porter added a comment - this is a regression resulting from fixing >1 level of inheritence. It only fails for build in properties (most importantly, maven.repo.remote).
Hide
Boris Boehlen added a comment -

My project layout is as follows:

common-build
project.properties
project.xml
kernel-module
project.xml
extension-1
project.xml
extension-2
project.xml

The extensions of the kernel are developed independently and can thus not be stored under kernel-module. Each module has a project.xml which says:
<extend>${basedir}/../common-build/project.xml</extend>
The output of "maven -X" tells me that the project.properties are read but the values (like maven.username and maven.repo.remote) are not set.

For me this is not a minor bug, but a show stopper.

Show
Boris Boehlen added a comment - My project layout is as follows: common-build project.properties project.xml kernel-module project.xml extension-1 project.xml extension-2 project.xml The extensions of the kernel are developed independently and can thus not be stored under kernel-module. Each module has a project.xml which says: <extend>${basedir}/../common-build/project.xml</extend> The output of "maven -X" tells me that the project.properties are read but the values (like maven.username and maven.repo.remote) are not set. For me this is not a minor bug, but a show stopper.
Hide
Boris Boehlen added a comment -

Bug's priority should be set to critical as it is in the duplicated bug #1513.

Show
Boris Boehlen added a comment - Bug's priority should be set to critical as it is in the duplicated bug #1513.
Hide
Brett Porter added a comment -

major is fairer.

We tend to drive priority by "fix for" version.

Show
Brett Porter added a comment - major is fairer. We tend to drive priority by "fix for" version.
Hide
Carlos Sanchez added a comment -

A workaround is passing the property in the command line, e.g.
maven -Dmaven.repo.remote=http://www.ibiblio.org/maven/,http://dist.codehaus.org/

This way it's available to subprojects

Show
Carlos Sanchez added a comment - A workaround is passing the property in the command line, e.g. maven -Dmaven.repo.remote=http://www.ibiblio.org/maven/,http://dist.codehaus.org/ This way it's available to subprojects
Hide
Brett Porter added a comment -

From Dr Wes Munsil:
For me, adding this to my top-level project.properties file seemed to make everything happy again:

maven.property.inheritance=true

Show
Brett Porter added a comment - From Dr Wes Munsil: For me, adding this to my top-level project.properties file seemed to make everything happy again: maven.property.inheritance=true
Hide
Boris Boehlen added a comment -

The workaround suggested by Wes Munsil does not work for me. I tried to set "maven.property.inheritance=true" at the following places

  • Inherited "project.properties"
  • Project specific "project.properties"
  • Command line
    None of them solved the issue.
Show
Boris Boehlen added a comment - The workaround suggested by Wes Munsil does not work for me. I tried to set "maven.property.inheritance=true" at the following places
  • Inherited "project.properties"
  • Project specific "project.properties"
  • Command line None of them solved the issue.
Hide
Brett Porter added a comment -

looking at the code made this fairly obvious what was going wrong. I have it fixed, and will commit this evening.

Show
Brett Porter added a comment - looking at the code made this fairly obvious what was going wrong. I have it fixed, and will commit this evening.

People

Vote (2)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: