Maven-Projekt kann nicht lokalisieren von Abhängigkeiten im lokalen repository

Ich habe ein maven-Projekt-setup.

In mein maven-POM-Datei, es ist wie folgt definiert:

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>com.myProject</groupId>
        <artifactId>basePOM</artifactId>
        <version>1.0</version>
        <relativePath>../../../shared/common/pom.xml</relativePath>
    </parent>

    <groupId>com.myProject.services</groupId>
    <artifactId>orderservice</artifactId>
    <version>developer</version>
    <packaging>war</packaging>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-resources-plugin</artifactId>
                <version>2.3</version>
                <configuration>
                    <encoding>UTF-8</encoding>
                </configuration>
            </plugin>
        </plugins>
    </build>

    <dependencies>
        <!--Internal dependencies-->
        <dependency>
            <groupId>com.myProject.shared</groupId>
            <artifactId>model</artifactId>
        </dependency>
        <dependency>
            <groupId>org.jboss.resteasy</groupId>
            <artifactId>resteasy-jaxrs</artifactId>
        </dependency>

        <dependency>
            <groupId>org.jboss.resteasy</groupId>
            <artifactId>resteasy-spring</artifactId>
        </dependency>
    </dependencies>
</project>

Ich habe ein parent-POM definiert einige Allgemeine bits:

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <name>Base POM</name>
    <groupId>com.myProject</groupId>
    <artifactId>basePOM</artifactId>
    <version>1.0</version>
    <packaging>pom</packaging>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>com.myProject.shared</groupId>
                <artifactId>model</artifactId>
                <version>developer</version>
            </dependency>

            <dependency>
                <groupId>org.jboss.resteasy</groupId>
                <artifactId>resteasy-jaxrs</artifactId>
                <version>1.2.GA</version>
                <exclusions>
                    <exclusion>
                        <groupId>org.slf4j</groupId>
                        <artifactId>slf4j-simple</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>

            <dependency>
                <groupId>org.jboss.resteasy</groupId>
                <artifactId>resteasy-spring</artifactId>
                <version>1.2.GA</version>
            </dependency>
        </dependencies>
    </dependencyManagement>
</project>

Wenn ich

mvn clean install

Des resteasy-jaxrs und resteasy-Frühling heruntergeladen auf mein lokales repository ohne problem.

Jedoch, es dann einen Fehler produziert, sagte:

**[ERROR] Failed to execute goal on project orderservice: Could not resolve dependencies for
 project com.mxyy.services:orderservice:war:developer: Failed to collect dependencies for
[com.mxyy.shared:model:jar:developer (compile), org.jboss.resteasy:resteasy-jaxrs:jar:1.2.
GA (compile), org.jboss.resteasy:resteasy-spring:jar:1.2.GA (compile), org.testng:testng:j
ar:jdk15:5.8 (test)]: Failed to read artifact descriptor for com.mxyy.shared:model:jar:dev
eloper: Failure to find com.mxyy:basePOM:pom:1.0 in http://repo.maven.apache.org/maven2 wa
s cached in the local repository, resolution will not be reattempted until the update inte
rval of central has elapsed or updates are forced -> [Help 1]**

Aussieht wie das Projekt nicht Abholung die Abhängigkeiten bereits in meinem lokalen repository.

Kann jemand lassen Sie mich wissen, wie kann ich dieses problem lösen?

Vielen Dank

Mehr Info:

Habe ich vorübergehend entfernt, die Abhängigkeit com.myProject.geteilt wird. Jetzt wird die Fehlermeldung angezeigt wird:

[ERROR] Failed to execute goal on project orderservice: Could not resolve dependencies for project com.mxyy.services:orderservice:war:developer: Faile
d to collect dependencies for [org.jboss.resteasy:resteasy-jaxrs:jar:1.2.GA (compile), org.jboss.resteasy:resteasy-spring:jar:1.2.GA (compile)]: Faile
d to read artifact descriptor for org.scannotation:scannotation:jar:1.0.2: Could not transfer artifact org.scannotation:scannotation:pom:1.0.2 from/to
 jboss (http://repository.jboss.org/maven2): Access denied to: http://repository.jboss.org/maven2/org/scannotation/scannotation/1.0.2/scannotation-1.0
.2.pom, ReasonPhrase:Forbidden. -> [Help 1]

InformationsquelleAutor Kevin | 2012-02-19

Schreibe einen Kommentar