sonatype/nexus — pull request #135 by cstamas (2011-12-08 14:27:20+00:00)
Title: Remove key dependencies from Nexus Core

This is a follow-up of the "Timeline into plugin" pull request (https://github.com/sonatype/nexus/pull/116).

This pull request contains following changes:

* moving Timeline into a plugin (exactly same as in referenced pull request)
* removing Aether from Nexus Core (it's also "too important" stuff to pin it in core)
* removing Maven Indexer Artifact from core (more about this later)

The artifacts not in core classloader anymore (once this pull request applied):
* org.apache.lucene:lucene-core
* com.google.protobuf:protobuf-java
* jdom:jdom
* rome:rome
* org.sonatype.aether:* (all 4 of them)
* org.apache.maven.indexer:indexer-artifact

All the "What does it buys for us?" explanation from referenced pull request still stands, and much more.

About Maven Indexer Artifact

This artifact contained classes that were originally part of Nexus. As we started Nexus indexer, those classes were also used in it. Later, as we moved Nexus Indexer into a plugin, we still left these classes in core. Meanwhile, many of the classes (well, some key classes at least) forms the basis of Nexus' Maven support too (just look at MavenRepository iface, and others). After donating the Indexer as "whole" to ASF, Nexus Maven support started relying on key classes not being present in Nexus core (like Gav, GavCalculator, etc). This led to similar "hostage" situation as we had with Timeline + Lucene (mentioned in previous pull request). Also, we had to make compromises wrt improvements we do, considering Maven Indexer other -- non Nexus -- integrations. All these just slowed down and complicated our advancement.

Maven Indexer _needs_ these classes, but does not use them in API. Nexus Maven support in contrary _needs_ them, but also _publishes them in API_ (again, see MavenRepository as example). Hence, they were "backforked", put in their proper packages and Core is changed to use them instead. Maven Indexer now has it's "own" indexer-artifact artifact as plugin dependency, while Nexus Core got back it's key classes needed for Maven support (with currently present compromises cleaned up).