Could not transfer artifact com.aliyun.oss:aliyun-sdk-oss:pom:3.8.0 from/to central (http://repo.maven.apache.org/maven2): Failed to transfer file: http://repo.maven.apache.org/maven2/com/aliyun/oss/aliyun-sdk-oss/3.8.0/aliyun-sdk-oss-3.8.0.pom. Return code is: 501 , ReasonPhrase:HTTPS Required.
我在maven工程中,引入依赖时发现这个问题,
<dependency>
<groupId>com.aliyun.oss</groupId>
<artifactId>aliyun-sdk-oss</artifactId>
<version>3.8.0</version>
</dependency>
接着就报了上面那个错误
解决办法:在maven的配置文件上,即settings.xml中,配置一下mirrors远程仓库镜像:
<mirrors>
<mirror>
<id>central</id>
<name>Maven Repository Switchboard</name>
<url>https://repo1.maven.org/maven2/</url>
<mirrorOf>central</mirrorOf>
</mirror>
</mirrors>
我的问题到此就解决了。你的呢?