Move the delete DB entry to the metadata thread, because it can be slow