Does anyone know what result in this Java Project build failure and how to resolve it? Thanks!
有没有人知道这个Java项目的搭建失败是怎么造成的吗,要怎么解决呢? 多谢!
Detailed Logs
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.720s
[INFO] Finished at: Sat May 16 16:34:49 CST 2020
[INFO] Final Memory: 7M/123M
[INFO] ------------------------------------------------------------------------
[ERROR] Plugin org.apache.maven.plugins:maven-compiler-plugin:3.1 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-compiler-plugin:jar:3.1: Could not transfer artifact org.apache.maven.plugins:maven-compiler-plugin:pom:3.1 from/to central (http://repo.maven.apache.org/...: Failed to transfer file: http://repo.maven.apache.org/... Return code is: 501 , ReasonPhrase:HTTPS Required. -> [Help 1]
[ERROR]
The problem is resolved. As is shown in the log, the Maven plugin has been successfully downloaded.
这个问题被解决了。如日志所示,这个Maven插件已经被成功的下载下来了。
How is the problem resolved? 这个问题怎么解决的呢?
The problem is resolved after an upgrade of Maven through upgrade of the integrated development environment, a subsitute of Maven repository, and a subsititue of Maven settings file.
The new Maven version is 3.6.3.
The Maven 3 repository was originally empty and I copied and pasted all the dependencies from Maven 2's repository to Maven 3's repository. In the IDE, it was set that the Maven 3 's repository path overrides the bundled one.
The settings file was a minial existance of a Maven settings file, which only encloses an xml 1.0 header and a <settings> tab claiming namespaces. Therefore, the Apache Maven server was kept as the remote source. Neither mirror nor private Maven server was set up.
这里提供一个最简化的Maven配置文件。