Hello Simon,

I think a multi module project should define the common configuration of
plugins and dependencies in the management section.

For example: If you define different versions of the commons-logging
api. The dependency mechanism is not using the most recent version of
commons-logging, maven resolves to the version of the dependency from
the nearest pom. (


Simon Kitching schrieb:
> ---- Bernd Bohmann <[EMAIL PROTECTED]> schrieb:
>>
>> Simon Kitching schrieb:
>>
>>> Yes, the above approach will work. But it is worrying to look at a pom and 
>>> see something without a version attached. It requires work to confirm that 
>>> this is valid (ie that a parent does define a version). And it sets a bad 
>>> example for other people; I have just been through all the poms and cleaned 
>>> up *many* cases where plugins and dependencies were being used without any 
>>> version being declared anywhere.
>>>
>>> The supposed advantage of declaring the version in a parent pom is that all 
>>> the children can be "pushed" to a new version at once. But in fact that is 
>>> not true, because this requires (a) a new version of the parent to be 
>>> released, then (b) every child be updated to use the new parent. Ok, it 
>>> does work a little better during SNAPSHOT cycles, where a modified parent 
>>> gets picked up automatically.
>>>
>>> But there is no great advantage in having all child modules using the same 
>>> plugin version anyway. If a module works with version X of a plugin, then 
>>> why move to a different one? That just risks breakage of that module for no 
>>> gain, as it worked fine before with the old one.
>>>
>> I think everybody should use pluginManagement and dependencyManagement
>> in a multi module maven project.
> 
> A few reasons would be helpful Bernd :-)
> 
> Why do you think pluginManagement/dependencyManagement is better? What are 
> the errors in my statements above?
> 
> Regards,
> Simon
> 

Reply via email to