Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Should we use Nexus or Artifactory for a Maven Repo? [closed]

People also ask

Which is better nexus or Artifactory?

Artifactory has a slight lead in the number of supported repo types, but Nexus provides you with OSGi interfaces, enabling you to make custom repository types if needed.

What is difference between Nexus and JFrog Artifactory?

Sonatype Nexus performs a health check on a repository. JFrog's Xray scans for both regulatory issues and vulnerabilities as well. JFrog tightly links Xray to its Artifactory repository, which provides metadata the tool uses to parse linkages between code components, libraries, production applications and projects.

What is the difference between Maven and Nexus?

Sonatype Nexus and Apache Maven are two pieces of software that often work together but they do very different parts of the job. Nexus provides a repository while Maven uses a repository to build software. Here's a quote from "What is Nexus?": Nexus manages software "artifacts" required for development.

Is Artifactory a Maven repository?

Overview. As a Maven repository, Artifactory is both a source for artifacts needed for a build, and a target to deploy artifacts generated in the build process. Maven is configured using a settings. xml file located under your Maven home directory (typically, this will be /user.


I'm sure that if you only talk about storing binaries from "mvn deploy" both will do fine.

We use Artifactory very extensively with all upgrades along the way. Lots of projects, numerous snapshots deployed and external repos proxied. Not a single problem. I find it hard to explain how other people experience issues with its DB, indexing or anything else. Nothing like that ever happened to us. Also, Artifactory allows to store data on a disk and only use a DB for storing metadata, it is quite flexible (see more here).

What makes those applications very different is their approach towards integration with other build tools and technologies. Nexus and Sonatype are pretty much locked on Maven and m2eclipse. They ignore anything else and only recently started to work on their own proprietary Hudson integration (see their Maven 3 webinar). EDIT: This is not true anymore as of 2017 Nexus gives a much larger support for other build tools End of Edit

Artifactory provides an awesome Hudson, TeamCity and Bamboo integration, and Gradle / Ivy support. So while Nexus gives you nothing once you step out of Sonatype "comfort zone" (Maven, m2eclipse), Artifactory embraces and collaborates with all major build tools.

In fact, being able to deploy build artifacts from Hudson, when job has finished, and not by "mvn deploy" is a huge difference: Artifactory Hudson plugin makes an atomic-like deploy of all artifacts at once, only when a build job finished successfully. "mvn deploy" runs after each module and can deploy a partial set of artifacts if a build job fails in the middle. Deploying from Maven on module completion and not from a build server on job completion is really a bad thing to do.

As you see, Artifactory thinks "outside the box" while Nexus thinks "inside the box" and only cares about Maven and Maven artifacts.

Something else that makes Artifactory more accessible is their cloud-based Artifactory Online solution. For about $80 a month you have your own Artifactory instance, no need to dedicate any server for it.

Artifactory has a simple and straightforward REST API, don't know how it works for Nexus. Edit Nexus has also a REST API that you can use easily as well.

To summarize, for basic storage of Maven artifacts I think both are fine. But while Nexus stops there being strictly a "Maven repository manager", Artifactory goes on and on, being a general "Binaries storage" for binaries of any kind, from any build tool and CI server.


I don't know about Artifactory but here are my reasons for using Nexus:

  • Dead simple install (and since 1.2, dead simple upgrade, too)
  • Very good web UI
  • Easy to maintain, almost no administrative overhead
  • Provides you with RSS feeds of recently installed, broken artifacts and errors
  • It can group several repositories so you can mirror several sources but need only one or two entries in your settings.xml
  • Deploying from Maven works out of the box (no need for WebDAV hacks, etc).
  • it's free
  • You can redirect access paths (i.e. some broken pom.xml requires "a.b.c" from "xxx"). Instead of patching the POM, you can fix the bug in Nexus and redirect the request to the place where the artifact really is.

Artifactory supports both file-system and database storage backends. Storage is checksum based and identical binaries are stored only once, no matter how many times they appear in the repo, which makes Artifactory more efficient storage-wise. Move and copy are also very cheap because of this architecture (in Nexus there's no REST for move/copy - you have to move stuff on the file system, then run corrective actions on the repo to let it know content has changed).

Another important differentiator is Artifactory has unique integration with Hudson and TeamCity for capturing information about deployed artifacts, resolved dependencies and environment data associated with build runs, which provides full build traceability.


Artifactory stores the artifacts in a database, which means that if something goes wrong, all your artifacts are gone. Nexus uses a flat file for your precious artifacts so you don't have to worry about them all getting lost.