2018年6月,为了提高安全性和符合现代标准,不安全的TLS 1.0和1.1协议将不再支持SSL连接到Central。这只会影响Java 6的用户,这些用户也在使用https访问中央,根据我们的标准,中央用户不到2%。
有关更多细节和解决方法,请参见博客和常见问题解答:https://blog.sonatype.com/enhancing-ssl-security-and-http/2-support-for-central
解决办法
maven的setting.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>nexus-aliyun</id>
<mirrorOf>*</mirrorOf>
<name>Nexus aliyun</name>
<url>http://maven.aliyun.com/nexus/content/groups/public</url>
</mirror>
</mirrors>
|
然后就ok了