Maven Build

时间:2018-06-14 13:11:46

标签: eclipse maven spring-boot apache-kafka

这是构建我的Maven项目时出现的错误。

项目来源:ProjectGithub link

设置:Windows上的Eclipse IDE。

  

[错误]无法在项目uicontroller-service上执行目标:无法解析项目的依赖关系poc.microsvc-angular:uicontroller-service:jar:0.1.0:无法在poc.microsvc-angular收集依赖关系:微服务-common:jar:0.0.1-SNAPSHOT - > org.apache.kafka:kafka_2.10:jar:0.8.2.1 - > org.apache.zookeeper:zookeeper:jar:3.4.6 - > org.slf4j:slf4j-log4j12:jar:1.7.21:无法读取org.slf4j的工件描述符:slf4j-log4j12:jar:1.7.21:无法传输工件org.slf4j:slf4j-log4j12:pom:1.7。 21从/到公共(https://globalrepository.mclocal.int/artifactory/public):连接超时 - > [帮助1]   [错误]

这是我的pom.xml文件:

<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>
<groupId>poc.microsvc-angular</groupId>
<artifactId>uicontroller-service</artifactId>
<version>0.1.0</version>
<packaging>jar</packaging>

<parent>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-parent</artifactId>
    <version>1.3.5.RELEASE</version>
    <relativePath />
</parent>

<properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <java.version>1.8</java.version>
    <docker.plugin.version>0.3.258</docker.plugin.version>
</properties>

<dependencies>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-test</artifactId>
        <scope>test</scope>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-websocket</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-messaging</artifactId>
    </dependency>
    <dependency>
        <groupId>poc.microsvc-angular</groupId>
        <artifactId>microservice-common</artifactId>
        <version>0.0.1-SNAPSHOT</version>
    </dependency>
</dependencies>

<build>
    <plugins>
        <plugin>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-maven-plugin</artifactId>
        </plugin>
        <plugin>
            <groupId>com.spotify</groupId>
            <artifactId>docker-maven-plugin</artifactId>
            <version>0.4.10</version>
            <configuration>
                <imageName>microsvc-angular/${project.name}</imageName>
                <dockerDirectory>${project.basedir}/src/main/docker</dockerDirectory>
                <skipDockerBuild>false</skipDockerBuild>
                <resources>
                    <resource>
                        <targetPath>/</targetPath>
                        <directory>${project.build.directory}</directory>
                        <include>${project.build.finalName}.jar</include>
                    </resource>
                </resources>
            </configuration>
        </plugin>
    </plugins>
</build>

是否存在腐烂的罐子或其他东西?

1 个答案:

答案 0 :(得分:0)

看起来您的本地~/.m2/settings.xmlC:\Users\myUserName\.m2\settings.xml for windows的配置指向maven central的公司/内部镜像。您可以暂时删除此功能以解决问题。