maven-m2-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Casey <>
Subject Re: the use of a file for maven.repo.local
Date Thu, 30 Sep 2004 21:42:01 GMT
The problem that I see with the current setup is that overrides.xml is a 
POM...or at least, it's read using the model reader. This means that 
anything we specify in overrides.xml can reasonably be expected to be 
legal in any old project POM. If you specify an environment-specific 
setting like maven.repo.local or java.home, your POM is non-portable; 
it's that simple.

But there are deeper problems than this. Say I specify the local repo in 
my project POM, and the inheritance actually leads to maven using this 
locally-overridden value. Now, the local repo was used to resolve all of 
my parent POMs, and then the local repo was switched. Anything I 
resolved/downloaded during that process (POMs, artifacts of any kind) 
must now be re-downloaded to the NEW local repo. I would argue the same 
problem with the remote repo, but I think the reasons for allowing 
project-override of the default remote repos list is too compelling to 

Why do we need to place local-environment settings in the POM, when 
specification of these settings (a) is not essential for proper maven 
functioning (local properties file is a good alternative), and (b) will 
virtually guarantee non-portability.

My java.home is: /usr/java/jdk/current

What is yours? If you're using windows, our shared POM is broken.


Brett Porter wrote:
> -0
> What is the reason not to have it in there? It's good to have just one 
> configuration file for the site defaults and user overrides (and these 
> must be a model so you can specify remote repositories, etc), and I'm 
> sure there are other local settings that we might add later (javaHome?).
> Unless its causing issues, I think there are probably bigger concerns at 
> the moment.
> Cheers,
> Brett
> Emmanuel Venisse wrote:
>>> Hi,
>>> John and I were chatting about how the local repository is specified and
>>> we were wondering if that might be one property that should be defined
>>> outside of the POM as it is not really related to the POM. I can't think
>>> of any other properties that might fall into this category but I thought
>>> I would bring it up.
>> +1
>> Emmanuel

View raw message