maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörg Schaible <>
Subject Re: Best practice for declaring repos in open source projects
Date Mon, 16 Nov 2009 09:39:02 GMT
Stephen Connolly wrote at Montag, 16. November 2009 09:41:

> 2009/11/16 Kalle Korhonen <>:
>> There's been quite a few threads on declaring Maven repos in poms,
>> most of them referring to Brian's blog post
>> I agree with that 100%, but as you mention Brian, it's not black and
>> white for open source projects. I ran into the same issue again while
>> working on
>> The module depends on some artifacts located in Jboss repo. Their repo
>> is not synched to repo1 but artifacts originating from JBoss may or
>> may not be deployed to repo1 depending on version and project. I'm
>> naturally running my own nexus instance for my team's needs but
>> anybody else just checking out the module from svn or a CI system that
>> I'm not in control of (as in this case, it's Codehaus Bamboo instance)
>> will have a problem building this module.
>> To avoid "burning the entries forever into my released POMs" I figured
>> I could just the declare the repositories in a profile, for example
>> named "repositories". Technically they would still be in the pom but
>> wouldn't be used in normal dependency resolution, only if the user
>> specifically activated it. Since I typically never depend on external
>> snapshots, the profile would only be needed roughly once per set-up,
>> and it would also be easy to document and users to use. Brian, others,
>> do you think this would be a good idea for best practice? Better than
>> declaring them by default or not declaring them at all (and thus
>> either trying to strictly use only modules available in repo1,
>> lobbying required libs to be deployed to repo1 or just having to
>> document this for users and lobbying CI administrators to proxy
>> additional Maven repos)?
> The issue is that some repositories have different versions of
> artifacts deployed for the same version number.
> If you download the artifact from repoA it will never be re-downloaded
> even if repoA is no longer in your list of repositories and repoB has
> a different binary.
> This is especially an issue with, but other (non
> repositories have the same issue.

Especially the jboss repos have this issue also, because - as I understood -
they build all artifacts themselves from the source i.e. they also publish
a lot of stuff not directly originating from them and that is also
available in central. While they *should* produce the same things, you
actually can never be sure.


- Jörg

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message