-
Notifications
You must be signed in to change notification settings - Fork 82
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
remove-project-artifact doesn't remove metadata #64
Comments
The right approach is probably as Maven core does it and read and write the changes the following way: Reader reader = ReaderFactory.newXmlReader( metadataFile ); with proper catch clauses closing of the streams. |
Simply we should not edit maven-metadata-local.xml it is internal Maven feature and may be changed in some version |
As a workaround for a rough spot in Artifactory, I'm using
remove-project-artifact
to clear artifacts from test builds on a Jenkins server. However, the metadata for the removed artifact isn't cleared, which means that the next time that Jenkins tries to build a project that depends on "this" one with a matching version range, the downstream build fails because Jenkins can't resolve the "missing" version. These projects are not resolved from any external repository when built on the CI server.Reproduction:
remove-project-artifact
A:[0.1.0,0.2.0)
Expected behavior: B resolves the latest existing version of A (0.1.0). Instead, it resolves the removed version 0.1.1, and the Maven build fails.
Example
maven-metadata-local.xml
"before":Example after version 3.0.2 was installed and deleted (this will fail because 3.0.2 doesn't exist):
The text was updated successfully, but these errors were encountered: