Skip to content

NE-2750: implement feature test for GatewayAPIManagementMode - #31503

Open
rikatz wants to merge 2 commits into
openshift:mainfrom
rikatz:gateway-api-knob-tests
Open

NE-2750: implement feature test for GatewayAPIManagementMode#31503
rikatz wants to merge 2 commits into
openshift:mainfrom
rikatz:gateway-api-knob-tests

Conversation

@rikatz

@rikatz rikatz commented Aug 11, 2026

Copy link
Copy Markdown
Member

This change implements origin tests for Gateway API Management Mode feature.
They are intended to show the right working of this feature:

  • Setting managed/unmanaged/managed
  • Verifying that controllers properly stop, the VAP is properly removed or re-added
  • Verifying that upgrades work correctly

Summary by CodeRabbit

  • New Features

    • Added comprehensive validation for Gateway API management modes, including Managed and Unmanaged transitions.
    • Added checks for routing functionality, resource preservation, compliance detection, metrics, and controller state.
    • Added upgrade coverage to verify Gateway API behavior before and after platform upgrades.
  • Bug Fixes

    • Improved confidence that Gateway API resources and workloads continue functioning correctly during management-mode changes and upgrades.
  • Chores

    • Updated OpenShift API and client components to newer versions.

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: automatic mode

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Aug 11, 2026
@openshift-ci-robot

openshift-ci-robot commented Aug 11, 2026

Copy link
Copy Markdown

@rikatz: This pull request references NE-2750 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "5.0.0" version, but no target version was set.

Details

In response to this:

This change implements origin tests for Gateway API Management Mode feature.
They are intended to show the right working of this feature:

  • Setting managed/unmanaged/managed
  • Verifying that controllers properly stop, the VAP is properly removed or re-added
  • Verifying that upgrades work correctly

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Central YAML (inherited)

Review profile: CHILL

Plan: Pro Plus

Run ID: b5aa0240-5ef9-4200-b7a0-905a1e757d6d

📥 Commits

Reviewing files that changed from the base of the PR and between 1cac6c8 and bf75d20.

📒 Files selected for processing (2)
  • test/extended/router/gatewayapi_management_mode.go
  • test/extended/router/gatewayapi_management_mode_upgrade.go
🚧 Files skipped from review as they are similar to previous changes (2)
  • test/extended/router/gatewayapi_management_mode_upgrade.go
  • test/extended/router/gatewayapi_management_mode.go

Walkthrough

Adds end-to-end tests for Gateway API management modes, including transitions, compliance, takeover blocking, metrics, routing, and upgrade persistence. Registers the upgrade test and updates OpenShift API dependencies.

Changes

Gateway API management-mode testing

Layer / File(s) Summary
Management-mode suite setup and transitions
test/extended/router/gatewayapi_management_mode.go
Adds platform-gated tests for Managed and Unmanaged transitions, resource preservation, Istio state, workload routing, and platform-specific timeouts.
Compliance, takeover, and metrics validation
test/extended/router/gatewayapi_management_mode.go
Validates CRD compliance, takeover blocking, recovery, management metrics, status conditions, and resource state.
Upgrade test and resource persistence
test/extended/router/gatewayapi_management_mode_upgrade.go, test/e2e/upgrade/upgrade.go
Adds and registers an upgrade test that validates Gateway API resource persistence, functionality, two-way mode transitions, controller state, and cleanup.
OpenShift API module updates
go.mod
Updates the OpenShift API and client-go pseudo-versions.

Estimated code review effort: 4 (Complex) | ~60 minutes

Suggested reviewers: bentito, p0lyn0mial

Sequence Diagram(s)

sequenceDiagram
  participant UpgradeTest as GatewayAPIManagementModeUpgradeTest
  participant IngressResource
  participant GatewayAPIResources
  participant Istiod
  UpgradeTest->>IngressResource: Set management mode
  UpgradeTest->>GatewayAPIResources: Create GatewayClass, Gateway, and HTTPRoute
  GatewayAPIResources-->>UpgradeTest: Return resource status and connectivity state
  UpgradeTest->>IngressResource: Switch mode after upgrade
  IngressResource->>Istiod: Create or remove mode-specific state
  UpgradeTest->>GatewayAPIResources: Verify resource persistence and reconciliation
Loading

Caution

Pre-merge checks failed

Please resolve all errors before merging. Addressing warnings is optional.

  • Ignore

❌ Failed checks (1 error, 1 warning)

Check name Status Explanation Resolution
No-Sensitive-Data-In-Logs ❌ Error New tests pass cluster-derived hostnames to helpers that log the full hostname and load-balancer address, exposing internal infrastructure identifiers. Redact hostnames and load-balancer addresses in helper logs, or log only resource names and response status codes.
Test Structure And Quality ⚠️ Warning New suites contain many bare error assertions (for example lines 111, 231, and 583), ignore CRD cleanup-update errors at line 189, and can leak GatewayClass when Setup fails before line 113. Add diagnostic messages to every assertion, register cleanup immediately after each cluster mutation, check cleanup errors, and track GatewayClass creation separately in Teardown.
✅ Passed checks (13 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the implementation of feature tests for Gateway API management mode, which is the main change in the pull request.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Stable And Deterministic Test Names ✅ Passed All Describe and It titles, plus upgrade Name and DisplayName, are static; formatted values occur only in runtime g.By step labels.
Microshift Test Compatibility ✅ Passed All seven new Ginkgo tests inherit [apigroup:operator.openshift.io], and the upgrade test DisplayName has the same tag; MicroShift CI therefore skips these unavailable-API tests.
Single Node Openshift (Sno) Test Compatibility ✅ Passed The new tests use one backend replica and require only one ready Istiod pod; they do not count nodes, use affinity, drain nodes, test failover, or require multi-node endpoints.
Topology-Aware Scheduling Compatibility ✅ Passed The PR adds only E2E tests and API/client dependency data. Searches found no scheduling constraints; the existing one-replica backend helper is unchanged and has no placement rules.
Ote Binary Stdout Contract ✅ Passed New test files have no direct stdout writes; diagnostics use e2e.Logf/Ginkgo APIs, and the upgrade diff only registers the test. Existing klog use runs inside a Ginkgo test.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed Both new suites skip IPv6/dual-stack clusters via shouldSkipGatewayAPITests; hosts are generated cluster ingress domains, and no public endpoints or IPv4 literals occur in the new files.
No-Weak-Crypto ✅ Passed PR additions contain no weak-algorithm references or crypto imports; equality checks cover modes, statuses, metrics, and errors, not secrets or tokens.
Container-Privileges ✅ Passed The PR adds no privileged, hostPID, hostNetwork, hostIPC, SYS_ADMIN, root, or allowPrivilegeEscalation:true settings; its backend helper enforces non-root and drops ALL capabilities.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@openshift-ci

openshift-ci Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: rikatz
Once this PR has been reviewed and has the lgtm label, please assign miyadav 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

@openshift-ci

openshift-ci Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

@rikatz: This PR was included in a payload test run from openshift/cluster-ingress-operator#1547
trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • e2e-aws-ovn-serial

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/baf0cf60-958c-11f1-8ef9-db390a0f6457-0

@openshift-ci

openshift-ci Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

@rikatz: This PR was included in a payload test run from openshift/cluster-ingress-operator#1547
trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • e2e-gcp-ovn

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/d88faa50-958c-11f1-966f-44422d7a35b5-0

@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.

Actionable comments posted: 6

🧹 Nitpick comments (4)
test/extended/router/gatewayapi_management_mode.go (2)

224-224: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Use platformAwareTimeout for consistency.

Every other transition wait in this file wraps the timeout with platformAwareTimeout. This call hardcodes 5*time.Minute. On slow platforms the surrounding calls scale, but this one does not.

♻️ Proposed change
-		err = waitForManagementModeTransition(ctx, oc, operatorv1alpha1.GatewayAPIManagementModeManaged, 5*time.Minute)
+		err = waitForManagementModeTransition(ctx, oc, operatorv1alpha1.GatewayAPIManagementModeManaged, platformAwareTimeout(oc, 5*time.Minute))
🤖 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 `@test/extended/router/gatewayapi_management_mode.go` at line 224, Update the
waitForManagementModeTransition call for GatewayAPIManagementModeManaged to pass
platformAwareTimeout(5*time.Minute) instead of the hardcoded 5*time.Minute,
matching the other transition waits in the file.

839-841: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Use ptr.To for the boolean pointer.

k8s.io/utils/ptr provides ptr.To(true) and is already used by extended tests. This removes the single-use boolPtr helper.

🤖 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 `@test/extended/router/gatewayapi_management_mode.go` around lines 839 - 841,
Replace the single-use boolPtr helper with k8s.io/utils/ptr.To at its call
sites, using ptr.To for boolean pointers and removing boolPtr once unused.
test/extended/router/gatewayapi_management_mode_upgrade.go (2)

293-306: 🩺 Stability & Availability | 🔵 Trivial | ⚡ Quick win

Detach cleanup from the canceled test context.

Teardown receives ctx from the upgrade framework. If the spec context is canceled after a failure, every client call in Teardown fails immediately and the Gateway, HTTPRoute, and GatewayClass leak into the cluster. Detach cancellation and apply an explicit timeout.

♻️ Proposed change
 func (t *GatewayAPIManagementModeUpgradeTest) Teardown(ctx context.Context, f *e2e.Framework) {
 	if t.oc == nil || t.gatewayName == "" {
 		e2e.Logf("Skipping cleanup because setup did not initialize resources")
 		return
 	}
+
+	ctx, cancel := context.WithTimeout(context.WithoutCancel(ctx), 10*time.Minute)
+	defer cancel()

Based on learnings, in openshift/origin test helpers avoid context.Background() for deferred cleanup; detach cancellation with context.WithoutCancel(ctx) to preserve context values, then bound it with context.WithTimeout.

🤖 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 `@test/extended/router/gatewayapi_management_mode_upgrade.go` around lines 293
- 306, Update GatewayAPIManagementModeUpgradeTest.Teardown to derive a cleanup
context with context.WithoutCancel(ctx), then wrap it with an explicit timeout
and defer its cancellation. Use this bounded, cancellation-independent context
for setManagementMode and waitForManagementModeTransition so cleanup still runs
after the test context is canceled.

Source: Learnings


294-297: 🩺 Stability & Availability | 🔵 Trivial | ⚡ Quick win

Clean up the GatewayClass when Gateway creation does not complete.

The guard returns early when t.gatewayName is empty. Setup sets t.gatewayClassName at line 109 and creates the GatewayClass at line 111, before it sets t.gatewayName at line 124. If Setup fails between those points, the GatewayClass stays in the cluster. Gate each delete on its own recorded name.

♻️ Proposed change
-	if t.oc == nil || t.gatewayName == "" {
+	if t.oc == nil || (t.gatewayClassName == "" && t.gatewayName == "") {
 		e2e.Logf("Skipping cleanup because setup did not initialize resources")
 		return
 	}

Then guard the individual delete steps with if t.routeName != "", if t.gatewayName != "", and if t.gatewayClassName != "".

🤖 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 `@test/extended/router/gatewayapi_management_mode_upgrade.go` around lines 294
- 297, Update the cleanup method’s initial guard so it only skips when the test
client is unavailable, then gate each resource deletion independently using
t.routeName, t.gatewayName, and t.gatewayClassName. This must delete the
GatewayClass even when Gateway creation failed after its name was recorded,
while preserving skips for empty resource names.
🤖 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.

Inline comments:
In `@go.mod`:
- Around line 68-71: Run go mod tidy followed by go mod vendor to refresh
dependency metadata and vendored sources for the OpenShift modules in go.mod,
removing obsolete go.sum checksums for prior API and client-go versions while
retaining the versions that provide the required symbols.

In `@test/extended/router/gatewayapi_management_mode_upgrade.go`:
- Around line 120-125: Update the custom-domain setup near
getDefaultIngressClusterDomainName and the customDomain assignment to verify
that replacing "apps." actually changes defaultIngressDomain before using it;
fail the test clearly when the expected segment is absent, while preserving the
existing gateway hostname construction.
- Around line 89-106: Update Teardown to restore the recorded initial mode from
t.startMode rather than the post-upgrade current mode, preserving the original
cluster state. Keep Managed mode during any resource-deletion steps that require
it, then transition to t.startMode as the final cleanup action and wait for that
transition to complete.
- Around line 47-73: Update GatewayAPIManagementModeUpgradeTest.Skip so this
scenario is excluded from real upgrade runs on TechPreviewNoUpgrade clusters; do
not allow those clusters to proceed into Setup. Move the scenario to a
non-upgrade suite or gate it on a feature configuration that supports upgrades,
while preserving the existing skip checks for other environments.

In `@test/extended/router/gatewayapi_management_mode.go`:
- Around line 509-517: The VAP binding cleanup in the DeferCleanup callback must
clear metadata that cannot be reused on create, including UID and
CreationTimestamp alongside ResourceVersion. Handle Get errors other than
NotFound by reporting or failing cleanup instead of silently skipping
restoration, while preserving the existing recreation path when the binding is
absent.
- Around line 843-855: Update platformAwareTimeout to return baseTimeout when
infra.Status.PlatformStatus is nil before dereferencing it. Rename the
infrastructure and type variables to reflect their values, compare the platform
against configv1.PowerVSPlatformType instead of "IBMPowerVS", and remove
"IBMZPlatform" as a platform-type check; if IBM Z requires the multiplier,
determine it from node architecture instead.

---

Nitpick comments:
In `@test/extended/router/gatewayapi_management_mode_upgrade.go`:
- Around line 293-306: Update GatewayAPIManagementModeUpgradeTest.Teardown to
derive a cleanup context with context.WithoutCancel(ctx), then wrap it with an
explicit timeout and defer its cancellation. Use this bounded,
cancellation-independent context for setManagementMode and
waitForManagementModeTransition so cleanup still runs after the test context is
canceled.
- Around line 294-297: Update the cleanup method’s initial guard so it only
skips when the test client is unavailable, then gate each resource deletion
independently using t.routeName, t.gatewayName, and t.gatewayClassName. This
must delete the GatewayClass even when Gateway creation failed after its name
was recorded, while preserving skips for empty resource names.

In `@test/extended/router/gatewayapi_management_mode.go`:
- Line 224: Update the waitForManagementModeTransition call for
GatewayAPIManagementModeManaged to pass platformAwareTimeout(5*time.Minute)
instead of the hardcoded 5*time.Minute, matching the other transition waits in
the file.
- Around line 839-841: Replace the single-use boolPtr helper with
k8s.io/utils/ptr.To at its call sites, using ptr.To for boolean pointers and
removing boolPtr once unused.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Central YAML (inherited)

Review profile: CHILL

Plan: Pro Plus

Run ID: f8ee33e6-558f-4d06-a5bf-be02434d242e

📥 Commits

Reviewing files that changed from the base of the PR and between 3d4c218 and 1cac6c8.

⛔ Files ignored due to path filters (60)
  • go.sum is excluded by !**/*.sum
  • vendor/github.com/openshift/api/config/v1/types_authentication.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/config/v1/types_infrastructure.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/config/v1/types_ingress.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/config/v1/types_kmsencryption.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/config/v1/zz_generated.featuregated-crd-manifests.yaml is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/config/v1/zz_generated.swagger_doc_generated.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/config/v1alpha1/types_cluster_monitoring.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/config/v1alpha1/zz_generated.deepcopy.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/config/v1alpha1/zz_generated.model_name.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/config/v1alpha1/zz_generated.swagger_doc_generated.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/envtest-releases.yaml is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/features.md is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/features/features.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/features/legacyfeaturegates.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/machineconfiguration/v1/types.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/machineconfiguration/v1/zz_generated.featuregated-crd-manifests.yaml is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/machineconfiguration/v1/zz_generated.swagger_doc_generated.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/operator/v1/types.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/operator/v1/types_kmsencryption.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/operator/v1/zz_generated.deepcopy.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/operator/v1/zz_generated.model_name.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/operator/v1/zz_generated.swagger_doc_generated.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/operator/v1alpha1/register.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/operator/v1alpha1/types_ingress.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.deepcopy.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.featuregated-crd-manifests.yaml is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.model_name.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/operator/v1alpha1/zz_generated.swagger_doc_generated.go is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/api/route/v1/generated.proto is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/route/v1/types.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/api/route/v1/zz_generated.featuregated-crd-manifests.yaml is excluded by !**/vendor/**, !vendor/**, !**/zz_generated*
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/awsplatformstatus.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/baremetalplatformstatus.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/gcpplatformstatus.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vaultkmspluginconfig.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vsphereplatformfailuredomainspec.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1/vsphereplatformspec.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorconfig.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectordevicemappermultipathconfig.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectornvmexpresssubsystemconfig.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/nodeexportercollectorzoneinfoconfig.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/config/v1alpha1/remotewritespec.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/internal/internal.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/config/applyconfigurations/utils.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/machineconfiguration/applyconfigurations/machineconfiguration/v1/controllerconfigspec.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/applyconfigurations/internal/internal.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmsencryptionstatus.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspluginhealthreport.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspreflightcheck.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/kmspreflightresult.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1/nodestatus.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/gatewayapiingressconfig.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingress.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingressspec.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/applyconfigurations/operator/v1alpha1/ingressstatus.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/generated_expansion.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/ingress.go is excluded by !**/vendor/**, !vendor/**
  • vendor/github.com/openshift/client-go/operator/clientset/versioned/typed/operator/v1alpha1/operator_client.go is excluded by !**/vendor/**, !vendor/**
  • vendor/modules.txt is excluded by !**/vendor/**, !vendor/**
📒 Files selected for processing (4)
  • go.mod
  • test/e2e/upgrade/upgrade.go
  • test/extended/router/gatewayapi_management_mode.go
  • test/extended/router/gatewayapi_management_mode_upgrade.go

Comment thread go.mod
Comment on lines +68 to +71
github.com/openshift/api v0.0.0-20260810132456-8f52beb625b5
github.com/openshift/apiserver-library-go v0.0.0-20260715200723-42e5e402ca43
github.com/openshift/build-machinery-go v0.0.0-20250530140348-dc5b2804eeee
github.com/openshift/client-go v0.0.0-20260715172546-dac61734e0ec
github.com/openshift/client-go v0.0.0-20260810202730-ddca5e0b7146

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify vendored openshift/api and client-go expose the management-mode API surface.
set -uo pipefail

grep -nE 'github.com/openshift/(api|client-go) ' go.mod
grep -nE '^# github.com/openshift/(api|client-go) ' vendor/modules.txt || echo "vendor/modules.txt entries missing"
grep -nE 'github.com/openshift/(api|client-go) ' go.sum | head -20

fd -t d 'v1alpha1' vendor/github.com/openshift/api/operator | head
rg -n 'GatewayAPIManagementMode(Managed|Unmanaged)?\b' vendor/github.com/openshift/api/operator -g '*.go' | head -20
rg -n 'func .*OperatorV1alpha1\(\)|Ingresses\(\)' vendor/github.com/openshift/client-go/operator -g '*.go' | head -20

Repository: openshift/origin

Length of output: 3019


🏁 Script executed:

#!/bin/bash
set -euo pipefail

python3 - <<'PY'
from pathlib import Path
import re

go_mod = Path("go.mod").read_text()
modules = Path("vendor/modules.txt").read_text()
go_sum = Path("go.sum").read_text()

names = ["github.com/openshift/api", "github.com/openshift/client-go"]
for name in names:
    mod_match = re.search(rf"(?m)^\s*{re.escape(name)}\s+(\S+)", go_mod)
    vendor_match = re.search(rf"(?m)^# {re.escape(name)}\s+(\S+)", modules)
    sum_versions = sorted(set(re.findall(rf"^{re.escape(name)}\s+(\S+)(?:/go\.mod)?\s+", go_sum, re.M)))
    print(name)
    print("  go.mod:", mod_match.group(1) if mod_match else "MISSING")
    print("  vendor/modules.txt:", vendor_match.group(1) if vendor_match else "MISSING")
    print("  go.sum versions:", ", ".join(sum_versions) if sum_versions else "MISSING")
    if not mod_match or not vendor_match or mod_match.group(1) != vendor_match.group(1):
        print("  VERSION_MISMATCH")

print("\nExact client call-chain references:")
for path in Path(".").rglob("*.go"):
    if any(part in {"vendor", ".git"} for part in path.parts):
        continue
    text = path.read_text(errors="replace")
    for i, line in enumerate(text.splitlines(), 1):
        if "AdminOperatorClient().OperatorV1alpha1().Ingresses()" in line:
            print(f"{path}:{i}:{line.strip()}")
PY

printf '\nGo module vendor diagnostics:\n'
go version
go mod vendor -h 2>&1 | sed -n '1,80p'

printf '\nSelected vendored module metadata:\n'
go list -mod=vendor -m github.com/openshift/api github.com/openshift/client-go

Repository: openshift/origin

Length of output: 1331


🏁 Script executed:

#!/bin/bash
set -u

printf '%s\n' 'Read-only go.mod/go.sum tidy diff:'
go mod tidy -diff 2>&1
tidy_status=$?
printf 'go mod tidy -diff exit status: %s\n' "$tidy_status"

printf '\nVendor-mode module query:\n'
go list -mod=vendor -m all 2>&1 | rg 'github.com/openshift/(api|client-go)|go:|cannot|error' | head -40
printf 'go list exit status: %s\n' "${PIPESTATUS[0]}"

Repository: openshift/origin

Length of output: 9410


Run go mod tidy && go mod vendor. go.sum contains four obsolete checksums for the previous OpenShift API and client-go versions. The vendored packages provide the requested API symbols.

🤖 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 `@go.mod` around lines 68 - 71, Run go mod tidy followed by go mod vendor to
refresh dependency metadata and vendored sources for the OpenShift modules in
go.mod, removing obsolete go.sum checksums for prior API and client-go versions
while retaining the versions that provide the required symbols.

Source: Coding guidelines

Comment on lines +47 to +73
func (t *GatewayAPIManagementModeUpgradeTest) Skip(_ upgrades.UpgradeContext) bool {
oc := exutil.NewCLIForMonitorTest("gateway-api-mgmt-mode-upgrade-skip").AsAdmin()

// Check if feature gate is enabled
if !exutil.IsTechPreviewNoUpgrade(context.Background(), oc.AdminConfigClient()) {
e2e.Logf("Skipping: GatewayAPIManagementMode feature is not in TechPreviewNoUpgrade")
return true
}

noOLM, err := isNoOLMFeatureGateEnabled(oc)
if err != nil {
e2e.Logf("Failed to check GatewayAPIWithoutOLM feature gate: %v", err)
return true
}

skip, reason, err := shouldSkipGatewayAPITests(oc, noOLM)
if err != nil {
e2e.Logf("Failed to check Gateway API skip conditions: %v", err)
return true
}
if skip {
e2e.Logf("Skipping test: %s", reason)
return true
}

return false
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🩺 Stability & Availability | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Description: Inspect the TechPreviewNoUpgrade helper and look for other upgrade tests that gate on it.
rg -nP -C 8 'func IsTechPreviewNoUpgrade\b' test/extended/util

# Find upgrade tests (Skip(upgrades.UpgradeContext)) that also check TechPreviewNoUpgrade.
rg -nP -C 5 'IsTechPreviewNoUpgrade' --type=go -g '!vendor/**'

Repository: openshift/origin

Length of output: 2763


🏁 Script executed:

#!/bin/bash
set -e
printf '%s\n' '--- TechPreviewNoUpgrade helper ---'
sed -n '190,225p' test/extended/util/compat_otp/clusters.go
printf '%s\n' '--- config-client TechPreviewNoUpgrade helper ---'
sed -n '2188,2225p' test/extended/util/framework.go
printf '%s\n' '--- upgrade test interface and runner ---'
rg -n -C 8 'type Test interface|func .*Skip\(|Skip\(.*UpgradeContext|Test\(\s*ctx|UpgradeContext' test/e2e test/extended --type=go -g '!vendor/**' | head -n 240
printf '%s\n' '--- relevant test lines ---'
sed -n '135,175p' test/extended/router/gatewayapi_management_mode_upgrade.go
printf '%s\n' '--- all TechPreviewNoUpgrade references outside helper definitions ---'
rg -n -C 6 'IsTechPreviewNoUpgrade' --type=go -g '!vendor/**'

Repository: openshift/origin

Length of output: 21941


🏁 Script executed:

#!/bin/bash
set -e
printf '%s\n' '--- upgrade test contract and skip invocation ---'
rg -n -C 12 'type UpgradeTest|Skip\(.*UpgradeContext|\.Skip\(|checkUpgradeability|IsNoUpgradeFeatureSet|TechPreviewNoUpgrade|CustomNoUpgrade' test/e2e/upgrade test/extended/router --type=go
printf '%s\n' '--- upgradeability implementation ---'
sed -n '230,330p' test/e2e/upgrade/upgrade.go
printf '%s\n' '--- complete imports and Skip implementation ---'
sed -n '1,90p' test/extended/router/gatewayapi_management_mode_upgrade.go
printf '%s\n' '--- all source references, including non-Go files ---'
rg -n -C 4 'IsTechPreviewNoUpgrade|TechPreviewNoUpgrade|IsNoUpgradeFeatureSet' . -g '!vendor/**' -g '!node_modules/**'

Repository: openshift/origin

Length of output: 50373


🏁 Script executed:

#!/bin/bash
set -e
printf '%s\n' '--- management-mode upgrade test ---'
sed -n '1,210p' test/extended/router/gatewayapi_management_mode_upgrade.go
printf '%s\n' '--- upgrade test registration ---'
rg -n -C 8 'GatewayAPIManagementModeUpgradeTest|gateway-api-mgmt-mode-upgrade' test/e2e/upgrade/upgrade.go test/extended/router/gatewayapi_management_mode_upgrade.go
printf '%s\n' '--- upgrade framework interface and skip path ---'
rg -n -C 8 'type Test interface|func .*Run|Skip\(.*UpgradeContext|test\.Skip|Setup\(ctx|Teardown\(ctx' vendor test 2>/dev/null | rg 'upgrades|UpgradeContext|Skip\(.*UpgradeContext|test/e2e/upgrade' | head -n 160
printf '%s\n' '--- feature-set upgrade restrictions ---'
rg -n -C 8 'TechPreviewNoUpgrade|CustomNoUpgrade|non-upgradeable|not.*upgrade|upgrade.*feature.?set' . -g '*.go' -g '*.md' -g '*.yaml' -g '*.yml' -g '!vendor/**' | head -n 240

Repository: openshift/origin

Length of output: 50372


🏁 Script executed:

#!/bin/bash
set -e
printf '%s\n' '--- complete upgradeability check ---'
sed -n '234,273p' test/e2e/upgrade/upgrade.go
printf '%s\n' '--- disruption skip and execution order ---'
sed -n '165,235p' test/extended/util/disruption/disruption.go
printf '%s\n' '--- upgrade feature-set references in vendored APIs and repository code ---'
rg -n -C 5 'TechPreviewNoUpgrade|ClusterNotUpgradeable|Upgradeable.*false|not upgradeable|not upgrade' vendor/k8s.io vendor/github.com/openshift . -g '*.go' -g '*.md' 2>/dev/null | head -n 260

Repository: openshift/origin

Length of output: 27021


🏁 Script executed:

#!/bin/bash
set -e
printf '%s\n' '--- CI jobs that combine upgrade tests and feature sets ---'
rg -n -C 5 'FEATURE_SET|TechPreviewNoUpgrade|techpreview|upgrade' ci-operator test -g '*.yaml' -g '*.yml' -g '*.json' -g '*.go' -g '*.md' 2>/dev/null | rg -C 3 'FEATURE_SET|TechPreviewNoUpgrade|techpreview|upgrade' | head -n 300
printf '%s\n' '--- upgrade suite documentation and job references ---'
rg -n -C 5 'Suite:upgrade|cluster-upgrade|openshift-tests.*upgrade|upgrade.*suite|upgrade.*job' . -g '*.md' -g '*.yaml' -g '*.yml' -g '*.json' -g '*.go' -g '!vendor/**' | head -n 240

Repository: openshift/origin

Length of output: 40588


Do not run this test in the real upgrade suite on TechPreviewNoUpgrade clusters. TechPreviewNoUpgrade sets the cluster as non-upgradeable, so the upgrade cannot complete. Upgradeable clusters skip this test, while TechPreviewNoUpgrade clusters enter Setup and can block at <-done. Move this scenario to a non-upgrade test suite or use a feature configuration supported during upgrades.

🤖 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 `@test/extended/router/gatewayapi_management_mode_upgrade.go` around lines 47 -
73, Update GatewayAPIManagementModeUpgradeTest.Skip so this scenario is excluded
from real upgrade runs on TechPreviewNoUpgrade clusters; do not allow those
clusters to proceed into Setup. Move the scenario to a non-upgrade suite or gate
it on a feature configuration that supports upgrades, while preserving the
existing skip checks for other environments.

Comment on lines +89 to +106
g.By("Recording initial management mode before upgrade")
ingress, err := getIngressCR(ctx, t.oc)
o.Expect(err).NotTo(o.HaveOccurred())

t.startMode = ingress.Spec.GatewayAPI.ManagementMode
if t.startMode == "" {
t.startMode = operatorv1alpha1.GatewayAPIManagementModeManaged
}
e2e.Logf("Starting with management mode: %s", t.startMode)

// Ensure we're in Managed mode for test setup
if t.startMode != operatorv1alpha1.GatewayAPIManagementModeManaged {
g.By("Transitioning to Managed mode for setup")
err = setManagementMode(ctx, t.oc, operatorv1alpha1.GatewayAPIManagementModeManaged)
o.Expect(err).NotTo(o.HaveOccurred())
err = waitForManagementModeTransition(ctx, t.oc, operatorv1alpha1.GatewayAPIManagementModeManaged, 5*time.Minute)
o.Expect(err).NotTo(o.HaveOccurred())
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win

Restore the recorded start mode instead of forcing Managed.

Setup records t.startMode, but no later code reads it. Test restores currentMode (the post-upgrade mode), and Teardown always sets Managed. If the cluster began in Unmanaged mode, the test leaves the cluster in Managed mode after cleanup. This changes cluster state for subsequent tests in the same run.

Use t.startMode as the final target in Teardown.

♻️ Proposed change in Teardown
-	g.By("Ensuring Managed mode for cleanup")
-	err := setManagementMode(ctx, t.oc, operatorv1alpha1.GatewayAPIManagementModeManaged)
+	g.By("Restoring the original management mode for cleanup")
+	restoreMode := t.startMode
+	if restoreMode == "" {
+		restoreMode = operatorv1alpha1.GatewayAPIManagementModeManaged
+	}
+	err := setManagementMode(ctx, t.oc, restoreMode)
 	if err != nil {
-		e2e.Logf("Failed to set Managed mode during cleanup: %v", err)
+		e2e.Logf("Failed to restore management mode %s during cleanup: %v", restoreMode, err)
 	} else {
-		_ = waitForManagementModeTransition(ctx, t.oc, operatorv1alpha1.GatewayAPIManagementModeManaged, 5*time.Minute)
+		if waitErr := waitForManagementModeTransition(ctx, t.oc, restoreMode, 5*time.Minute); waitErr != nil {
+			e2e.Logf("Management mode did not settle on %s during cleanup: %v", restoreMode, waitErr)
+		}
 	}

Note: deleting resources requires Managed mode in some flows. If that is the case, keep Managed for the delete steps and restore t.startMode at the end of Teardown.

Also applies to: 216-226

🤖 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 `@test/extended/router/gatewayapi_management_mode_upgrade.go` around lines 89 -
106, Update Teardown to restore the recorded initial mode from t.startMode
rather than the post-upgrade current mode, preserving the original cluster
state. Keep Managed mode during any resource-deletion steps that require it,
then transition to t.startMode as the final cleanup action and wait for that
transition to complete.

Comment on lines +120 to +125
defaultIngressDomain, err := getDefaultIngressClusterDomainName(t.oc, 1*time.Minute)
o.Expect(err).NotTo(o.HaveOccurred())
customDomain := strings.Replace(defaultIngressDomain, "apps.", "gw-upgrade-mgmt.", 1)

t.gatewayName = "upgrade-mgmt-mode-gateway"
t.hostname = "test-upgrade-mgmt." + customDomain

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Confirm the custom domain replacement always applies.

strings.Replace(defaultIngressDomain, "apps.", "gw-upgrade-mgmt.", 1) is a no-op when the default ingress domain does not contain the literal apps.. In that case customDomain equals the default ingress domain, and the Gateway listener claims the same wildcard domain that the default IngressController serves. That can produce confusing routing failures instead of a clear test error.

Assert that the replacement changed the value, or derive the custom domain by prefixing the cluster base domain.

🤖 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 `@test/extended/router/gatewayapi_management_mode_upgrade.go` around lines 120
- 125, Update the custom-domain setup near getDefaultIngressClusterDomainName
and the customDomain assignment to verify that replacing "apps." actually
changes defaultIngressDomain before using it; fail the test clearly when the
expected segment is absent, while preserving the existing gateway hostname
construction.

Comment on lines +509 to +517
g.DeferCleanup(func(ctx context.Context) {
e2e.Logf("Cleanup: Restoring VAP binding")
// VAP binding should be recreated by CIO, but restore just in case
_, err := oc.AdminKubeClient().AdmissionregistrationV1().ValidatingAdmissionPolicyBindings().Get(ctx, gwapiCRDVAPName, metav1.GetOptions{})
if apierrors.IsNotFound(err) {
vapBinding.ResourceVersion = ""
_, _ = oc.AdminKubeClient().AdmissionregistrationV1().ValidatingAdmissionPolicyBindings().Create(ctx, vapBinding, metav1.CreateOptions{})
}
})

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win

Clear UID before recreating the ValidatingAdmissionPolicyBinding, and handle non-NotFound errors.

The cleanup reuses the object returned by Get. It clears ResourceVersion but keeps UID and CreationTimestamp, which the API server rejects on create for a set UID. The cleanup also skips restoration when Get returns an error other than NotFound, which hides a real failure.

🛠️ Proposed change
 		g.DeferCleanup(func(ctx context.Context) {
 			e2e.Logf("Cleanup: Restoring VAP binding")
 			// The CIO normally recreates the binding; recreate it only if it is still absent.
 			_, err := oc.AdminKubeClient().AdmissionregistrationV1().ValidatingAdmissionPolicyBindings().Get(ctx, gwapiCRDVAPName, metav1.GetOptions{})
 			if apierrors.IsNotFound(err) {
-				vapBinding.ResourceVersion = ""
-				_, _ = oc.AdminKubeClient().AdmissionregistrationV1().ValidatingAdmissionPolicyBindings().Create(ctx, vapBinding, metav1.CreateOptions{})
+				restored := vapBinding.DeepCopy()
+				restored.ResourceVersion = ""
+				restored.UID = ""
+				restored.CreationTimestamp = metav1.Time{}
+				restored.Generation = 0
+				if _, createErr := oc.AdminKubeClient().AdmissionregistrationV1().ValidatingAdmissionPolicyBindings().Create(ctx, restored, metav1.CreateOptions{}); createErr != nil {
+					e2e.Logf("Cleanup: failed to recreate VAP binding %s: %v", gwapiCRDVAPName, createErr)
+				}
+			} else if err != nil {
+				e2e.Logf("Cleanup: failed to check VAP binding %s: %v", gwapiCRDVAPName, err)
 			}
 		})
🤖 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 `@test/extended/router/gatewayapi_management_mode.go` around lines 509 - 517,
The VAP binding cleanup in the DeferCleanup callback must clear metadata that
cannot be reused on create, including UID and CreationTimestamp alongside
ResourceVersion. Handle Get errors other than NotFound by reporting or failing
cleanup instead of silently skipping restoration, while preserving the existing
recreation path when the binding is absent.

Comment on lines +843 to +855
// platformAwareTimeout adjusts timeout for slow architectures
func platformAwareTimeout(oc *exutil.CLI, baseTimeout time.Duration) time.Duration {
platform, err := oc.AdminConfigClient().ConfigV1().Infrastructures().Get(context.Background(), "cluster", metav1.GetOptions{})
if err != nil {
return baseTimeout
}

arch := platform.Status.PlatformStatus.Type
if arch == "IBMPowerVS" || arch == "IBMZPlatform" {
return baseTimeout * 2
}
return baseTimeout
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Confirm the configv1 PlatformType constant values and that PlatformStatus is a pointer.
set -uo pipefail

rg -nP 'PlatformType\s+PlatformType\s*=\s*"' vendor/github.com/openshift/api/config/v1 --type=go
rg -nP 'PlatformStatus\s+\*?PlatformStatus' vendor/github.com/openshift/api/config/v1 --type=go
rg -n 'IBMZ|s390x' vendor/github.com/openshift/api/config/v1 --type=go | head

Repository: openshift/origin

Length of output: 2149


🏁 Script executed:

#!/bin/bash
set -euo pipefail

file="test/extended/router/gatewayapi_management_mode.go"
printf '%s\n' '--- target helper and imports ---'
sed -n '1,80p' "$file"
sed -n '820,865p' "$file"

printf '%s\n' '--- helper call sites ---'
rg -n -C 3 'platformAwareTimeout' "$file" test/extended/router

printf '%s\n' '--- related platform handling ---'
rg -n -C 5 'getPlatformCapabilities|PlatformStatus|PowerVSPlatformType|IBMZPlatform|IBMPowerVS|s390x' test/extended/router vendor/github.com/openshift/api/config/v1 --glob '*.go'

Repository: openshift/origin

Length of output: 50373


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- infrastructure type definitions ---'
sed -n '70,115p' vendor/github.com/openshift/api/config/v1/types_infrastructure.go
sed -n '225,285p' vendor/github.com/openshift/api/config/v1/types_infrastructure.go

printf '%s\n' '--- architecture detection and related timeout logic ---'
rg -n -C 4 'runtime\.GOARCH|NodeArchitecture|Architecture|s390x|ppc64le|PowerVS|IBM Z|IBMZ|timeout.*2|2.*timeout' test/extended vendor/github.com/openshift/api --glob '*.go' | head -240

printf '%s\n' '--- concise platform references ---'
rg -n 'IBMPowerVS|IBMZPlatform|PowerVSPlatformType|s390x|ppc64le' --glob '*.go' --glob '*.yaml' --glob '*.md' . | head -200

Repository: openshift/origin

Length of output: 50372


Guard PlatformStatus and use valid platform or architecture values

Return baseTimeout when infra.Status.PlatformStatus is nil before dereferencing it. Use configv1.PowerVSPlatformType, whose value is "PowerVS"; "IBMPowerVS" does not match a valid platform type. "IBMZPlatform" is not a platform type. If IBM Z needs a longer timeout, read the node architecture instead. Rename platform and arch to match the values they hold.

🤖 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 `@test/extended/router/gatewayapi_management_mode.go` around lines 843 - 855,
Update platformAwareTimeout to return baseTimeout when
infra.Status.PlatformStatus is nil before dereferencing it. Rename the
infrastructure and type variables to reflect their values, compare the platform
against configv1.PowerVSPlatformType instead of "IBMPowerVS", and remove
"IBMZPlatform" as a platform-type check; if IBM Z requires the multiplier,
determine it from node architecture instead.


g.BeforeEach(func(ctx context.Context) {
// Check if feature gate is enabled
if !exutil.IsTechPreviewNoUpgrade(ctx, oc.AdminConfigClient()) {

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

claude goofed on this, I will fix this soon

@rikatz
rikatz force-pushed the gateway-api-knob-tests branch from 1cac6c8 to bf75d20 Compare August 11, 2026 18:09
@openshift-ci

openshift-ci Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

@rikatz: This PR was included in a payload test run from openshift/cluster-ingress-operator#1547
trigger 0 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

@rikatz

rikatz commented Aug 11, 2026

Copy link
Copy Markdown
Member Author

/test help

@openshift-ci

openshift-ci Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

@rikatz: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

/test agentic-images
/test e2e-aws-csi
/test e2e-aws-jenkins
/test e2e-aws-ovn-fips
/test e2e-aws-ovn-image-registry
/test e2e-aws-ovn-microshift
/test e2e-aws-ovn-microshift-serial
/test e2e-aws-ovn-serial-1of2
/test e2e-aws-ovn-serial-2of2
/test e2e-gcp-csi
/test e2e-gcp-ovn
/test e2e-gcp-ovn-builds
/test e2e-gcp-ovn-image-ecosystem
/test e2e-gcp-ovn-upgrade
/test e2e-metal-ipi-ovn-ipv6
/test e2e-vsphere-ovn
/test e2e-vsphere-ovn-upi
/test go-verify-deps
/test images
/test lint
/test okd-scos-images
/test unit
/test verify
/test verify-deps
/test verify-image-manifest-lists

The following commands are available to trigger optional jobs:

/test e2e-agent-compact-ipv4-iso-no-registry
/test e2e-agnostic-ovn-cmd
/test e2e-aws-disruptive
/test e2e-aws-etcd-certrotation
/test e2e-aws-etcd-recovery
/test e2e-aws-ovn
/test e2e-aws-ovn-cgroupsv2
/test e2e-aws-ovn-dra-example
/test e2e-aws-ovn-edge-zones
/test e2e-aws-ovn-etcd-scaling
/test e2e-aws-ovn-kube-apiserver-rollout
/test e2e-aws-ovn-kubevirt
/test e2e-aws-ovn-serial-fast
/test e2e-aws-ovn-serial-ipsec
/test e2e-aws-ovn-serial-publicnet-1of2
/test e2e-aws-ovn-serial-publicnet-2of2
/test e2e-aws-ovn-single-node
/test e2e-aws-ovn-single-node-serial
/test e2e-aws-ovn-single-node-techpreview
/test e2e-aws-ovn-single-node-techpreview-serial
/test e2e-aws-ovn-single-node-upgrade
/test e2e-aws-ovn-upgrade
/test e2e-aws-ovn-upgrade-rollback
/test e2e-aws-ovn-upi
/test e2e-aws-proxy
/test e2e-aws-tls-observed-config
/test e2e-aws-tls-observed-config-fips
/test e2e-aws-tls-observed-config-hypershift
/test e2e-azure
/test e2e-azure-ovn-etcd-scaling
/test e2e-azure-ovn-upgrade
/test e2e-baremetalds-kubevirt
/test e2e-external-aws
/test e2e-external-aws-ccm
/test e2e-external-vsphere-ccm
/test e2e-gcp-disruptive
/test e2e-gcp-fips-serial-1of2
/test e2e-gcp-fips-serial-2of2
/test e2e-gcp-ovn-etcd-scaling
/test e2e-gcp-ovn-kube-apiserver-rollout
/test e2e-gcp-ovn-rt-upgrade
/test e2e-gcp-ovn-techpreview
/test e2e-gcp-ovn-techpreview-pkiconfig
/test e2e-gcp-ovn-techpreview-serial-1of2
/test e2e-gcp-ovn-techpreview-serial-2of2
/test e2e-gcp-ovn-usernamespace
/test e2e-hypershift-conformance
/test e2e-metal-ipi-ovn
/test e2e-metal-ipi-ovn-bgp-virt-dualstack
/test e2e-metal-ipi-ovn-bgp-virt-dualstack-techpreview
/test e2e-metal-ipi-ovn-dualstack
/test e2e-metal-ipi-ovn-dualstack-bgp
/test e2e-metal-ipi-ovn-dualstack-bgp-local-gw
/test e2e-metal-ipi-ovn-dualstack-local-gateway
/test e2e-metal-ipi-ovn-kube-apiserver-rollout
/test e2e-metal-ipi-serial-1of2
/test e2e-metal-ipi-serial-2of2
/test e2e-metal-ipi-serial-ovn-ipv6-1of2
/test e2e-metal-ipi-serial-ovn-ipv6-2of2
/test e2e-metal-ipi-virtualmedia
/test e2e-metal-ovn-single-node-live-iso
/test e2e-metal-ovn-single-node-with-worker-live-iso
/test e2e-metal-ovn-two-node-arbiter
/test e2e-metal-ovn-two-node-fencing
/test e2e-metal-ovn-two-node-fencing-recovery
/test e2e-openstack-dualstack-v6primary
/test e2e-openstack-ovn
/test e2e-openstack-serial
/test e2e-vsphere-ovn-etcd-scaling
/test okd-scos-e2e-aws-ovn

Use /test all to run the following jobs that were automatically triggered:

pull-ci-openshift-origin-main-agentic-images
pull-ci-openshift-origin-main-go-verify-deps
pull-ci-openshift-origin-main-images
pull-ci-openshift-origin-main-lint
pull-ci-openshift-origin-main-okd-scos-images
pull-ci-openshift-origin-main-unit
pull-ci-openshift-origin-main-verify
pull-ci-openshift-origin-main-verify-deps
Details

In response to this:

/test help

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@openshift-ci

openshift-ci Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

@rikatz: This PR was included in a payload test run from openshift/cluster-ingress-operator#1547
trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • e2e-gcp-ovn-techpreview-serial

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/983aa1e0-95b3-11f1-8279-e88e2a3dac51-0

@openshift-ci

openshift-ci Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

@rikatz: This PR was included in a payload test run from openshift/cluster-ingress-operator#1547
trigger 0 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

@openshift-ci

openshift-ci Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

@rikatz: This PR was included in a payload test run from openshift/cluster-ingress-operator#1547
trigger 3 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-release-main-ci-5.0-e2e-aws-ovn-techpreview-serial-1of3
  • periodic-ci-openshift-release-main-ci-5.0-e2e-aws-ovn-techpreview-serial-2of3
  • periodic-ci-openshift-release-main-ci-5.0-e2e-aws-ovn-techpreview-serial-3of3

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/ec5620d0-95b6-11f1-8eee-421ddecb8633-0

@openshift-ci

openshift-ci Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

@rikatz: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/go-verify-deps bf75d20 link true /test go-verify-deps
ci/prow/verify-deps bf75d20 link true /test verify-deps

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

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

Labels

jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. vendor-update Touching vendor dir or related files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants