Uploaded image for project: 'OpenShift Virtualization'
  1. OpenShift Virtualization
  2. CNV-78434

Replace infraUtils.new*Param context usage with structured job context

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • None
    • CNV QE DevOps
    • None

      Goal

      Remove reliance on infraUtils.new*Param (e.g., CLUSTER_ID) and build a structured job execution context.

      Motivation

      Current pipelines set ad-hoc env/params via infraUtils.new*Param, which is brittle, obscures data flow, and it is a perfect example of the Spaghetti code. We want a single, explicit context model for job execution metadata.

      Proposed direction

      • Define a Job Execution Context based on JOB_METADATA (jobdsl metadata), then enrich with cluster info when CLUSTER params are present.
      • Provide a clear interface to read/add/update context fields.
      • Evaluate existing Jenkins plugins for structured build metadata/context (if suitable, adopt).
      • If no plugin, persist context as JSON in workspace and archive as artifact.

      Scope (initial)

      • Inventory infraUtils.new*Param usage across pipelines.
      • Propose a shared library API for context handling.
      • Migrate a pilot job (upgrade pipelines) to use the new context.

      Acceptance criteria

      • No infraUtils.new*Param usage in pilot jobs.
      • Context is available to steps and archived for traceability.
      • Documentation added with usage examples.

      Additional scope

      • Consolidate build-info.json and run-info.json, and deprecate them in favor of the new job-execution-context management.
      • Adjust DevopAPI GW to work with the new format.
        1. Additional scope
      • Consolidate build-info.json and run-info.json, and deprecate them in favor of the new job-execution-context management.

              dkeler@redhat.com Daniel Keler
              lbednar@redhat.com Lukas Bednar
              Daniel Keler Daniel Keler
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: