MongoDbProvider refactored