def METHOD_NAME(self, collection_name):
    try:
        if self.has_collection(collection_name):
            self.collection = Collection(name=collection_name)
        else:
            raise Exception(
                f"There is no collection named:{collection_name}")
    except Exception as e:
        LOGGER.error(f"Failed to set collection in Milvus: {e}")
        sys.exit(1)