Ejemplo n.º 1
0
    def any_cancels(self):
        """Determines if there are any task cancellations.

        :return: True if there is one or more tasks in cancelled state.
        """
        t_execs = lookup_utils.find_cancelled_task_executions(self.wf_ex.id)

        return len(t_execs) > 0
Ejemplo n.º 2
0
def _build_cancel_info_message(wf_ctrl, wf_ex):
    # Try to find where cancel is exactly.
    cancelled_tasks = sorted(lookup_utils.find_cancelled_task_executions(
        wf_ex.id),
                             key=lambda t: t.name)

    return ('Cancelled tasks: %s' %
            ', '.join([t.name for t in cancelled_tasks]))
Ejemplo n.º 3
0
    def any_cancels(self):
        """Determines if there are any task cancellations.

        :return: True if there is one or more tasks in cancelled state.
        """
        t_execs = lookup_utils.find_cancelled_task_executions(self.wf_ex.id)

        return len(t_execs) > 0
Ejemplo n.º 4
0
def _build_cancel_info_message(wf_ctrl, wf_ex):
    # Try to find where cancel is exactly.
    cancelled_tasks = sorted(
        lookup_utils.find_cancelled_task_executions(wf_ex.id),
        key=lambda t: t.name
    )

    return (
        'Cancelled tasks: %s' % ', '.join([t.name for t in cancelled_tasks])
    )