Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(0)  |  Call(0)  |  Derive(0)  |  Import(0)

src/s/y/synnefo-HEAD/snf-cyclades-app/synnefo/logic/backend.py   synnefo(Download)
    if job_status not in rapi.JOB_STATUS_FINALIZED:
        return vm
    vm.backendlogmsg = logmsg
    if status not in rapi.JOB_STATUS_FINALIZED:
        vm.backendtime = etime
    if status in rapi.JOB_STATUS_FINALIZED:
        if nics is not None:
            update_vm_nics(vm, nics, etime)
            status = rapi.JOB_STATUS_SUCCESS
    if status in rapi.JOB_STATUS_FINALIZED:
        # Job is finalized: Handle quotas/commissioning
        vm = handle_vm_quotas(vm, job_id=jobid, job_opcode=opcode,
def update_snapshot(snap_id, user_id, job_id, job_status, etime):
    """Update a snapshot based on result of a Ganeti job."""
    if job_status in rapi.JOB_STATUS_FINALIZED:
        status = rapi.JOB_STATUS_SUCCESS and "AVAILABLE" or "ERROR"
        log.debug("Updating status of snapshot '%s' to '%s'", snap_id, status)

src/s/y/synnefo-HEAD/snf-cyclades-app/synnefo/logic/reconciliation.py   synnefo(Download)
            if gnt_job_status == rapi.JOB_STATUS_ERROR:
                return "ERROR", end_timestamp
            elif gnt_job_status not in rapi.JOB_STATUS_FINALIZED:
                return "RUNNING", None
            gnt_job_status = self.gnt_jobs[job_id]["status"]
            if gnt_job_status in rapi.JOB_STATUS_FINALIZED:
                pending_task = True

src/s/y/synnefo-HEAD/snf-cyclades-app/synnefo/logic/servers.py   synnefo(Download)
    # OP_INSTANCE_REMOVE supports the 'depends' request attribute.
    if (vm.backendopcode == "OP_INSTANCE_CREATE" and
       vm.backendjobstatus not in rapi.JOB_STATUS_FINALIZED and
       backend.job_is_still_running(vm) and
       not backend.vm_exists_in_backend(vm)):