Skip to content

Add CPT dashboard metadata fields to ES documents#1239

Draft
arpsharm wants to merge 1 commit into
mainfrom
feature/cpt-dashboard-metadata
Draft

Add CPT dashboard metadata fields to ES documents#1239
arpsharm wants to merge 1 commit into
mainfrom
feature/cpt-dashboard-metadata

Conversation

@arpsharm

@arpsharm arpsharm commented Jun 14, 2026

Copy link
Copy Markdown
Member

Add CPT-compatible metadata fields to __get_metadata() and jobStatus mapping to update_ci_status() so benchmark-runner results can appear on the CPT dashboard alongside kube-burner workloads. Existing fields preserved for backward compatibility.

Summary by CodeRabbit

Release Notes

  • New Features
    • Benchmark metadata now captures cluster version, node counts, and platform information
    • Timestamps are consistently tracked in UTC format from start to completion
    • Job status is recorded in results for better tracking
    • Enhanced CI integration with additional environment variable capture

@openshift-ci

openshift-ci Bot commented Jun 14, 2026

Copy link
Copy Markdown

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@coderabbitai

coderabbitai Bot commented Jun 14, 2026

Copy link
Copy Markdown

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: a2eba9ff-985b-48af-ac50-a6384deb879d

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • ✅ Review completed - (🔄 Check again to review again)
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/cpt-dashboard-metadata

Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-ci

openshift-ci Bot commented Jun 14, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: arpsharm
Once this PR has been reviewed and has the lgtm label, please assign ebattat for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Add CPT-compatible fields (ocpVersion, releaseStream, ciSystem, platform,
benchmark, workerNodesCount, masterNodesCount, startDate, endDate, jobStatus)
to workload metadata so benchmark-runner results appear on the CPT dashboard
alongside kube-burner workloads.
@arpsharm arpsharm force-pushed the feature/cpt-dashboard-metadata branch from 56aab17 to 5ba8d99 Compare June 14, 2026 11:46

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
benchmark_runner/workloads/workloads_operations.py (1)

466-466: 💤 Low value

Consider extracting platform detection to a dedicated method for consistency.

Other cluster metadata (OCP version, CNV version, etc.) use dedicated methods in the OC class. This inline oc.run() call works but is inconsistent with the codebase pattern. A method like get_cluster_platform() would improve maintainability and allow reuse.

♻️ Suggested refactor

Add to benchmark_runner/common/oc/oc.py:

def get_cluster_platform(self):
    """
    This method returns the cluster platform (e.g., AWS, GCP, BareMetal).
    :return: platform string
    """
    return self.run(fr""" {self._cli} get infrastructure cluster -o jsonpath="{{.status.platform}}" """).strip()

Then in workloads_operations.py:

-                    'platform': self._oc.run("oc get infrastructure cluster -o jsonpath='{.status.platform}'").strip().strip("'"),
+                    'platform': self._oc.get_cluster_platform(),
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@benchmark_runner/workloads/workloads_operations.py` at line 466, The inline
oc.run() call in the workloads_operations.py file at line 466 is inconsistent
with the codebase pattern where other cluster metadata operations use dedicated
methods in the OC class. Add a new method called get_cluster_platform() to the
OC class in benchmark_runner/common/oc/oc.py that returns the cluster platform
by running the infrastructure cluster query and stripping whitespace, then
replace the inline oc.run() call in workloads_operations.py with a call to
self._oc.get_cluster_platform() for consistency and maintainability.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@benchmark_runner/workloads/workloads_operations.py`:
- Line 466: The inline oc.run() call in the workloads_operations.py file at line
466 is inconsistent with the codebase pattern where other cluster metadata
operations use dedicated methods in the OC class. Add a new method called
get_cluster_platform() to the OC class in benchmark_runner/common/oc/oc.py that
returns the cluster platform by running the infrastructure cluster query and
stripping whitespace, then replace the inline oc.run() call in
workloads_operations.py with a call to self._oc.get_cluster_platform() for
consistency and maintainability.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 91b5aaa1-20e2-4b7c-be32-d572a9cee5f8

📥 Commits

Reviewing files that changed from the base of the PR and between e762f4d and 5ba8d99.

📒 Files selected for processing (1)
  • benchmark_runner/workloads/workloads_operations.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant