'Process a job, get all successors of this job, and call _handle_successor() to handle each successor.
:param JobInfo job_info: The JobInfo instance
:return: None'

def _process_job_and_get_successors(self, job_info):

    job = job_info.job
    successors = self._get_successors(job)
    all_new_jobs = []
    for successor in successors:
        new_jobs = self._handle_successor(job, successor, successors)
        if new_jobs:
            all_new_jobs.extend(new_jobs)
            for new_job in new_jobs:
                self._insert_job(new_job)
    self._post_job_handling(job, all_new_jobs, successors)
