contrib/runners/mistral_v2/query/mistral_v2.py
def _get_workflow_tasks(self, exec_id, last_query_time=None):
        """
        Returns the list of tasks for a workflow execution.
        :param exec_id: Mistral execution ID
        :type exec_id: ``str``
        :param last_query_time: Timestamp to filter tasks
        :type last_query_time: ``str``
        :rtype: ``list``
        """
        result = []

        try:
            query_filters = {}

            if last_query_time:
                query_filters['updated_at'] = 'gte:%s' % last_query_time

            wf_tasks = self._client.tasks.list(workflow_execution_id=exec_id, **query_filters)

            for wf_task in wf_tasks:
                result.append(self._client.tasks.get(wf_task.id))

                # Lets not blast requests but just space it out for better CPU profile
                jitter = random.uniform(0, self._jitter)
                eventlet.sleep(jitter)
        except mistralclient_base.APIException as mistral_exc:
            if 'not found' in mistral_exc.message:
                raise exceptions.ReferenceNotFoundError(mistral_exc.message)
            raise mistral_exc

        return [self._format_task_result(task=entry.to_dict()) for entry in result]

        Returns the list of tasks for a workflow execution.
        :param exec_id: Mistral execution ID
        :type exec_id: ``str``
        :param last_query_time: Timestamp to filter tasks
        :type last_query_time: ``str``
        :rtype: ``list``
        
Returns the list of tasks for a workflow execution.
Returns the list of tasks for a workflow execution .
def _get_workflow_tasks(self, exec_id, last_query_time=None):
        result = []
        try:
            query_filters = {}
            if last_query_time:
                query_filters['updated_at'] = 'gte:%s' % last_query_time
            wf_tasks = self._client.tasks.list(workflow_execution_id=exec_id, **query_filters)
            for wf_task in wf_tasks:
                result.append(self._client.tasks.get(wf_task.id))
                jitter = random.uniform(0, self._jitter)
                eventlet.sleep(jitter)
        except mistralclient_base.APIException as mistral_exc:
            if 'not found' in mistral_exc.message:
                raise exceptions.ReferenceNotFoundError(mistral_exc.message)
            raise mistral_exc
        return [self._format_task_result(task=entry.to_dict()) for entry in result]
def _get_workflow_tasks ( self , exec_id , last_query_time = None ) : result = [ ] try : query_filters = { } if last_query_time : query_filters [ 'updated_at' ] = 'gte:%s' % last_query_time wf_tasks = self . _client . tasks . list ( workflow_execution_id = exec_id , ** query_filters ) for wf_task in wf_tasks : result . append ( self . _client . tasks . get ( wf_task . id ) ) jitter = random . uniform ( 0 , self . _jitter ) eventlet . sleep ( jitter ) except mistralclient_base . APIException as mistral_exc : if 'not found' in mistral_exc . message : raise exceptions . ReferenceNotFoundError ( mistral_exc . message ) raise mistral_exc return [ self . _format_task_result ( task = entry . to_dict ( ) ) for entry in result ]
Returns the list of tasks for a workflow execution.
Returns the list of tasks for a workflow execution .
"""
        Returns the list of tasks for a workflow execution.
        :param exec_id: Mistral execution ID
        :type exec_id: ``str``
        :param last_query_time: Timestamp to filter tasks
        :type last_query_time: ``str``
        :rtype: ``list``
        """ # Lets not blast requests but just space it out for better CPU profile
None
``list``
self
exec_id
Mistral execution ID
Mistral execution ID
last_query_time
Timestamp to filter tasks
Timestamp to filter tasks