Bug 1139016

Summary: Move all maven repositories references into top level pom.xml
Product: [Retired] oVirt Reporter: Yaniv Lavi <ylavi>
Component: ovirt-engine-coreAssignee: Alon Bar-Lev <alonbl>
Status: CLOSED CURRENTRELEASE QA Contact: Pavel Stehlik <pstehlik>
Severity: high Docs Contact:
Priority: high    
Version: 3.5CC: alonbl, bazulay, dougsland, ecohen, gklein, iheim, oourfali, rbalakri, yeylon
Target Milestone: ---Keywords: CodeChange
Target Release: 3.5.0   
Hardware: x86_64   
OS: Linux   
Whiteboard: infra
Fixed In Version: ovirt-3.5.0_rc3 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-10-17 12:21:18 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Infra RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Yaniv Lavi 2014-09-07 13:45:01 UTC
Description of problem:
I've installed maven and openjdk java\java-devel 1.7 on a clean el6 machine. When I try to build engine from source I get this error:

[ERROR] Failed to execute goal on project interface-common-jaxrs: Could not resolve dependencies for project org.ovirt.engine.api:interface-common-jaxrs:jar:3.5.0-SNAPSHOT: Could not find artifact org.ovirt.ovirt-host-deploy:ovirt-host-deploy:jar:1.3.0-master-SNAPSHOT -> [Help 1]

To my understanding this is because this repo with artifact is missing:
https://oss.sonatype.org/content/repositories/snapshots/org/ovirt/ovirt-host-deploy/ovirt-host-deploy/1.3.0-master-SNAPSHOT/

This should be added to project, so it can be built without needing to add this to maven's settings.xml.
 
Version-Release number of selected component (if applicable):
3.5

How reproducible:
Always

Steps to Reproduce:
1. install fresh el6 machine.
2. Install maven and openjdk java\java-devel 1.7.
3. try to build.

Actual results:
error:
[ERROR] Failed to execute goal on project interface-common-jaxrs: Could not resolve dependencies for project org.ovirt.engine.api:interface-common-jaxrs:jar:3.5.0-SNAPSHOT: Could not find artifact org.ovirt.ovirt-host-deploy:ovirt-host-deploy:jar:1.3.0-master-SNAPSHOT -> [Help 1]

Expected results:
Should pull all deps and build correctly.

Additional info:

Comment 1 Yaniv Lavi 2014-09-07 13:48:31 UTC
This should be added to pom:
"""
<repository>
    <id>mvn-releases</id>
    <url>
        https://oss.sonatype.org/content/repositories/snapshots
    </url>
    <releases></releases>
    <snapshots>
        <enabled>true</enabled>
    </snapshots>
</repository>
"""

Comment 2 Alon Bar-Lev 2014-09-08 08:14:32 UTC
artifact it not missing, follow maven-metadata.xml and see what it refers, and it does exists.

I just confirmed once again... just to make sure.

if you think that this is el6 specific, please try to use upstream maven as-is[1]

[1] http://apache.mivzakim.net/maven/maven-3/3.2.3/binaries/apache-maven-3.2.3-bin.tar.gz

Comment 3 Alon Bar-Lev 2014-09-10 12:04:36 UTC
Having multiple repositories under different names cause maven to be confused, there should be a reference for external repositories only in top level pom.xml per project (parent).

Comment 4 Sandro Bonazzola 2014-10-17 12:21:18 UTC
oVirt 3.5 has been released and should include the fix for this issue.