From bf8774b80970357048e1d9353383a42ebe811c2c Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Thu, 25 May 2017 09:29:30 -0500 Subject: [PATCH] Log specific error message from RetriableConnectionFailure There are more than one error from keystoneauth that can match RetriableConnectionFailure. We retry on all of them, but logging the whole message can be useful for debugging. Change-Id: I2fd3bf62a3a755281d34ff5d3624b835281604fb --- shade/task_manager.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/shade/task_manager.py b/shade/task_manager.py index 430a2585d..d890b8a2c 100644 --- a/shade/task_manager.py +++ b/shade/task_manager.py @@ -108,10 +108,11 @@ class BaseTask(object): # Keep time for connection retrying logging start = time.time() self.done(self.main(client)) - except keystoneauth1.exceptions.RetriableConnectionFailure: + except keystoneauth1.exceptions.RetriableConnectionFailure as e: end = time.time() dt = end - start if client.region_name: + client.log.debug(str(e)) client.log.debug( "Connection failure on %(cloud)s:%(region)s" " for %(name)s after %(secs)s seconds, retrying",