Brett Porter wrote:
> Currently, no there isn't a way to do this.
> 
> I've got something on the list for beta-1 to make this possible (see
> inclusions), but it is highly recommended that you track the problem and
> have it fixed. We've been really reluctant to add this because
> technically it shouldn't be required and because it will certainly
> become a crutch and we'll stop getting feedback on bad poms.
> 
> What are you experiencing problems with?
> 
I don't think that this is just because of bad poms. Current in Cocoon
we face two problems:
1) Avalon framework. Up to version 4.1.0 (or something) Avalon had one
big jar: the avalon framework. Then starting with 4.1.1 they splitt this
into two jar files: api and impl. But for convenience they provide both
versions, so for example, you have
avalon-framework-4.2.0.jar
avalon-framework-api-4.2.0.jar
avalon-framework-impl-4.2.0.jar

Now Cocoon depends on 4.2.0 api and impl which of course works fine. We
use several other projects, that depend on avalon-framework-4.1.5. As
this is a different identifier for the jar we end up with
avalon-framework-4.1.5 and api/impl from 4.2.0 resulting in errors as
4.1.5 is loaded before the other two jars! (Compilation works fine of
course).
All poms are imho correct. And there are several projects having these
different dependencies. So everywhere specifying exclude statements
can't be the solution.

2) servletapi.jar. Now, we depend on this jar, but it shouldn't go into
the webapp. Fortunately this is possible and works. Unfortunately we
depend on onther project that depends on the servletapi where it's not
specified that the jar should not go into the webapp, because that
project doesn't provide a webapp, it's just a framework. Now, you can
guess what happens, we end up with the servletapi in the WEB-INF/lib
directory, just because of the transitive dependency.

Sure, if all poms all over the world would be correct (whatever that
means) these problems can be avoided. But I don't think that this will
ever really happen. Basically I think the transitive dependencies are a
good idea, but I would like to turn them off and then perhaps get a
warning if some dependency might be missing.

In fact I think one of the biggest problems are unique identifier for
artifacts. I guess you have already discussed this. As long as everyone
can pick up an identifier he thinks is good, POMs will never be perfect.
Look at the xml-apis mess or projects like jakarta regexp where the
group id is just regexp, or projects using different ids, like avalon
logkit (using just logkit, excalibur-logkit and god knows what else).

So I agree that theoretically it shouldn't be required but practically
it will be. :)

Carsten
-- 
Carsten Ziegeler - Open Source Group, S&N AG
http://www.s-und-n.de
http://www.osoco.org/weblogs/rael/

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to