From 9c46f4100c393bc971733ea55fb172500fa6e653 Mon Sep 17 00:00:00 2001 From: Oleksandr Andriienko Date: Wed, 8 Apr 2026 18:56:16 +0300 Subject: [PATCH 1/2] fix(orchestrator): query by CSV name prefix instead of displayName for stability Signed-off-by: Oleksandr Andriienko --- .../orchestrator/install-orchestrator.sh | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/src/deployment/orchestrator/install-orchestrator.sh b/src/deployment/orchestrator/install-orchestrator.sh index 94e347d..0469708 100755 --- a/src/deployment/orchestrator/install-orchestrator.sh +++ b/src/deployment/orchestrator/install-orchestrator.sh @@ -123,13 +123,19 @@ EOD } check_operator_status() { - local timeout=${1:-300} namespace=$2 operator_name=$3 expected_status=${4:-Succeeded} - log::info "Checking operator '${operator_name}' in '${namespace}' (timeout ${timeout}s, expected: ${expected_status})" + local timeout=${1:-300} namespace=$2 csv_name_prefix=$3 expected_status=${4:-Succeeded} + log::info "Checking operator CSV '${csv_name_prefix}*' in '${namespace}' (timeout ${timeout}s, expected: ${expected_status})" timeout "${timeout}" bash -c " while true; do - CURRENT_PHASE=\$(oc get csv -n '${namespace}' -o jsonpath='{.items[?(@.spec.displayName==\"${operator_name}\")].status.phase}') - echo \"[check_operator_status] Phase: \${CURRENT_PHASE}\" >&2 + CSV_NAME=\$(oc get csv -n '${namespace}' -o name 2>/dev/null | grep \"/${csv_name_prefix}\" | head -1 | cut -d'/' -f2) + if [[ -n \"\${CSV_NAME}\" ]]; then + CURRENT_PHASE=\$(oc get csv \"\${CSV_NAME}\" -n '${namespace}' -o jsonpath='{.status.phase}' 2>/dev/null) + else + CURRENT_PHASE=\"\" + fi + echo \"[check_operator_status] CSV: \${CSV_NAME}, Phase: \${CURRENT_PHASE}\" >&2 [[ \"\${CURRENT_PHASE}\" == \"${expected_status}\" ]] && echo \"[check_operator_status] Operator reached ${expected_status}\" >&2 && break + [[ -z \"\${CSV_NAME}\" ]] && echo \"[check_operator_status] No CSV found matching '${csv_name_prefix}'\" >&2 sleep 10 done " || { log::error "Operator did not reach ${expected_status} in time."; return 1; } @@ -140,7 +146,7 @@ install_serverless_logic_ocp_operator() { return 0 } waitfor_serverless_logic_ocp_operator() { - check_operator_status 500 openshift-operators "Red Hat OpenShift Serverless Logic" Succeeded + check_operator_status 500 openshift-operators "logic-operator" Succeeded return 0 } @@ -149,7 +155,7 @@ install_serverless_ocp_operator() { return 0 } waitfor_serverless_ocp_operator() { - check_operator_status 300 openshift-operators "Red Hat OpenShift Serverless" Succeeded + check_operator_status 300 openshift-operators "serverless-operator" Succeeded return 0 } From 046f91b65f3f26f2bf160e06a460ffd7ee5aca5d Mon Sep 17 00:00:00 2001 From: Oleksandr Andriienko Date: Wed, 8 Apr 2026 23:56:45 +0300 Subject: [PATCH 2/2] fix(orchestrator): update changelog and version Signed-off-by: Oleksandr Andriienko --- docs/changelog.md | 9 ++++++++- package.json | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/docs/changelog.md b/docs/changelog.md index a20702d..267cc06 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -2,7 +2,14 @@ All notable changes to this project will be documented in this file. -## [1.1.28] - Current +## [1.1.29] - Current + +### Fixed + +- **Orchestrator installation script operator status check**: Fixed `install-orchestrator.sh` timeout issue caused by incorrect operator display name. The script was searching for "Red Hat OpenShift Serverless Logic" but the actual display name is "OpenShift Serverless Logic Operator", causing empty Phase values and 500-second timeout. +- **Robust operator status checking**: Refactored `check_operator_status()` to query by CSV name prefix (e.g., `logic-operator`) instead of display name, making it more stable across operator version updates and preventing similar issues in the future. + +## [1.1.28] - **APIHelper.createGitHubRepoWithFile**: Ensure file creation happens after repository creation. diff --git a/package.json b/package.json index 7e0ad02..ea327b6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@red-hat-developer-hub/e2e-test-utils", - "version": "1.1.28", + "version": "1.1.29", "description": "Test utilities for RHDH E2E tests", "license": "Apache-2.0", "repository": {