Add the charm's workload status message to the callback so more detailed
information can be provided to the user.
Signed-off-by: Adam Israel <adam.israel@canonical.com>
Change-Id: I1bcd502a2470dd5a527bc88cf24f2e3e6753da91
self.ns_name,
delta.data['application'],
new_status,
self.ns_name,
delta.data['application'],
new_status,
+ new.workload_status_message,
*callback_args)
if old and not new:
*callback_args)
if old and not new:
self.ns_name,
delta.data['application'],
"removed",
self.ns_name,
delta.data['application'],
"removed",
*callback_args)
except Exception as e:
self.log.debug("[1] notify_callback exception {}".format(e))
*callback_args)
except Exception as e:
self.log.debug("[1] notify_callback exception {}".format(e))
"""Close any open connections."""
yield self.logout()
"""Close any open connections."""
yield self.logout()
- def notify_callback(self, model_name, application_name, status, callback=None, *callback_args):
+ def notify_callback(self, model_name, application_name, status, message, callback=None, *callback_args):
- callback(model_name, application_name, status, *callback_args)
+ callback(model_name, application_name, status, message, *callback_args)
except Exception as e:
self.log.error("[0] notify_callback exception {}".format(e))
raise e
except Exception as e:
self.log.error("[0] notify_callback exception {}".format(e))
raise e