def bind_on_status_change(new_status, job_id): try: message = "Publishing LWR state change with status %s for job_id %s" % (new_status, job_id) log.debug(message) payload = manager_endpoint_util.full_status(manager, new_status, job_id) lwr_exchange.publish("status_update", payload) except: log.exception("Failure to publish LWR state change.") raise
def check_complete(manager, job_id): status = manager.get_status(job_id) return full_status(manager, status, job_id)