
我的解決方案,maven倉庫中配置的地址不對。我們的項目使用的是私有倉庫地址,我最開始配置的是阿里雲公共的倉庫地址,后來我把阿里雲倉庫注釋掉,此時使用的是默認倉庫地址,這時還是報錯。如下所示:
<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>alimaven</id> <mirrorOf>central</mirrorOf> <name>aliyun maven</name> <url>http://maven.aliyun.com/nexus/content/repositories/central/</url> </mirror> --> </mirrors>
最后替換成公司私有的倉庫地址就可以了。
僅此記錄一下遇到的問題~
