Skip to content

Refactor/ipa telco kpis prow migration test infrastructure refactoring#465

Merged
openshift-merge-bot[bot] merged 1 commit into
openshift-kni:mainfrom
ccardenosa:refactor/ipa-telco-kpis-prow-migration-test-infrastructure-refactoring
Jun 24, 2026
Merged

Refactor/ipa telco kpis prow migration test infrastructure refactoring#465
openshift-merge-bot[bot] merged 1 commit into
openshift-kni:mainfrom
ccardenosa:refactor/ipa-telco-kpis-prow-migration-test-infrastructure-refactoring

Conversation

@ccardenosa

Copy link
Copy Markdown
Collaborator

No description provided.

@openshift-ci openshift-ci Bot requested review from mkochanowski and shaior May 6, 2026 19:03
@openshift-ci openshift-ci Bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label May 13, 2026
@ccardenosa ccardenosa force-pushed the refactor/ipa-telco-kpis-prow-migration-test-infrastructure-refactoring branch from 47a6c77 to be22e63 Compare June 3, 2026 13:22
@openshift-ci openshift-ci Bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 3, 2026
@ccardenosa ccardenosa force-pushed the refactor/ipa-telco-kpis-prow-migration-test-infrastructure-refactoring branch 9 times, most recently from ee30d22 to 02fc5f3 Compare June 15, 2026 15:38
@ccardenosa ccardenosa force-pushed the refactor/ipa-telco-kpis-prow-migration-test-infrastructure-refactoring branch 6 times, most recently from e33fdb3 to 2775651 Compare June 24, 2026 08:51
Implement shared roles and modules to eliminate code duplication and standardize
Telco-KPIs test implementations.

**playbooks/telco-kpis/roles/artifact-management/**
- Eliminates duplicate artifact collection code across all tests
- Standardized artifact workflow: collect → generate JUnit XML → push to shared location → cleanup
- Tasks:
  - `collect-from-bastion.yml` - Fetch artifacts from remote bastion
  - `generate-junit-xml.yml` - Create JUnit XML from test results
  - `push-to-shared.yml` - Copy to shared artifact location
  - `cleanup-old-artifacts.yml` - Remove temporary artifacts
- Template: `junit-report.xml.j2` - Standardized JUnit XML format

**playbooks/telco-kpis/roles/telco-kpis-defaults/**
- Centralized default values for all telco-kpis tests
- Provides consistent defaults for:
  - Spirent configuration (chassis, stcweb, ports, test config)
  - Artifact directories
  - Test parameters
- Eliminates hardcoded values scattered across playbooks

**kubernetes.core Module Migration:**
- Replaced shell commands with kubernetes.core.k8s module for:
  - Pod deployment (dpdk-testpmd)
  - Resource querying
  - Pod deletion verification
- Benefits:
  - Idempotent operations
  - Better error handling
  - Structured return values
  - No shell parsing required

**Centralized Configuration:**
- Default Spirent settings in telco-kpis-defaults role
- Eliminates magic numbers and hardcoded IPs
- Single source of truth for test parameters

- **Code Reuse:** artifact-management role used across all tests
- **Consistency:** Standardized artifact naming and structure
- **Maintainability:** Changes to artifact workflow in one place
- **Reliability:** kubernetes.core modules more robust than shell commands
- **Configuration Management:** Centralized defaults easier to update

All telco-kpis tests (oslat, cyclictest, ptp, cpu_util, reboot, rfc2544, bios-validation,
rds-compare, ztp-timeline) benefit from these refactorings.

Related: Telco-KPIs test infrastructure
Signed-off-by: Carlos Cardenosa <ccardeno@redhat.com>
@ccardenosa ccardenosa force-pushed the refactor/ipa-telco-kpis-prow-migration-test-infrastructure-refactoring branch from 2775651 to e1856f0 Compare June 24, 2026 11:12
@eifrach

eifrach commented Jun 24, 2026

Copy link
Copy Markdown
Collaborator

/lgtm

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Jun 24, 2026
@ccardenosa

Copy link
Copy Markdown
Collaborator Author

/approve

@openshift-ci

openshift-ci Bot commented Jun 24, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ccardenosa

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

The pull request process is described 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

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 24, 2026
@openshift-merge-bot openshift-merge-bot Bot merged commit c961617 into openshift-kni:main Jun 24, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants