From 2db1a0f62b797acdb8506e7e36fbced0828dd796 Mon Sep 17 00:00:00 2001 From: Nicholas Kuechler Date: Wed, 27 Feb 2013 10:02:33 -0600 Subject: Adds retry on upload_vhd for xapi glance plugin Add a retry for the xapi glance plugin to handle transient issues when uploading the vhd. An example issue we're seeing is a connection timeout: ['XENAPI_PLUGIN_FAILURE', 'upload_vhd', 'error', "(110, 'Connection timed out')"] To work around transient issues such as a connection timeout, we should retry based on glance_num_retries before outright failing. Change-Id: Ice6fdd3dd39ef40e5997d69209aaafa66bff5d6e Fixes: bug #1134493 --- nova/exception.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'nova/exception.py') diff --git a/nova/exception.py b/nova/exception.py index cad1c5c02..d1037aabc 100644 --- a/nova/exception.py +++ b/nova/exception.py @@ -1080,6 +1080,10 @@ class CouldNotFetchImage(NovaException): message = _("Could not fetch image %(image_id)s") +class CouldNotUploadImage(NovaException): + message = _("Could not upload image %(image_id)s") + + class TaskAlreadyRunning(NovaException): message = _("Task %(task_name)s is already running on host %(host)s") -- cgit