Remove potential locks from the MongoDB on resource removal