Log unhandled exceptions during task execution

Partially implements blueprint improve-engine-logging
Change-Id: I65196d3216d1c35b7f1d53c1c1e0f0421ecc7c68
This commit is contained in:
Steve McLellan 2014-05-05 10:06:43 -05:00
parent 3e7eaee594
commit a3004cd5cf

View File

@ -71,6 +71,8 @@ class TaskProcessingEndpoint(object):
except Exception as e: except Exception as e:
# TODO(gokrokve) report error here # TODO(gokrokve) report error here
# TODO(slagun) code below needs complete rewrite and redesign # TODO(slagun) code below needs complete rewrite and redesign
LOG.exception("Error during task execution for tenant %s",
env.tenant_id)
msg_env = Environment(task['model']['Objects']['?']['id']) msg_env = Environment(task['model']['Objects']['?']['id'])
reporter = status_reporter.StatusReporter() reporter = status_reporter.StatusReporter()
reporter.initialize(msg_env) reporter.initialize(msg_env)