You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Ralph Goers <Ra...@dslextreme.com> on 2007/04/09 08:44:53 UTC
building trunk.
I ran a build of trunk and afterward ended up with the following
duplicates in a clean local repository. It seems to me that there
should only be one version of these used in a build.
commons-collections/commons-collections/2.0
commons-collections/commons-collections/3.2
commons-logging/commons-logging/1.0
commons-logging/commons-logging/1.0.4
commons-logging/commons-logging/1.1
javax/servlet/servlet-api/2.3
javax/servlet/servlet-api/2.4
junit/junit/3.8
junit/junit/3.8.1
junit/junit/3.8.2
log4j/log4j/1.2.12
log4j/log4j/1.2.14
org/apache/maven/plugins/maven-plugins/1
org/apache/maven/plugins/maven-plugins/3
org/apache/maven/plugins/maven-plugins/7
org/apache/maven/plugins/maven-plugins/8
org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5
org/apache/maven/wagon/wagon-provider-api/1.0-alpha-6
org/codehaus/plexus/plexus/1.0.4
org/codehaus/plexus/plexus/1.0.5
org/codehaus/plexus/plexus/1.0.8
org/codehaus/plexus/plexus-container-default/1.0-alpha-8
org/codehaus/plexus/plexus-container-default/1.0-alpha-9
org/codehaus/plexus/plexus-utils/1.0.4
org/codehaus/plexus/plexus-utils/1.0.5
org/codehaus/plexus/plexus-utils/1.1
org/codehaus/plexus/plexus-utils/1.2
org/springframework/spring-aop/2.0.2
org/springframework/spring-aop/2.0.3
org/springframework/spring-beans/2.0.2
org/springframework/spring-beans/2.0.3
org/springframework/spring-context/2.0.2
org/springframework/spring-context/2.0.3
org/springframework/spring-core/2.0.2
org/springframework/spring-core/2.0.3
org/springframework/spring-web/2.0.2
org/springframework/spring-web/2.0.3
xalan/xalan/2.7.0
xerces/xerces/2.4.0
xerces/xerces
xerces/xercesImpl/2.4.0
xerces/xercesImpl/2.8.0
xerces/xercesImpl/2.8.1
xml-apis/xml-apis/1.0.b2
xml-apis/xml-apis/1.3.02
xml-apis/xml-apis/2.0.2
xml-resolver/xml-resolver/1.1
xml-resolver/xml-resolver/1.2
Re: building trunk.
Posted by Jorg Heymans <jh...@apache.org>.
Ralph Goers wrote:
> No. If you reference a transitive dependency than the
> dependencyManagement of its parent will be used to provide the version.
> However, if the project being built defines the dependency, either in
> its pom or in a parent's dependencyManagement, than that will be used
> instead.
...
>> I don't think any of these options is desired. Our main goal should be
>> to keep our own dependency tree as clean as possible, ie <exclude>
>> transitive dependencies in 3rd party libs that are clearly
>> wrong/optional etc.
> Have you looked at the dependency analysis report? It is a mess.
...
>> Example: say i have a webapp pom that includes
>> - cocoon-core (which has CL 1.1)
>> - cocoon-thread-impl (which has CL 1.0.4)
>>
>> then maven will just select CL 1.1 for inclusion, not both. If i
>> however define in my webapp pom CL 1.0.4 then it will select only that.
> Wrong. Maven will choose the "nearest" which might be 1.1 or 1.0.4. The
> bottom line is you can never be sure. dependencyManagement allows you
> to define what versions should be used wherever they appear in the project.
>
Gosh and i thought maven was supposed to make dependencyManagement easy :-)
Jorg
(i stand corrected on all points btw, thanks for explaining the details)
Re: building trunk.
Posted by Ralph Goers <Ra...@dslextreme.com>.
Jorg Heymans wrote:
> Reinhard Poetz wrote:
>
>> I'm asking because I don't understand who the customers of creating a
>> <dependencyMangement> section in Cocoon are? Is it the Cocoon project
>> alone or also all projects that use Cocoon?
>
> AFAICT dependencyManagement does not come into play unless you're
> inheriting from the pom that declares it, so it would be only useful
> to us internally.
No. If you reference a transitive dependency than the
dependencyManagement of its parent will be used to provide the version.
However, if the project being built defines the dependency, either in
its pom or in a parent's dependencyManagement, than that will be used
instead.
>
>>
>> In the first case I doubt that there is much value in doing all this
>> work as long as the build runs through, isn't it?
>
> Agreed.
Disagree. See my reply to Reinhard.
>
>> Or is the idea that the user looks into our released parent pom and
>> copies our <dependencyMangement> section into his own project or even
>> inherits from our root pom?
>
> I don't think any of these options is desired. Our main goal should be
> to keep our own dependency tree as clean as possible, ie <exclude>
> transitive dependencies in 3rd party libs that are clearly
> wrong/optional etc.
Have you looked at the dependency analysis report? It is a mess.
>
> In any case, why wouldn't maven apply proper dependency resolution and
> selection when presented with multiple versions of the same artifact ?
Because it doesn't. See below and go look at MNG-1577.
>
> Example: say i have a webapp pom that includes
> - cocoon-core (which has CL 1.1)
> - cocoon-thread-impl (which has CL 1.0.4)
>
> then maven will just select CL 1.1 for inclusion, not both. If i
> however define in my webapp pom CL 1.0.4 then it will select only that.
Wrong. Maven will choose the "nearest" which might be 1.1 or 1.0.4. The
bottom line is you can never be sure. dependencyManagement allows you
to define what versions should be used wherever they appear in the project.
Ralph
Re: building trunk.
Posted by Jorg Heymans <jh...@apache.org>.
Reinhard Poetz wrote:
> I'm asking because I don't understand who the customers of creating a
> <dependencyMangement> section in Cocoon are? Is it the Cocoon project
> alone or also all projects that use Cocoon?
AFAICT dependencyManagement does not come into play unless you're
inheriting from the pom that declares it, so it would be only useful to
us internally.
>
> In the first case I doubt that there is much value in doing all this
> work as long as the build runs through, isn't it?
Agreed.
> Or is the idea that the user looks into our released parent pom and
> copies our <dependencyMangement> section into his own project or even
> inherits from our root pom?
I don't think any of these options is desired. Our main goal should be
to keep our own dependency tree as clean as possible, ie <exclude>
transitive dependencies in 3rd party libs that are clearly
wrong/optional etc.
In any case, why wouldn't maven apply proper dependency resolution and
selection when presented with multiple versions of the same artifact ?
Example: say i have a webapp pom that includes
- cocoon-core (which has CL 1.1)
- cocoon-thread-impl (which has CL 1.0.4)
then maven will just select CL 1.1 for inclusion, not both. If i however
define in my webapp pom CL 1.0.4 then it will select only that.
Regards,
Jorg
Re: building trunk.
Posted by Jorg Heymans <jh...@apache.org>.
Ralph Goers wrote:
>
>
> Jorg Heymans wrote:
>> What about the unwanted rubble that the user will inherit by extending
>> our root pom ? Some of it is harmless (developers, issueMgmt etc) but
>> other elements have a potential impact on a project (build plugins,
>> reporting). Most of our users will not understand the full scope of
>> what they're inheriting if they extend our root pom, and to be honest
>> i don't think we can expect them to.
>>
> The root pom doesn't have to be the current root pom. We could make a
> "master project" that contains the real root with pretty much nothing
> but the dependencyManagement.
>
+1 good idea.
Jorg
Re: building trunk.
Posted by Ralph Goers <Ra...@dslextreme.com>.
Jorg Heymans wrote:
> What about the unwanted rubble that the user will inherit by extending
> our root pom ? Some of it is harmless (developers, issueMgmt etc) but
> other elements have a potential impact on a project (build plugins,
> reporting). Most of our users will not understand the full scope of
> what they're inheriting if they extend our root pom, and to be honest
> i don't think we can expect them to.
>
The root pom doesn't have to be the current root pom. We could make a
"master project" that contains the real root with pretty much nothing
but the dependencyManagement.
Re: building trunk.
Posted by Jorg Heymans <jh...@apache.org>.
Ralph Goers wrote:
>> Or is the idea that the user looks into our released parent pom and
>> copies our <dependencyMangement> section into his own project or even
>> inherits from our root pom?
> If the user uses our root pom then they can be assured that the system
> will work. If they use different versions then they will have to verify
> that doing so doesn't cause any problems.
What about the unwanted rubble that the user will inherit by extending
our root pom ? Some of it is harmless (developers, issueMgmt etc) but
other elements have a potential impact on a project (build plugins,
reporting). Most of our users will not understand the full scope of what
they're inheriting if they extend our root pom, and to be honest i don't
think we can expect them to.
Regards,
Jorg
Re: building trunk.
Posted by Reinhard Poetz <re...@apache.org>.
Ralph Goers wrote:
> Giacomo Pati wrote:
>> I'v committed an initial dependencyManagement section in the root pom.
>>
>> The deps were gathered by concatenating all relevant poms into a big
>> xml document and run through an
>> xsl stylesheet which extracted all dependencies sorting them by
>> artifactId groupId. I've hand
>> crafted it afterwards to eliminate duplicates and put some TODOs into
>> it for duplicate artifactIds
>> with different groups.
>>
>> Next step would be to eliminate all version element from the sub poms,
>> right?
>>
>>
> Yes, that is correct. I knew we had smart people here - I wouldn't have
> thought of doing it that way. Thanks for the hard work!
thanks too :-)
As soon as the version numbers are removed, we have to make Maven 2.0.6 a
prerequisite. IIRC this can be set in the root pom.
--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}
web(log): http://www.poetz.cc
--------------------------------------------------------------------
Re: building trunk.
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
hepabolu wrote:
> Reinhard Poetz said the following on 16/4/07 13:07:
>> Giacomo Pati wrote:
>>
>>> Ok, so just for readybility. Do you use the eclipse XML-Formatter?
>>
>> no, I use OxygenXML but I do the formatting by hand. Basically I add
>> empty lines between the different sections and try to move the important
>
> I use OxygenXML too, and since I hate indenting by hand, I force 'empty'
> lines by adding formatted comments between the sections. Like:
>
> <!-- ************** new section here ************ -->
>
> enough to improve readability and Oxygen obeys. ;-)
I use the "standard" XML-Indentor comming with the XML editor (WTP?) which respects empty lines
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.3 (GNU/Linux)
iD8DBQFGI3vWLNdJvZjjVZARAhZDAJ45sEw1GeI3Kylil1exS4Oq4yK0DQCg5BOu
g8V0+rBGF9Pt/HE1DDApbqs=
=39zM
-----END PGP SIGNATURE-----
Re: building trunk.
Posted by hepabolu <he...@gmail.com>.
Reinhard Poetz said the following on 16/4/07 13:07:
> Giacomo Pati wrote:
>
>> Ok, so just for readybility. Do you use the eclipse XML-Formatter?
>
> no, I use OxygenXML but I do the formatting by hand. Basically I add
> empty lines between the different sections and try to move the important
I use OxygenXML too, and since I hate indenting by hand, I force 'empty'
lines by adding formatted comments between the sections. Like:
<!-- ************** new section here ************ -->
enough to improve readability and Oxygen obeys. ;-)
Bye, Helma
Re: building trunk.
Posted by Reinhard Poetz <re...@apache.org>.
Giacomo Pati wrote:
> Ok, so just for readybility. Do you use the eclipse XML-Formatter?
no, I use OxygenXML but I do the formatting by hand. Basically I add empty lines
between the different sections and try to move the important parts to the top
(though it could be discussed what important means).
--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}
web(log): http://www.poetz.cc
--------------------------------------------------------------------
Re: building trunk.
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Reinhard Poetz wrote:
> Giacomo Pati wrote:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>>
>>
>> Reinhard Poetz wrote:
>>> Giacomo Pati wrote:
>>>> -----BEGIN PGP SIGNED MESSAGE-----
>>>> Hash: SHA1
>>>>
>>>>
>>>>
>>>> Reinhard Poetz wrote:
>>>>> Giacomo Pati wrote:
>>>>>
>>>>>> That wasn't much of a hard work. The harder work will come next. I
>>>>>> thought making it the same way:
>>>>>> an XSLT that filters out all version elements from the dependencies
>>>>>> (and probably from the plugins
>>>>>> sections as well). WDYT
>>>>> Please make sure that the xslt transformation preservers the document
>>>>> structure of the pom files. At least the pom-updater scripts
>>>>> (trunk/tools/pom-updater) do so. IIRC they use xsltproc. Thanks!
>>>> What you mean by "preservers the document structure of the pom"?
>>> Sorry for being unclear, I meant whitespaces, linebreaks and indention.
>>
>> And why?
>
> As I often have to work with our pom files, it helps me if they are more
> readable.
Ok, so just for readybility. Do you use the eclipse XML-Formatter?
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.3 (GNU/Linux)
iD8DBQFGI0tzLNdJvZjjVZARAqrNAJ91qQ8hCIVVCGJ7+lXqFryrxeRhIACfVgcS
OoUV0C2fs2HRVvqEosfQloI=
=GLBR
-----END PGP SIGNATURE-----
Re: building trunk.
Posted by Reinhard Poetz <re...@apache.org>.
Giacomo Pati wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
>
>
> Reinhard Poetz wrote:
>> Giacomo Pati wrote:
>>> -----BEGIN PGP SIGNED MESSAGE-----
>>> Hash: SHA1
>>>
>>>
>>>
>>> Reinhard Poetz wrote:
>>>> Giacomo Pati wrote:
>>>>
>>>>> That wasn't much of a hard work. The harder work will come next. I
>>>>> thought making it the same way:
>>>>> an XSLT that filters out all version elements from the dependencies
>>>>> (and probably from the plugins
>>>>> sections as well). WDYT
>>>> Please make sure that the xslt transformation preservers the document
>>>> structure of the pom files. At least the pom-updater scripts
>>>> (trunk/tools/pom-updater) do so. IIRC they use xsltproc. Thanks!
>>> What you mean by "preservers the document structure of the pom"?
>> Sorry for being unclear, I meant whitespaces, linebreaks and indention.
>
> And why?
As I often have to work with our pom files, it helps me if they are more readable.
--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}
web(log): http://www.poetz.cc
--------------------------------------------------------------------
Re: building trunk.
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Reinhard Poetz wrote:
> Giacomo Pati wrote:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>>
>>
>> Reinhard Poetz wrote:
>>> Giacomo Pati wrote:
>>>
>>>> That wasn't much of a hard work. The harder work will come next. I
>>>> thought making it the same way:
>>>> an XSLT that filters out all version elements from the dependencies
>>>> (and probably from the plugins
>>>> sections as well). WDYT
>>> Please make sure that the xslt transformation preservers the document
>>> structure of the pom files. At least the pom-updater scripts
>>> (trunk/tools/pom-updater) do so. IIRC they use xsltproc. Thanks!
>>
>> What you mean by "preservers the document structure of the pom"?
>
> Sorry for being unclear, I meant whitespaces, linebreaks and indention.
And why?
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.3 (GNU/Linux)
iD8DBQFGI0MmLNdJvZjjVZARAqjMAKDvGwD4e8pxiBgS0blmvqXkY1dtgACeJssE
MOHygNhnYAygu75myoHEioI=
=dQBz
-----END PGP SIGNATURE-----
Re: building trunk.
Posted by Reinhard Poetz <re...@apache.org>.
Giacomo Pati wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
>
>
> Reinhard Poetz wrote:
>> Giacomo Pati wrote:
>>
>>> That wasn't much of a hard work. The harder work will come next. I
>>> thought making it the same way:
>>> an XSLT that filters out all version elements from the dependencies
>>> (and probably from the plugins
>>> sections as well). WDYT
>> Please make sure that the xslt transformation preservers the document
>> structure of the pom files. At least the pom-updater scripts
>> (trunk/tools/pom-updater) do so. IIRC they use xsltproc. Thanks!
>
> What you mean by "preservers the document structure of the pom"?
Sorry for being unclear, I meant whitespaces, linebreaks and indention.
--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}
web(log): http://www.poetz.cc
--------------------------------------------------------------------
Re: building trunk.
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Reinhard Poetz wrote:
> Giacomo Pati wrote:
>
>> That wasn't much of a hard work. The harder work will come next. I
>> thought making it the same way:
>> an XSLT that filters out all version elements from the dependencies
>> (and probably from the plugins
>> sections as well). WDYT
>
> Please make sure that the xslt transformation preservers the document
> structure of the pom files. At least the pom-updater scripts
> (trunk/tools/pom-updater) do so. IIRC they use xsltproc. Thanks!
What you mean by "preservers the document structure of the pom"?
Ciao
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.3 (GNU/Linux)
iD8DBQFGInTLLNdJvZjjVZARAihAAJ4pjHf6XqEiE100e2doiyXaVJus+ACeN3Kc
mvFA4kb/EtF+pcqaz7IJEZI=
=wb3I
-----END PGP SIGNATURE-----
Re: building trunk.
Posted by Reinhard Poetz <re...@apache.org>.
Giacomo Pati wrote:
> That wasn't much of a hard work. The harder work will come next. I thought making it the same way:
> an XSLT that filters out all version elements from the dependencies (and probably from the plugins
> sections as well). WDYT
Please make sure that the xslt transformation preservers the document structure
of the pom files. At least the pom-updater scripts (trunk/tools/pom-updater) do
so. IIRC they use xsltproc. Thanks!
--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}
web(log): http://www.poetz.cc
--------------------------------------------------------------------
Re: building trunk.
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Ralph Goers wrote:
> Giacomo Pati wrote:
>> I'v committed an initial dependencyManagement section in the root pom.
>>
>> The deps were gathered by concatenating all relevant poms into a big
>> xml document and run through an
>> xsl stylesheet which extracted all dependencies sorting them by
>> artifactId groupId. I've hand
>> crafted it afterwards to eliminate duplicates and put some TODOs into
>> it for duplicate artifactIds
>> with different groups.
>>
>> Next step would be to eliminate all version element from the sub poms,
>> right?
>>
>>
> Yes, that is correct. I knew we had smart people here - I wouldn't have
> thought of doing it that way. Thanks for the hard work!
That wasn't much of a hard work. The harder work will come next. I thought making it the same way:
an XSLT that filters out all version elements from the dependencies (and probably from the plugins
sections as well). WDYT
Ciao
>
> Ralph
>
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.3 (GNU/Linux)
iD8DBQFGH6L/LNdJvZjjVZARAvzpAJ4kqofCM5l2wbXQdEnmVZA2VilEeQCgr+MH
wYtJ0RI/W53O/xOYaUyvBrQ=
=aCU8
-----END PGP SIGNATURE-----
Re: building trunk.
Posted by Ralph Goers <Ra...@dslextreme.com>.
Giacomo Pati wrote:
> I'v committed an initial dependencyManagement section in the root pom.
>
> The deps were gathered by concatenating all relevant poms into a big xml document and run through an
> xsl stylesheet which extracted all dependencies sorting them by artifactId groupId. I've hand
> crafted it afterwards to eliminate duplicates and put some TODOs into it for duplicate artifactIds
> with different groups.
>
> Next step would be to eliminate all version element from the sub poms, right?
>
>
Yes, that is correct. I knew we had smart people here - I wouldn't have
thought of doing it that way. Thanks for the hard work!
Ralph
Re: building trunk.
Posted by Ralph Goers <Ra...@dslextreme.com>.
Jorg Heymans wrote:
> I think so yes, just wasn't sure. There are 2 sides to the story IMO.
> As you say its convenient for us because we have a default centralized
> internal versioning scheme for our modules. However our 'customers'
> will also end up with these versions, unless they ofcourse override in
> their own pom (right Ralph ?).
>
> I'm just thinking if the customer could introduce incompatibilities
> between blocks by overriding certain block versions and relying on the
> transitivity of others ?
>
> Example:
>
> <root depMgmt>
> core-1.0
> blockA-1.2
> blockB-0.4
> </root depMgmt>
>
> now our customer does in his pom
>
> <dependencies>
> blockA-1.4 (which transitively pulls in core-1.2)
> blockB (no version so he will get 0.4)
> </dependencies>
>
> If above scenario is correct and core-1.2 and blockB-0.4 are
> incompatible the he's in trouble and will have to explicitly introduce
> the new version of blockB. Or am i seeing ghosts ?
>
First, the root pom is versioned like anything else. So the user will
explicitly choose the version they want and if they extend it then what
you say is true. However, one would expect that if they are going to
explicitly override a version that they would accept the responsibility
for insuring that it is compatible and works. Basically, we are making
a guarantee that all the parts in our root pom play nice together. But
it is impossible to make that guarantee if the user just randomly picks
various blocks and third party components.
As an example, JBoss 4.0.5 comes prepackaged with log4j 1.2.8, but we
have some code that requires 1.2.13. We had to take on the
responsibility of verifying that JBoss would still run with that
version. The same is true of the 2.1 branch. We prepackage all our jars
in the lib directory and everything compiles against them. If I user
chooses to use a different version of one of the jars it is their
responsibility to test it.
Ralph
Ralph
Re: building trunk.
Posted by Jorg Heymans <jh...@apache.org>.
Giacomo Pati wrote:
>> I noticed that our own blocks are in the dependencymanagement as well.
>> Is this intended ?
>
> This way blocks don't have to specify versions when refering other blocks. Isn't that the way to go?
I think so yes, just wasn't sure. There are 2 sides to the story IMO. As
you say its convenient for us because we have a default centralized
internal versioning scheme for our modules. However our 'customers' will
also end up with these versions, unless they ofcourse override in their
own pom (right Ralph ?).
I'm just thinking if the customer could introduce incompatibilities
between blocks by overriding certain block versions and relying on the
transitivity of others ?
Example:
<root depMgmt>
core-1.0
blockA-1.2
blockB-0.4
</root depMgmt>
now our customer does in his pom
<dependencies>
blockA-1.4 (which transitively pulls in core-1.2)
blockB (no version so he will get 0.4)
</dependencies>
If above scenario is correct and core-1.2 and blockB-0.4 are
incompatible the he's in trouble and will have to explicitly introduce
the new version of blockB. Or am i seeing ghosts ?
Regards
Jorg
Re: building trunk.
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Jorg Heymans wrote:
> Giacomo Pati wrote:
>
>>
>> The deps were gathered by concatenating all relevant poms into a big
>> xml document and run through an
>> xsl stylesheet which extracted all dependencies sorting them by
>> artifactId groupId. I've hand
>> crafted it afterwards to eliminate duplicates and put some TODOs into
>> it for duplicate artifactIds
>> with different groups.
>
> nifty :)
>
> I noticed that our own blocks are in the dependencymanagement as well.
> Is this intended ?
This way blocks don't have to specify versions when refering other blocks. Isn't that the way to go?
Ciao
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.3 (GNU/Linux)
iD8DBQFGH6NrLNdJvZjjVZARAuRtAKDZGVbyuTQQ+2am6fwFxXvTPX+afwCguLew
GWcQBWCQ2kWIsbAIhw57KVU=
=yjoY
-----END PGP SIGNATURE-----
Re: building trunk.
Posted by Jorg Heymans <jh...@apache.org>.
Giacomo Pati wrote:
>
> The deps were gathered by concatenating all relevant poms into a big xml document and run through an
> xsl stylesheet which extracted all dependencies sorting them by artifactId groupId. I've hand
> crafted it afterwards to eliminate duplicates and put some TODOs into it for duplicate artifactIds
> with different groups.
nifty :)
I noticed that our own blocks are in the dependencymanagement as well.
Is this intended ?
Jorg
Re: building trunk.
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Giacomo Pati wrote:
>
>
> Reinhard Poetz wrote:
>>
>> Thanks for your explanations. Since dependency management finally works
>> as expected, I'd say go for it. Now we only need a volunteer ...
>
> As I've done it for another project I can take care of it (if you don't expect it to be there by
> tomorrow ;-)
I'v committed an initial dependencyManagement section in the root pom.
The deps were gathered by concatenating all relevant poms into a big xml document and run through an
xsl stylesheet which extracted all dependencies sorting them by artifactId groupId. I've hand
crafted it afterwards to eliminate duplicates and put some TODOs into it for duplicate artifactIds
with different groups.
Next step would be to eliminate all version element from the sub poms, right?
Ciao
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.3 (GNU/Linux)
iD8DBQFGHy+QLNdJvZjjVZARAiX5AKCALhrqinUkNG92XwR5R+dp++TK2QCgru2/
HoOcM94MmAdVSFxSsSjTMN8=
=qviL
-----END PGP SIGNATURE-----
Re: building trunk.
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Reinhard Poetz wrote:
> Ralph Goers wrote:
>> Reinhard Poetz wrote:
>>> If we use the dependency management section in our root pom, what
>>> will happen when we release one of our modules? Is the version
>>> information used and added to the <dependency> or is the fallback to
>>> the parent's pom depdencyManagement section still considered?
>> The root pom should also be in the Maven repository. The versions in
>> it are used when the module's pom is referenced.
>>>
>>> I'm asking because I don't understand who the customers of creating a
>>> <dependencyMangement> section in Cocoon are? Is it the Cocoon project
>>> alone or also all projects that use Cocoon?
>> Ideally, customers would also extend the root pom. If they don't
>> though, as I said above, the root pom will control what versions of
>> transitive dependencies are used just as if they had been specified in
>> the pom itself. However, if the customer has declares the dependencies
>> in their own pom or in a dependencyManagement section that will take
>> precedence.
>>>
>>> In the first case I doubt that there is much value in doing all this
>>> work as long as the build runs through, isn't it?
>> I disagree. The build is merrily rolling along using whatever
>> dependencies happen to get chosen. Then along comes cocoon-webapp
>> which has specific versions of the dependencies - which are not
>> necessarily the same version that was used for compilation. The only
>> way to know for sure that the system works in this scenario is to
>> bring up the sample site and exercise every single Cocoon component.
>>> Or is the idea that the user looks into our released parent pom and
>>> copies our <dependencyMangement> section into his own project or even
>>> inherits from our root pom?
>> If the user uses our root pom then they can be assured that the system
>> will work. If they use different versions then they will have to
>> verify that doing so doesn't cause any problems.
>
> Thanks for your explanations. Since dependency management finally works
> as expected, I'd say go for it. Now we only need a volunteer ...
As I've done it for another project I can take care of it (if you don't expect it to be there by
tomorrow ;-)
Ciao
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.3 (GNU/Linux)
iD8DBQFGHPNGLNdJvZjjVZARAqatAKDuqpz2ZWonB6QeFfUElZwMoa8xaQCfZcbG
kYJUy0bRLs9915s2u4EAxnQ=
=qAUD
-----END PGP SIGNATURE-----
Re: building trunk.
Posted by Reinhard Poetz <re...@apache.org>.
Ralph Goers wrote:
> Reinhard Poetz wrote:
>> If we use the dependency management section in our root pom, what will
>> happen when we release one of our modules? Is the version information
>> used and added to the <dependency> or is the fallback to the parent's
>> pom depdencyManagement section still considered?
> The root pom should also be in the Maven repository. The versions in it
> are used when the module's pom is referenced.
>>
>> I'm asking because I don't understand who the customers of creating a
>> <dependencyMangement> section in Cocoon are? Is it the Cocoon project
>> alone or also all projects that use Cocoon?
> Ideally, customers would also extend the root pom. If they don't though,
> as I said above, the root pom will control what versions of transitive
> dependencies are used just as if they had been specified in the pom
> itself. However, if the customer has declares the dependencies in their
> own pom or in a dependencyManagement section that will take precedence.
>>
>> In the first case I doubt that there is much value in doing all this
>> work as long as the build runs through, isn't it?
> I disagree. The build is merrily rolling along using whatever
> dependencies happen to get chosen. Then along comes cocoon-webapp which
> has specific versions of the dependencies - which are not necessarily
> the same version that was used for compilation. The only way to know
> for sure that the system works in this scenario is to bring up the
> sample site and exercise every single Cocoon component.
>> Or is the idea that the user looks into our released parent pom and
>> copies our <dependencyMangement> section into his own project or even
>> inherits from our root pom?
> If the user uses our root pom then they can be assured that the system
> will work. If they use different versions then they will have to verify
> that doing so doesn't cause any problems.
Thanks for your explanations. Since dependency management finally works as
expected, I'd say go for it. Now we only need a volunteer ...
--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}
web(log): http://www.poetz.cc
--------------------------------------------------------------------
___________________________________________________________
Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de
Re: building trunk.
Posted by Ralph Goers <Ra...@dslextreme.com>.
Reinhard Poetz wrote:
> If we use the dependency management section in our root pom, what will
> happen when we release one of our modules? Is the version information
> used and added to the <dependency> or is the fallback to the parent's
> pom depdencyManagement section still considered?
The root pom should also be in the Maven repository. The versions in it
are used when the module's pom is referenced.
>
> I'm asking because I don't understand who the customers of creating a
> <dependencyMangement> section in Cocoon are? Is it the Cocoon project
> alone or also all projects that use Cocoon?
Ideally, customers would also extend the root pom. If they don't though,
as I said above, the root pom will control what versions of transitive
dependencies are used just as if they had been specified in the pom
itself. However, if the customer has declares the dependencies in their
own pom or in a dependencyManagement section that will take precedence.
>
> In the first case I doubt that there is much value in doing all this
> work as long as the build runs through, isn't it?
I disagree. The build is merrily rolling along using whatever
dependencies happen to get chosen. Then along comes cocoon-webapp which
has specific versions of the dependencies - which are not necessarily
the same version that was used for compilation. The only way to know
for sure that the system works in this scenario is to bring up the
sample site and exercise every single Cocoon component.
> Or is the idea that the user looks into our released parent pom and
> copies our <dependencyMangement> section into his own project or even
> inherits from our root pom?
If the user uses our root pom then they can be assured that the system
will work. If they use different versions then they will have to verify
that doing so doesn't cause any problems.
Ralph
Re: building trunk.
Posted by Reinhard Poetz <re...@apache.org>.
Ralph Goers wrote:
> Given the number of projects in Cocoon I'm sure it is.
>
> Just for grins run mvn -P allblocks dependency:analyze. It will take a
> while but has tons of useful output.
>
> As an example, I've shown part of it below. You can see that
> commons-logging 1.1 is used as a transitive dependency for XML while
> commons-logging 1.0.4 is used as a transitive dependency for the
> Pipeline components. While it may not happen for commons-logging, in
> other cases when packaged up into a single webapp a runtime exception
> might likely occur. If commons-logging was placed in the
> dependencyManagement of the root pom than only that version would get
> used and presumably, if there is a problem, it would get detected during
> the build.
>
> Also notice that the Pipeline components below declares that it needs
> cocoon-configuration-api but doesn't actually use it.
>
> I'm sure that some really smart person could figure out how to write a
> perl script and take the output below or the output from mvn
> dependency:resolve and get it to generate all the dependencies.
If we use the dependency management section in our root pom, what will happen
when we release one of our modules? Is the version information used and added to
the <dependency> or is the fallback to the parent's pom depdencyManagement
section still considered?
I'm asking because I don't understand who the customers of creating a
<dependencyMangement> section in Cocoon are? Is it the Cocoon project alone or
also all projects that use Cocoon?
In the first case I doubt that there is much value in doing all this work as
long as the build runs through, isn't it?
Or is the idea that the user looks into our released parent pom and copies our
<dependencyMangement> section into his own project or even inherits from our
root pom?
--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}
web(log): http://www.poetz.cc
--------------------------------------------------------------------
___________________________________________________________
Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de
Re: building trunk.
Posted by Ralph Goers <Ra...@dslextreme.com>.
Given the number of projects in Cocoon I'm sure it is.
Just for grins run mvn -P allblocks dependency:analyze. It will take a
while but has tons of useful output.
As an example, I've shown part of it below. You can see that
commons-logging 1.1 is used as a transitive dependency for XML while
commons-logging 1.0.4 is used as a transitive dependency for the
Pipeline components. While it may not happen for commons-logging, in
other cases when packaged up into a single webapp a runtime exception
might likely occur. If commons-logging was placed in the
dependencyManagement of the root pom than only that version would get
used and presumably, if there is a problem, it would get detected during
the build.
Also notice that the Pipeline components below declares that it needs
cocoon-configuration-api but doesn't actually use it.
I'm sure that some really smart person could figure out how to write a
perl script and take the output below or the output from mvn
dependency:resolve and get it to generate all the dependencies.
[INFO] Building Cocoon XML Implementation
[INFO] task-segment: [dependency:analyze]
[INFO]
----------------------------------------------------------------------------
[INFO] Preparing dependency:analyze
[INFO] [resources:resources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [compiler:compile]
[INFO] Nothing to compile - all classes are up to date
[INFO] [resources:testResources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [compiler:testCompile]
[INFO] No sources to compile
[INFO] [dependency:analyze]
[INFO] Used declared dependencies:
[INFO] xml-apis:xml-apis:jar:1.3.02:compile
[INFO] xml-resolver:xml-resolver:jar:1.2:compile
[INFO] org.springframework:spring-context:jar:2.0.3:compile
[INFO] org.apache.cocoon:cocoon-xml-api:jar:1.0.0-RC1-SNAPSHOT:compile
[INFO] Used undeclared dependencies:
[WARNING] commons-logging:commons-logging:jar:1.1:compile
[WARNING] org.springframework:spring-beans:jar:2.0.3:compile
[WARNING] org.springframework:spring-core:jar:2.0.3:compile
[INFO] Unused declared dependencies:
[INFO] None
[WARNING] Potential problems discovered.
[INFO] Found Resolved Dependency / DependencyManagement mismatches:
[INFO] Nothing in DepMgt.
[INFO]
----------------------------------------------------------------------------
[INFO] Building Cocoon Pipeline Components
[INFO] task-segment: [dependency:analyze]
[INFO]
----------------------------------------------------------------------------
[INFO] Preparing dependency:analyze
[INFO] [resources:resources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [compiler:compile]
[INFO] Nothing to compile - all classes are up to date
[INFO] [resources:testResources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [compiler:testCompile]
[INFO] Nothing to compile - all classes are up to date
[INFO] [dependency:analyze]
[INFO] Used declared dependencies:
[INFO] javax.servlet:servlet-api:jar:2.4:provided
[INFO]
org.apache.cocoon:cocoon-pipeline-impl:jar:1.0.0-RC1-SNAPSHOT:compile
[INFO] org.apache.cocoon:cocoon-xml-api:jar:1.0.0-RC1-SNAPSHOT:compile
[INFO] org.apache.cocoon:cocoon-util:jar:1.0.0-RC1-SNAPSHOT:compile
[INFO] Used undeclared dependencies:
[WARNING]
org.apache.excalibur.components:excalibur-pool-api:jar:2.2.1:compile
[WARNING] xml-apis:xml-apis:jar:1.3.02:compile
[WARNING] commons-lang:commons-lang:jar:2.3:compile
[WARNING]
org.apache.avalon.framework:avalon-framework-api:jar:4.3.1:compile
[WARNING]
org.apache.excalibur.components:excalibur-xmlutil:jar:2.2.1:compile
[WARNING] jakarta-regexp:jakarta-regexp:jar:1.4:compile
[WARNING] commons-logging:commons-logging:jar:1.0.4:compile
[WARNING]
org.apache.excalibur.components:excalibur-store:jar:2.2.1:compile
[WARNING]
org.apache.excalibur.components:excalibur-sourceresolve:jar:2.2.1:compile
[WARNING]
org.apache.cocoon:cocoon-pipeline-api:jar:1.0.0-RC1-SNAPSHOT:compile
[INFO] Unused declared dependencies:
[INFO] org.apache.cocoon:cocoon-configuration-api:jar:1.0.0:compile
[WARNING] Potential problems discovered.
[INFO] Found Resolved Dependency / DependencyManagement mismatches:
[INFO] Nothing in DepMgt.
Reinhard Poetz wrote:
> Ralph Goers wrote:
>> Get rid of the versions in all the poms. Create a
>> dependencyManagement section in the root pom. Add all Cocoon
>> dependencies to the dependencyManagement section and specify the
>> version there.
>
> Could this be automatized? Doing this by hand sounds like an awful lot
> of work to me ...
>
Re: building trunk.
Posted by Reinhard Poetz <re...@apache.org>.
Ralph Goers wrote:
> Get rid of the versions in all the poms. Create a dependencyManagement
> section in the root pom. Add all Cocoon dependencies to the
> dependencyManagement section and specify the version there.
Could this be automatized? Doing this by hand sounds like an awful lot of work
to me ...
--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}
web(log): http://www.poetz.cc
--------------------------------------------------------------------
___________________________________________________________
Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de
Re: building trunk.
Posted by Ralph Goers <Ra...@dslextreme.com>.
Get rid of the versions in all the poms. Create a dependencyManagement
section in the root pom. Add all Cocoon dependencies to the
dependencyManagement section and specify the version there.
Maven 2.0.6 must be used for this to work properly.
Ralph
Reinhard Poetz wrote:
> Ralph Goers wrote:
>> Well, it is actually quite a bit worse than this. The below was
>> actually from running mvn idea:idea. After doing "mvn
>> -Dmaven.test.skip=true -P allblocks install" I ended up with 7
>> different version of xercesImpl, 3 versions of xerces and xalan, 5
>> versions of maven-artifact and even 2 versions of
>> cocoon-spring-configurator. There are many more than these; I just am
>> highlighting a few.
>
> So what do you suggest?
>
Re: building trunk.
Posted by Reinhard Poetz <re...@apache.org>.
Ralph Goers wrote:
> Well, it is actually quite a bit worse than this. The below was actually
> from running mvn idea:idea. After doing "mvn -Dmaven.test.skip=true -P
> allblocks install" I ended up with 7 different version of xercesImpl, 3
> versions of xerces and xalan, 5 versions of maven-artifact and even 2
> versions of cocoon-spring-configurator. There are many more than these;
> I just am highlighting a few.
So what do you suggest?
--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}
web(log): http://www.poetz.cc
--------------------------------------------------------------------
___________________________________________________________
Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de
Re: building trunk.
Posted by Ralph Goers <Ra...@dslextreme.com>.
Well, it is actually quite a bit worse than this. The below was actually
from running mvn idea:idea. After doing "mvn -Dmaven.test.skip=true -P
allblocks install" I ended up with 7 different version of xercesImpl, 3
versions of xerces and xalan, 5 versions of maven-artifact and even 2
versions of cocoon-spring-configurator. There are many more than these;
I just am highlighting a few.
Ralph Goers wrote:
> I ran a build of trunk and afterward ended up with the following
> duplicates in a clean local repository. It seems to me that there
> should only be one version of these used in a build.
>
> commons-collections/commons-collections/2.0
> commons-collections/commons-collections/3.2
> commons-logging/commons-logging/1.0
> commons-logging/commons-logging/1.0.4
> commons-logging/commons-logging/1.1
> javax/servlet/servlet-api/2.3
> javax/servlet/servlet-api/2.4
> junit/junit/3.8
> junit/junit/3.8.1
> junit/junit/3.8.2
> log4j/log4j/1.2.12
> log4j/log4j/1.2.14
> org/apache/maven/plugins/maven-plugins/1
> org/apache/maven/plugins/maven-plugins/3
> org/apache/maven/plugins/maven-plugins/7
> org/apache/maven/plugins/maven-plugins/8
> org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5
> org/apache/maven/wagon/wagon-provider-api/1.0-alpha-6
> org/codehaus/plexus/plexus/1.0.4
> org/codehaus/plexus/plexus/1.0.5
> org/codehaus/plexus/plexus/1.0.8
> org/codehaus/plexus/plexus-container-default/1.0-alpha-8
> org/codehaus/plexus/plexus-container-default/1.0-alpha-9
> org/codehaus/plexus/plexus-utils/1.0.4
> org/codehaus/plexus/plexus-utils/1.0.5
> org/codehaus/plexus/plexus-utils/1.1
> org/codehaus/plexus/plexus-utils/1.2
> org/springframework/spring-aop/2.0.2
> org/springframework/spring-aop/2.0.3
> org/springframework/spring-beans/2.0.2
> org/springframework/spring-beans/2.0.3
> org/springframework/spring-context/2.0.2
> org/springframework/spring-context/2.0.3
> org/springframework/spring-core/2.0.2
> org/springframework/spring-core/2.0.3
> org/springframework/spring-web/2.0.2
> org/springframework/spring-web/2.0.3
> xalan/xalan/2.7.0
> xerces/xerces/2.4.0
> xerces/xerces
> xerces/xercesImpl/2.4.0
> xerces/xercesImpl/2.8.0
> xerces/xercesImpl/2.8.1
> xml-apis/xml-apis/1.0.b2
> xml-apis/xml-apis/1.3.02
> xml-apis/xml-apis/2.0.2
> xml-resolver/xml-resolver/1.1
> xml-resolver/xml-resolver/1.2