com.youzan.cloud:open-sdk-core:pom:1.0.7-RELEASE failed to transfer from http://0.0.0.0/ during a previous attempt. This failure was cached in the local repository and resolution is not reattempted until the update interval of maven-default-http-blocker has elapsed or updates are forced. Original error: Could not transfer artifact com.youzan.cloud:open-sdk-core:pom:1.0.7-RELEASE from/to maven-default-http-blocker (http://0.0.0.0/): Blocked mirror for repositories: [baymax-releases (http://maven.youzanyun.com/repository/maven-releases/, default, releases+snapshots)]
com.youzan.cloud:open-sdk-gen:pom:1.0.7.202003242151-RELEASE failed to transfer from http://0.0.0.0/ during a previous attempt. This failure was cached in the local repository and resolution is not reattempted until the update interval of maven-default-http-blocker has elapsed or updates are forced. Original error: Could not transfer artifact com.youzan.cloud:open-sdk-gen:pom:1.0.7.202003242151-RELEASE from/to maven-default-http-blocker (http://0.0.0.0/): Blocked mirror for repositories: [baymax-releases (http://maven.youzanyun.com/repository/maven-releases/, default, releases+snapshots)]无法访问 Maven 3.8.1 http 仓库。可能的解决方案:
- 检查 Maven settings.xml 是否不包含 http 仓库
- 检查 Maven pom 文件是否不包含 http 仓库 http://maven.youzanyun.com/repository/maven-releases/
- 在 Maven settings.xml 中为 http://maven.youzanyun.com/repository/maven-releases/ 添加允许 http url 的镜像
- 在设置中将 Maven 降级到 3.8.1 或更早的版本
- 降低maven版本
1. 修改 Maven settings.xml
你需要修改你的Maven设置文件settings.xml
,通常位于~/.m2/
目录下(对于Linux/Unix)或C:\Users\[YourUsername]\.m2\
(对于Windows)。
添加以下镜像配置来允许HTTP访问:
<mirrors><mirror><id>maven-http-allow</id><mirrorOf>baymax-releases</mirrorOf><name>Maven Allow HTTP</name><url>http://maven.youzanyun.com/repository/maven-releases/</url></mirror>
</mirrors>
2、settings.xml
<mirrors><!-- mirror| Specifies a repository mirror site to use instead of a given repository. The repository that| this mirror serves has an ID that matches the mirrorOf element of this mirror. IDs are used| for inheritance and direct lookup purposes, and must be unique across the set of mirrors.|<mirror><id>mirrorId</id><mirrorOf>repositoryId</mirrorOf><name>Human Readable Name for this Mirror.</name><url>http://my.repository.com/repo/path</url></mirror>--><mirror><id>maven-default-http-blocker</id><mirrorOf>external:http:*</mirrorOf><name>Pseudo repository to mirror external repositories initially using HTTP.</name><url>http://0.0.0.0/</url><blocked>true</blocked></mirror><mirror><id>maven-http-allow</id><mirrorOf>baymax-releases</mirrorOf><name>Maven Allow HTTP</name><url>http://maven.youzanyun.com/repository/maven-releases/</url></mirror></mirrors>