sonatype/nexus — pull request #103 by cstamas (2011-11-24 22:47:52+00:00)
Title: Nexus attributes verbesserung

A massive one:

* opening up for other serializators, not being chained to XStream (as today)
* slimming down AttributeStorage iface, because since Nexus 1.4 there was no need to persist whole StorageItem, the attributes was enough (it was a leftover since Proximity)
* StorageItem cleanup, before it was: a bunch of transient fields, a bunch of persisted fields and one persisted map. Now, an item is: transient map (context, as before), persisted map (attributes, and everything else, the actual data)
* upgrade path provided: if attributes detected in old place, "legacy" AttributeStore kicks in and Nexus seamlessly upgrades attribues to new ones (as Nexus is used).
* current attribute storage is LS attribute storage (attributes as below storage/repo-id/.nexus/attributes) and have new, cleaner format, they are just a Map (series of key-val pairs).

In previous pull https://github.com/sonatype/nexus/pull/93 Marshaller iface is already provided. There, only the XStreamMarshaller was viable (jacksons were unable to cope with Item classes). Here, we have them all: XstreamMarshaller, but JacksonJSON and JacksonXML worx too! As I measured, JacksonJSON is a bit better over Xstream (about 10%-ish), but this is CPU only, since IO is clearly the same (no much size differences).

And once Jackson enters core, nothing will stop it to come all way to the REST API ;)
Just watch! :beer: