Used configuration datastoreImpl to detect mongo before using Holders

This is not intended as a final fix (as we haven't foun one yet), but on our project it served to workaround Issue #70