INNER CODE UNIT · Python

job_event

GACWR/OpenUBA · core/operator/main.py:216

def job_event(event, body, **kwargs):
    # Watch for completion of our jobs
    job_name = body['metadata']['name']

    # Determine type
    crd_type = None
    if job_name.startswith('inf-job-'):
        crd_type = "ubainferences"
        prefix_len = 8
    elif job_name.startswith('train-job-'):
        crd_type = "ubatrainings"
        prefix_len = 10
    else:
        return

    # Infer parent CRD name
    parent_crd_name = job_name[prefix_len:]

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…