Maven ไม่สามารถแก้ไขการขึ้นต่อกัน ไม่สามารถอ่านสิ่งประดิษฐ์ได้

ฉันกำลังติดตามบทช่วยสอนครั้งแรกกับ maven และไม่สามารถผ่านข้อผิดพลาดนี้ได้ ด้านล่างนี้เป็นไฟล์ pom; ลิงค์คือข้อผิดพลาด

รูปภาพข้อผิดพลาด

https://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0

<groupId>org.springframework</groupId>
<artifactId>gs-maven</artifactId>
<packaging>jar</packaging>
<version>0.1.0</version>

<properties>
    <maven.compiler.source>1.8</maven.compiler.source>
    <maven.compiler.target>1.8</maven.compiler.target>
</properties>

<build>
    <plugins>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-shade-plugin</artifactId>
            <version>2.1</version>
            <executions>
                <execution>
                    <phase>package</phase>
                    <goals>
                        <goal>shade</goal>
                    </goals>
                    <configuration>
                        <transformers>
                            <transformer
                                implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
                                <mainClass>hello.HelloWorld</mainClass>
                            </transformer>
                        </transformers>
                    </configuration>
                </execution>
            </executions>
        </plugin>
    </plugins>
</build>


person Imran Sandozi    schedule 19.08.2019    source แหล่งที่มา


คำตอบ (1)


พิมพ์ stacktrace ต่อไปนี้:

[ERROR] Plugin org.apache.maven.plugins:maven-resources-plugin:2.6 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-resources-plugin: jar:2.6: Could not transfer artifact

org.apache.maven.plugins :maven-resources-plugin:pom:2.6 from/to central <https://repo-maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo. maven.apache.org/151.101.184.215] failed: Connection timed out: connect -> [Help 1]
[ERROR ]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e swit

ส่วน Connect to repo.maven.apache.org:443 [repo. maven.apache.org/151.101.184.215] failed: Connection timed out: connect ระบุว่าการเชื่อมต่อกับ repo.maven.apache.org ล้มเหลว

คุณสามารถเชื่อมต่อกับ http://repo.maven.apache.org ในเบราว์เซอร์ของคุณหรือไม่? มีไฟร์วอลล์ใด ๆ ที่สามารถบล็อกได้หรือไม่?

person MaartenDev    schedule 19.08.2019
comment
ฉันสามารถเข้าถึง URL นั้นในเบราว์เซอร์ได้ มันแสดงโฟลเดอร์ไดเร็กทอรีให้ฉัน - person Imran Sandozi; 19.08.2019