目标部署路径与 POM 的预期路径前缀不匹配

The target deployment path does not match the POM's expected path prefix

我已经在新服务器上配置了 Jfrog Artifactory,并备份了旧的 repo,并试图将其导入到新服务器。

我在导入时收到以下错误:

java.lang.RuntimeException: 
Failed to validate pom file: The target deployment path 'jcenter-cache/org/springframework/spring-beans/4.3.8.RELEASE/spring-beans-4.3.8.RELEASE.pom' 
does not match the POM's expected path prefix 'org/springframework/spring-beans/4.3.8.RELEASE'. 
Please verify your POM content for correctness and make sure the source path is a valid Maven repository root path.

我创建的存储库是本地的,可以导入除 POM 文件之外的工件。

您似乎在尝试将导出的存储库名称作为您在本地存储库中的路径的一部分进行部署,我将解释:

Artifactory 有一个保护机制,可以帮助您确保 Maven 能够处理您的文件。这是通过确保 pom 文件按其布局部署来完成的。

您应该删除已导入到本地存储库的文件,然后再向下一层开始导入过程,这样 jcenter-cache 就不会成为导入路径的一部分。