Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be unavailable on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 1345752 - Unnecessary artifacts in maven repository
Summary: Unnecessary artifacts in maven repository
Alias: None
Product: JBoss Data Virtualization 6
Classification: JBoss
Component: Distribution
Version: 6.3.0
Hardware: Unspecified
OS: Unspecified
Target Milestone: ER5
: 6.3.0
Assignee: Petr Kočandrle
QA Contact: Juraj Duráni
Depends On:
TreeView+ depends on / blocked
Reported: 2016-06-13 06:45 UTC by Juraj Duráni
Modified: 2016-08-24 11:38 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2016-08-24 11:38:07 UTC
Type: Bug

Attachments (Terms of Use)
dependency-not-found errors (5.33 KB, text/plain)
2016-06-13 06:45 UTC, Juraj Duráni
no flags Details

Description Juraj Duráni 2016-06-13 06:45:27 UTC
Created attachment 1167243 [details]
dependency-not-found errors

Description of problem:
Maven repository contains some artifacts, which seem to be not referenced by any Teiid/ModeShape related artifact [1]. Those artifacts cause depedency-not-found errors (which, I suppose, are not very serious) in testing because there are unsatisfied dependencies for those artifacts.
For more details see attachment [2]. In the report, you can see that none of the paths contains Teiid/ModeShape related artifact. Therefore, I think that those dependencies could be removed from the repository. Removing them from the repo could also decrease size of the repository.

Additional info:
I removed mentioned artifacts and tried to build quickstarts and create new connector and translator project via archetype. Both tests pass.

[1] unnecessary artifacts:

For each missing dependency (miss:...) you can see which artifact depends on it (one or more from:...) with optional "transitive path" if it is not a direct dependency (path:...).

Comment 1 Alex Szczuczko 2016-06-13 13:15:00 UTC
The repo builder uses one of the most complete dependency detection systems (not all dependencies are properly declared in POM files unfortunately), but it is pretty complicated, so might be including things by mistake.

I don't know what process the validator uses for its depedency-not-found check, but if it's just looking at the dependency entries in the poms, that's only going to be valid in some/most cases.

Comment 2 Juraj Duráni 2016-06-14 05:33:01 UTC
Yes, that's exactly what it is doing. It tries to resolve all dependencies in POM in provided repositories (validated repository, maven central, and optionally some more).

Comment 3 Petr Kočandrle 2016-06-16 12:40:12 UTC
* org.scannotation:scannotation:pom:1.0.3.redhat-4 is required to build org.jboss.teiid.quickstart:webservices-as-a-datasource:3.0.0.redhat-63-8
* org.jboss.remotingjmx:remoting-jmx:1.1.3.Final-redhat-2 is a transitive dependency of teiid-adminshell and teiid-jboss-admin
* net.java.dev.msv:msv-core:2011.1-redhat-2 is a transitive dependency of org.modeshape:modeshape-web-jcr-rest-war:3.8.4.GA-redhat-8 which is one of the roots used for repo generation, but is not included in the end because it is a war artifact; apart from that it is optional transitive dependency of many quickstarts introduced by maven-compiler-plugin and the version is managed by our BOM... but in this case I'm not sure if a plugin's dependencies can be managed by a BOM, so this is probably wrong

The rest (and also those mentioned above) are pulled in as dependencies of org.jboss.teiid:test-integration-common:8.12.5.redhat-6 which unpacks jboss-as-dist on which they depend transitively. I think they should not be included, because we don't need to have test-integration-common rebuildable with the repo and the jboss-as-dist is a buildtime dependency. BTW should we include test-integration-* at all?

Comment 4 Petr Kočandrle 2016-06-16 13:11:36 UTC
And regarding the missing dependencies - they are managed by our BOM to different version or not managed by the BOM, so the version from the pom is used, e.g.
* jaxb-impl is managed to version 2.2.5.redhat-9 (included)
* jaxws-rt is not managed, so 2.1.4 available in central is used
* commons-collections is managed to version 3.2.1.redhat-7
* ...

So I think the validator is not set up correctly to use the same BOM as we do with the repository build or there is a bug. And please note that not all artifacts in the repository should match the versions in the BOM, because for quickstart builds the BOM is not injected by the repository builder, but it relies on the one used in the quickstart's pom, so they can resolve different versions if they use different BOM.

Comment 5 Lucie Fabrikova 2016-07-04 10:08:36 UTC
In maven repository of ER5, all mentioned artifacts are removed except for:

Comment 6 Juraj Duráni 2016-07-07 05:16:38 UTC
Setting to VERIFIED. See comments 3 and 5.

Note You need to log in before you can comment on or make changes to this bug.