Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
base_images:
test-oadp-operator:
name: oadp-operator-e2e-tests
namespace: konveyor
tag: oadp-1.6
build_root:
image_stream_tag:
name: builder
Expand All @@ -13,13 +18,82 @@ promotion:
to:
- name: kubevirt-datamover-controller
namespace: konveyor
releases:
latest:
candidate:
product: ocp
stream: nightly
version: "5.0"
resources:
'*':
limits:
memory: 4Gi
requests:
cpu: 100m
memory: 200Mi
tests:
- always_run: false
as: e2e-test-aws
run_if_changed: .+\.go|go\.(\bmod\b|\bsum\b)|Makefile|Dockerfile|.dockerignore|.*\.ya{0,1}ml|.sh
steps:
cluster_profile: openshift-org-aws
env:
OO_BUNDLE: registry.ci.openshift.org/konveyor/oadp-operator-bundle:oadp-1.6
OO_INSTALL_MODE: OwnNamespace
OO_INSTALL_NAMESPACE: openshift-adp
post:
- chain: ipi-aws-post
pre:
- chain: ipi-aws-pre
- ref: optional-operators-operator-sdk-non-ci-bundle-image
test:
- as: set-related-image
cli: latest
commands: |
SUB=$(oc get subscription -n "${OO_INSTALL_NAMESPACE}" -o jsonpath='{.items[0].metadata.name}')
if [ -z "${SUB}" ]; then
echo "No Subscription found in namespace ${OO_INSTALL_NAMESPACE}" >&2
exit 1
fi
echo "Discovered Subscription: ${SUB}"
# Subscription.spec.config.env is OLM's supported override mechanism:
# it wins over same-named CSV env vars and survives reconciliation,
# unlike patching the Deployment directly (OLM reconciles that from
# the CSV and would revert it).
oc patch subscription "${SUB}" -n "${OO_INSTALL_NAMESPACE}" --type merge -p "$(jq -n --arg img "${KDM_CONTROLLER_IMAGE}" '{spec:{config:{env:[{name:"RELATED_IMAGE_KUBEVIRT_DATAMOVER_CONTROLLER",value:$img}]}}}')"
echo "Waiting for Deployment to observe RELATED_IMAGE_KUBEVIRT_DATAMOVER_CONTROLLER=${KDM_CONTROLLER_IMAGE}"
for i in $(seq 1 60); do
CURRENT=$(oc get deployment/openshift-adp-controller-manager -n "${OO_INSTALL_NAMESPACE}" -o jsonpath="{.spec.template.spec.containers[?(@.name==\"manager\")].env[?(@.name==\"RELATED_IMAGE_KUBEVIRT_DATAMOVER_CONTROLLER\")].value}" 2>/dev/null || true)
[ "${CURRENT}" = "${KDM_CONTROLLER_IMAGE}" ] && break
sleep 5
done
if [ "${CURRENT}" != "${KDM_CONTROLLER_IMAGE}" ]; then
echo "Timed out waiting for Deployment spec to reflect the Subscription.spec.config.env override" >&2
oc get subscription "${SUB}" -n "${OO_INSTALL_NAMESPACE}" -o yaml > "${ARTIFACT_DIR}/subscription-${SUB}.yaml" || true
oc get csv -n "${OO_INSTALL_NAMESPACE}" -o yaml > "${ARTIFACT_DIR}/csvs.yaml" || true
exit 1
fi
oc rollout status deployment/openshift-adp-controller-manager -n "${OO_INSTALL_NAMESPACE}" --timeout=180s
dependencies:
- env: KDM_CONTROLLER_IMAGE
name: kubevirt-datamover-controller-oadp-1.6
from: cli
resources:
requests:
cpu: 100m
memory: 100Mi
- as: e2e
cli: latest
commands: make TEST_VIRT=true test-e2e

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

since you are NOW running oadp-operator e2e tests against KDM repos and not out of the operator only. It would make sense to create a new VIRT test suite for KDM. You'd only want to run the KDM virt suite against kdm-controller/plugin imho. In the oadp-operator that would mean a new job most likely due to time constraints. Anyhoo this is very cool and let's roll w/ what you have for now.

credentials:
- mount_path: /var/run/oadp-credentials
name: oadp-credentials
namespace: test-credentials
from: test-oadp-operator
resources:
requests:
cpu: 1000m
memory: 512Mi
zz_generated_metadata:
branch: oadp-1.6
org: migtools
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
base_images:
test-oadp-operator:
name: oadp-operator-e2e-tests
namespace: konveyor
tag: oadp-dev
build_root:
image_stream_tag:
name: builder
Expand All @@ -13,13 +18,82 @@ promotion:
to:
- namespace: konveyor
tag: oadp-dev
releases:
latest:
candidate:
product: ocp
stream: nightly
version: "5.0"
resources:
'*':
limits:
memory: 4Gi
requests:
cpu: 100m
memory: 200Mi
tests:
- always_run: false
as: e2e-test-aws
run_if_changed: .+\.go|go\.(\bmod\b|\bsum\b)|Makefile|Dockerfile|.dockerignore|.*\.ya{0,1}ml|.sh
steps:
cluster_profile: openshift-org-aws
env:
OO_BUNDLE: registry.ci.openshift.org/konveyor/oadp-operator-bundle:oadp-dev
OO_INSTALL_MODE: OwnNamespace
OO_INSTALL_NAMESPACE: openshift-adp
post:
- chain: ipi-aws-post
pre:
- chain: ipi-aws-pre
- ref: optional-operators-operator-sdk-non-ci-bundle-image
test:
- as: set-related-image
cli: latest
commands: |
SUB=$(oc get subscription -n "${OO_INSTALL_NAMESPACE}" -o jsonpath='{.items[0].metadata.name}')
if [ -z "${SUB}" ]; then
echo "No Subscription found in namespace ${OO_INSTALL_NAMESPACE}" >&2
exit 1
fi
echo "Discovered Subscription: ${SUB}"
# Subscription.spec.config.env is OLM's supported override mechanism:
# it wins over same-named CSV env vars and survives reconciliation,
# unlike patching the Deployment directly (OLM reconciles that from
# the CSV and would revert it).
oc patch subscription "${SUB}" -n "${OO_INSTALL_NAMESPACE}" --type merge -p "$(jq -n --arg img "${KDM_CONTROLLER_IMAGE}" '{spec:{config:{env:[{name:"RELATED_IMAGE_KUBEVIRT_DATAMOVER_CONTROLLER",value:$img}]}}}')"
echo "Waiting for Deployment to observe RELATED_IMAGE_KUBEVIRT_DATAMOVER_CONTROLLER=${KDM_CONTROLLER_IMAGE}"
for i in $(seq 1 60); do
CURRENT=$(oc get deployment/openshift-adp-controller-manager -n "${OO_INSTALL_NAMESPACE}" -o jsonpath="{.spec.template.spec.containers[?(@.name==\"manager\")].env[?(@.name==\"RELATED_IMAGE_KUBEVIRT_DATAMOVER_CONTROLLER\")].value}" 2>/dev/null || true)
[ "${CURRENT}" = "${KDM_CONTROLLER_IMAGE}" ] && break
sleep 5
done
Comment on lines +65 to +69

Copy link
Copy Markdown
Contributor

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
set -euo pipefail
oc options 2>&1 | grep -F -- '--request-timeout'

Repository: openshift/release

Length of output: 155


🏁 Script executed:

#!/bin/bash
set -euo pipefail

file='ci-operator/config/migtools/kubevirt-datamover-controller/migtools-kubevirt-datamover-controller-oadp-dev.yaml'

printf '%s\n' '--- target lines ---'
sed -n '45,80p' "$file"

printf '%s\n' '--- related timeout and oc usage ---'
rg -n -C 3 --fixed-strings 'openshift-adp-controller-manager' .
rg -n -C 2 'oc (get|wait)|request-timeout|timeout [0-9].*oc|timeout --' "$file" .github ci-operator 2>/dev/null | head -n 240

Repository: openshift/release

Length of output: 50375


🌐 Web query:

OpenShift oc CLI documentation for --request-timeout, including whether oc supports the kubectl request-timeout option and its default behavior

💡 Result:

The OpenShift CLI (oc) supports the --request-timeout option, which functions similarly to the equivalent option in kubectl [1][2][3]. Documentation and Behavior: The --request-timeout flag specifies the length of time the client waits before giving up on a single server request [1][4]. It requires a value with a corresponding time unit (e.g., 1s, 2m, 3h) if a non-zero value is provided [1][3]. Default Behavior: The default value for --request-timeout is "0", which signifies that the client will not timeout requests [1][3]. Compatibility with kubectl: Because oc is built upon the Kubernetes client libraries, it supports the --request-timeout option in the same manner as kubectl [3]. Both tools interpret the flag to control the timeout duration for API server interactions [1][3]. While most commands consistently respect this flag, historical issues have been noted where specific sub-commands (such as oc login in older versions) did not always honor the timeout correctly, necessitating patches to ensure the configuration is properly passed to the underlying REST client [5][6][7].

Citations:


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- oc references and installation/version evidence ---'
rg -n -C 3 '\boc\b|openshift-client|ocp|OPENSHIFT_VERSION|CLUSTER_VERSION' \
  ci-operator/config/migtools/kubevirt-datamover-controller \
  ci-operator/jobs/migtools/kubevirt-datamover-controller \
  .github 2>/dev/null | head -n 300

printf '%s\n' '--- file metadata and nearby job structure ---'
wc -l ci-operator/config/migtools/kubevirt-datamover-controller/migtools-kubevirt-datamover-controller-oadp-dev.yaml
sed -n '1,120p' ci-operator/config/migtools/kubevirt-datamover-controller/migtools-kubevirt-datamover-controller-oadp-dev.yaml

Repository: openshift/release

Length of output: 4329


🌐 Web query:

site:docs.openshift.com oc request-timeout oc get

💡 Result:

There is no global --request-timeout flag for the oc get command [1][2]. The --timeout option available with oc get is specifically used to set the length of time to wait for a specific operation to complete, such as waiting for a node or a resource to reach a specific state [1]. If you are looking to manage timeouts for network traffic or application routes, you must use different methods depending on the context: 1. Route Timeouts: You can configure timeouts for specific routes using the oc annotate command to add a timeout value to the route's configuration: oc annotate route <route_name> --overwrite haproxy.router.openshift.io/timeout=<time_unit> Supported time units include ms, s, m, h, and d [3][4]. 2. Ingress Controller Timeouts: For global ingress settings, you can configure timeout values within the Ingress Controller's configuration, such as clientTimeout or serverTimeout [5]. If you were referring to a different CLI tool, such as roxctl, that tool does feature a --timeout flag for API requests [6], but this does not apply to the standard oc CLI.

Citations:


Bound each oc request.

Line 63 can block indefinitely because oc get has no request timeout. Add --request-timeout=10s so the loop can enforce its retry deadline.

🤖 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
`@ci-operator/config/migtools/kubevirt-datamover-controller/migtools-kubevirt-datamover-controller-oadp-dev.yaml`
around lines 62 - 66, Add --request-timeout=10s to the oc get invocation in the
retry loop so each request is bounded and the existing 60-iteration deadline
remains enforceable.

Source: MCP tools

if [ "${CURRENT}" != "${KDM_CONTROLLER_IMAGE}" ]; then
echo "Timed out waiting for Deployment spec to reflect the Subscription.spec.config.env override" >&2
oc get subscription "${SUB}" -n "${OO_INSTALL_NAMESPACE}" -o yaml > "${ARTIFACT_DIR}/subscription-${SUB}.yaml" || true
oc get csv -n "${OO_INSTALL_NAMESPACE}" -o yaml > "${ARTIFACT_DIR}/csvs.yaml" || true
exit 1
fi
oc rollout status deployment/openshift-adp-controller-manager -n "${OO_INSTALL_NAMESPACE}" --timeout=180s
dependencies:
- env: KDM_CONTROLLER_IMAGE
name: kubevirt-datamover-controller
from: cli
resources:
requests:
cpu: 100m
memory: 100Mi
- as: e2e
cli: latest
commands: make TEST_VIRT=true test-e2e
credentials:
- mount_path: /var/run/oadp-credentials
name: oadp-credentials
namespace: test-credentials
from: test-oadp-operator
resources:
requests:
cpu: 1000m
memory: 512Mi
zz_generated_metadata:
branch: oadp-dev
org: migtools
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
base_images:
test-oadp-operator:
name: oadp-operator-e2e-tests
namespace: konveyor
tag: oadp-1.6
build_root:
image_stream_tag:
name: builder
Expand All @@ -13,13 +18,82 @@ promotion:
to:
- name: kubevirt-datamover-plugin
namespace: konveyor
releases:
latest:
candidate:
product: ocp
stream: nightly
version: "5.0"
resources:
'*':
limits:
memory: 4Gi
requests:
cpu: 100m
memory: 200Mi
tests:
- always_run: false
as: e2e-test-aws
run_if_changed: .+\.go|go\.(\bmod\b|\bsum\b)|Makefile|Dockerfile|.dockerignore|.*\.ya{0,1}ml|.sh
steps:
cluster_profile: openshift-org-aws
env:
OO_BUNDLE: registry.ci.openshift.org/konveyor/oadp-operator-bundle:oadp-1.6
OO_INSTALL_MODE: OwnNamespace
OO_INSTALL_NAMESPACE: openshift-adp
post:
- chain: ipi-aws-post
pre:
- chain: ipi-aws-pre
- ref: optional-operators-operator-sdk-non-ci-bundle-image
test:
- as: set-related-image
cli: latest
commands: |
SUB=$(oc get subscription -n "${OO_INSTALL_NAMESPACE}" -o jsonpath='{.items[0].metadata.name}')
if [ -z "${SUB}" ]; then
echo "No Subscription found in namespace ${OO_INSTALL_NAMESPACE}" >&2
exit 1
fi
echo "Discovered Subscription: ${SUB}"
# Subscription.spec.config.env is OLM's supported override mechanism:
# it wins over same-named CSV env vars and survives reconciliation,
# unlike patching the Deployment directly (OLM reconciles that from
# the CSV and would revert it).
oc patch subscription "${SUB}" -n "${OO_INSTALL_NAMESPACE}" --type merge -p "$(jq -n --arg img "${KDM_PLUGIN_IMAGE}" '{spec:{config:{env:[{name:"RELATED_IMAGE_KUBEVIRT_DATAMOVER_PLUGIN",value:$img}]}}}')"
echo "Waiting for Deployment to observe RELATED_IMAGE_KUBEVIRT_DATAMOVER_PLUGIN=${KDM_PLUGIN_IMAGE}"
for i in $(seq 1 60); do
CURRENT=$(oc get deployment/openshift-adp-controller-manager -n "${OO_INSTALL_NAMESPACE}" -o jsonpath="{.spec.template.spec.containers[?(@.name==\"manager\")].env[?(@.name==\"RELATED_IMAGE_KUBEVIRT_DATAMOVER_PLUGIN\")].value}" 2>/dev/null || true)
[ "${CURRENT}" = "${KDM_PLUGIN_IMAGE}" ] && break
sleep 5
done
if [ "${CURRENT}" != "${KDM_PLUGIN_IMAGE}" ]; then
echo "Timed out waiting for Deployment spec to reflect the Subscription.spec.config.env override" >&2
oc get subscription "${SUB}" -n "${OO_INSTALL_NAMESPACE}" -o yaml > "${ARTIFACT_DIR}/subscription-${SUB}.yaml" || true
oc get csv -n "${OO_INSTALL_NAMESPACE}" -o yaml > "${ARTIFACT_DIR}/csvs.yaml" || true
exit 1
fi
oc rollout status deployment/openshift-adp-controller-manager -n "${OO_INSTALL_NAMESPACE}" --timeout=180s
dependencies:
- env: KDM_PLUGIN_IMAGE
name: kubevirt-datamover-plugin-oadp-1.6
from: cli
resources:
requests:
cpu: 100m
memory: 100Mi
- as: e2e
cli: latest
commands: make TEST_VIRT=true test-e2e
credentials:
- mount_path: /var/run/oadp-credentials
name: oadp-credentials
namespace: test-credentials
from: test-oadp-operator
resources:
requests:
cpu: 1000m
memory: 512Mi
zz_generated_metadata:
branch: oadp-1.6
org: migtools
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
base_images:
test-oadp-operator:
name: oadp-operator-e2e-tests
namespace: konveyor
tag: oadp-dev
build_root:
image_stream_tag:
name: builder
Expand All @@ -13,13 +18,82 @@ promotion:
to:
- namespace: konveyor
tag: oadp-dev
releases:
latest:
candidate:
product: ocp
stream: nightly
version: "5.0"
resources:
'*':
limits:
memory: 4Gi
requests:
cpu: 100m
memory: 200Mi
tests:
- always_run: false
as: e2e-test-aws
run_if_changed: .+\.go|go\.(\bmod\b|\bsum\b)|Makefile|Dockerfile|.dockerignore|.*\.ya{0,1}ml|.sh
steps:
cluster_profile: openshift-org-aws
env:
OO_BUNDLE: registry.ci.openshift.org/konveyor/oadp-operator-bundle:oadp-dev
OO_INSTALL_MODE: OwnNamespace
OO_INSTALL_NAMESPACE: openshift-adp
post:
- chain: ipi-aws-post
pre:
- chain: ipi-aws-pre
- ref: optional-operators-operator-sdk-non-ci-bundle-image
test:
- as: set-related-image
cli: latest
commands: |
SUB=$(oc get subscription -n "${OO_INSTALL_NAMESPACE}" -o jsonpath='{.items[0].metadata.name}')
if [ -z "${SUB}" ]; then
echo "No Subscription found in namespace ${OO_INSTALL_NAMESPACE}" >&2
exit 1
fi
echo "Discovered Subscription: ${SUB}"
# Subscription.spec.config.env is OLM's supported override mechanism:
# it wins over same-named CSV env vars and survives reconciliation,
# unlike patching the Deployment directly (OLM reconciles that from
# the CSV and would revert it).
oc patch subscription "${SUB}" -n "${OO_INSTALL_NAMESPACE}" --type merge -p "$(jq -n --arg img "${KDM_PLUGIN_IMAGE}" '{spec:{config:{env:[{name:"RELATED_IMAGE_KUBEVIRT_DATAMOVER_PLUGIN",value:$img}]}}}')"
echo "Waiting for Deployment to observe RELATED_IMAGE_KUBEVIRT_DATAMOVER_PLUGIN=${KDM_PLUGIN_IMAGE}"
for i in $(seq 1 60); do
CURRENT=$(oc get deployment/openshift-adp-controller-manager -n "${OO_INSTALL_NAMESPACE}" -o jsonpath="{.spec.template.spec.containers[?(@.name==\"manager\")].env[?(@.name==\"RELATED_IMAGE_KUBEVIRT_DATAMOVER_PLUGIN\")].value}" 2>/dev/null || true)
[ "${CURRENT}" = "${KDM_PLUGIN_IMAGE}" ] && break
sleep 5
done
if [ "${CURRENT}" != "${KDM_PLUGIN_IMAGE}" ]; then
echo "Timed out waiting for Deployment spec to reflect the Subscription.spec.config.env override" >&2
oc get subscription "${SUB}" -n "${OO_INSTALL_NAMESPACE}" -o yaml > "${ARTIFACT_DIR}/subscription-${SUB}.yaml" || true
oc get csv -n "${OO_INSTALL_NAMESPACE}" -o yaml > "${ARTIFACT_DIR}/csvs.yaml" || true
exit 1
fi
oc rollout status deployment/openshift-adp-controller-manager -n "${OO_INSTALL_NAMESPACE}" --timeout=180s
dependencies:
- env: KDM_PLUGIN_IMAGE
name: kubevirt-datamover-plugin
from: cli
resources:
requests:
cpu: 100m
memory: 100Mi
- as: e2e
cli: latest
commands: make TEST_VIRT=true test-e2e
credentials:
- mount_path: /var/run/oadp-credentials
name: oadp-credentials
namespace: test-credentials
from: test-oadp-operator
resources:
requests:
cpu: 1000m
memory: 512Mi
zz_generated_metadata:
branch: oadp-dev
org: migtools
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,18 @@ images:
to: test-oadp-operator
operator:
bundles:
- dockerfile_path: build/Dockerfile.bundle
- as: oadp-operator-bundle
dockerfile_path: build/Dockerfile.bundle
skip_building_index: true
promotion:
to:
- excluded_images:
- test-oadp-operator
name: oadp-operator
namespace: konveyor
- additional_images:
oadp-operator-bundle: oadp-operator-bundle
oadp-operator-e2e-tests: test-oadp-operator
oadp-operator-index: ci-index
namespace: konveyor
tag: oadp-1.6
resources:
Expand Down
Loading