如何在Artifactory中重建maven-metadata.xml? [英] How to rebuild maven-metadata.xml in Artifactory?
问题描述
我们正在使用Artifactory 3.9.2
,并且不得不合并两个存储库的一部分(通过复制工件),这些存储库具有相同的工件(SNAPSHOT
版本).这搞砸了maven-metadata.xml
.在Nexus中,可以简单地为此工件重建元数据,并让存储库管理器为您整理内容.我似乎找不到关于如何使用Artifactory进行操作的任何链接/说明.有人可以告诉我我该怎么做吗?
We're using Artifactory 3.9.2
and had to merge parts of two repositories (by copying over the artifacts) which had the same (SNAPSHOT
-versioned) artifact. This screwed up the maven-metadata.xml
. In Nexus its possible to simply rebuild the metadata for this artifact and let the repository manager sort out things for you. I can't seem to find any links/explanations on how to do this with Artifactory. Could somebody please tell me how I can do this?
推荐答案
I'm not sure if this is possible in the UI, but you can do it using the REST API. Try posting a request using curl
:
curl -v -X POST http://artifactory/artifactory/api/maven/calculateMetadata/my-repository/com/foo/bar
他们决定将其称为计算元数据",而不是不太适合恕我直言的重建元数据".
They decided to call it "calculate metadata" instead of "rebuild metadata" which is not very suitable IMHO.
这篇关于如何在Artifactory中重建maven-metadata.xml?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!