Deduplicate Maven artifacts across multiple repositories - Sonatype Nexus Repository - Sonatype Community

Deduplicate Maven artifacts across multiple repositories

post by prasad.itv.116 on Aug 27, 2020

Is there any recommended ways to deduplicate maven artifacts across multiple repositories?

We have inherited a Nexus 3 Repository Manager where there are a lot of release artifacts duplicated across multiple repositories due to historical reasons and now we are facing issues with storage and need to find a way to clean them up.

We are open to any suggestions (even if it's a non-standard scripting approach),

Thanks,

Prasad.CH


post by jtom on Sep 1, 2020

Built-in cleanup procedures are documented here: https://help.sonatype.com/display/NXRM3/Cleanup+Policies

If your instance is old, I recommend upgrading to get access to everything on that page for sure.

Likely what you want, however, is https://issues.sonatype.org/browse/NEXUS-10821. Until that is implemented, you are somewhat limited to a date-based approach. I am skeptical there’s a scripted solution (and not one I’ve heard of), but I could be wrong.

Hope that helps a little,

Joe