WIP [NX-525] shared database support

https://issues.sonatype.org/browse/NX-525

also addresses:
https://issues.sonatype.org/browse/NEXUS-6698
https://issues.sonatype.org/browse/NEXUS-6619
Probably should make a RemoteDatabaseManager impl for this?  I don't object to having one of those around if they are useful, but I didn't feel like writing/porting this at the time, since it was not used I just killed it.