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
this lock might get a lot of contention on a high-traffic server, since it will be obtained/released for every call to ProviderImpl.get()...probably not worth sweating over ATM, but if it becomes a noticeable problem, eagerly initting the instances would avoid the need for synchronizing on the map