New function to ensure and get a mongo collection.