:
Skip Navigation
Resources Blog Publishing Your Artifacts to the Central Repository

Publishing Your Artifacts to the Central Repository

If your project's artifacts are published to the Central Repository it is trivial for your users to add a dependency and start using your project's library or framework, but if your project is hosted somewhere like Sourceforge and there is no repository manager or repository setup for synchronizing to the Central Repository, getting your artifacts into Central can be a pain. The old process for publishing your artifacts to Central required several manual steps for you and for the Maven team to setup and enable an rsync location... assuming you can find a location to host your files at all.

At Sonatype, we want to make synchronizing and publishing your artifacts to Central easier both for you and for us, and we want to improve the quality of repository metadata for everyone at the same time. We have set up a dedicated instance of Sonatype Pro for Nexus at http://oss.sonatype.org specifically to host the artifacts of other Open Source projects. In this post, I talk about the process of creating a repository for your open source projects and publishing artifacts so that they will be available from the Central Repository.

This service has been available since 2009 and includes many projects such as Plexus, Jetty, Google Guice, Spring and Ehcache (Greg wrote about his experience with migrating to oss.sonatype.org). We have tooling in place to make it easy for us to process a larger set of requests, so we invite everyone to use this resource. As of October, 2011, we have over 1500 projects using this repository on a daily basis.

To get the process started, go here. We'll setup a release and snapshot repository for your project, along with the appropriate configuration to allow you to use the staging features for your releases. If you have an existing repository somewhere, we can migrate that for you too.

Since the Sonatype machines are hosted on the same infrastructure as the Central Repository, we are able to synchronize the repositories every hour instead of twice a day.

The system allows customizable rules to be run during the staging process, which allows us to automatically check things like valid pgp signatures and correct POM parsing. This will ensure that your users have the best experience possible when using your artifacts, and relieve some of the manual validation on your side, a win for everyone.

On the technical details, this instance gets its network connection via Contegix's high availability network, the same one running Central (and Codehaus.org and Atlassian.com), and New Relic has donated monitoring services to help us monitor and tune this instance of Nexus.

Picture of Brian Fox

Written by Brian Fox

Brian Fox is a software developer, innovator and entrepreneur. He is an active contributor within the open source development community, most prominently as a member of the Apache Software Foundation and former Chair of the Apache Maven project. As the CTO and co-founder of Sonatype, he is focused on building a platform for developers and DevOps professionals to build high-quality, secure applications with open source components.