This is an automated email from the ASF dual-hosted git repository.

gyfora pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/flink-kubernetes-operator.git


The following commit(s) were added to refs/heads/main by this push:
     new ec9d6011 [FLINK-30150] Ignore "REST service in session cluster is bad 
now" where we kill the JobManager manually
ec9d6011 is described below

commit ec9d60113a4dda072d97e48462a059c6a3c84151
Author: pvary <[email protected]>
AuthorDate: Thu Dec 15 15:26:24 2022 +0100

    [FLINK-30150] Ignore "REST service in session cluster is bad now" where we 
kill the JobManager manually
---
 e2e-tests/test_application_kubernetes_ha.sh |  2 +-
 e2e-tests/test_sessionjob_kubernetes_ha.sh  |  2 +-
 e2e-tests/utils.sh                          | 20 +++++++++++++-------
 3 files changed, 15 insertions(+), 9 deletions(-)

diff --git a/e2e-tests/test_application_kubernetes_ha.sh 
b/e2e-tests/test_application_kubernetes_ha.sh
index eda15bc6..3cafd0a1 100755
--- a/e2e-tests/test_application_kubernetes_ha.sh
+++ b/e2e-tests/test_application_kubernetes_ha.sh
@@ -47,7 +47,7 @@ wait_for_logs $jm_pod_name "Completed checkpoint [0-9]+ for 
job" ${TIMEOUT} || e
 wait_for_status flinkdep/flink-example-statemachine 
'.status.jobManagerDeploymentStatus' READY ${TIMEOUT} || exit 1
 wait_for_status flinkdep/flink-example-statemachine '.status.jobStatus.state' 
RUNNING ${TIMEOUT} || exit 1
 
-check_operator_log_for_errors || exit 1
+check_operator_log_for_errors '|grep -v "REST service in session cluster is 
bad now"' || exit 1
 
 echo "Successfully run the Flink Kubernetes application HA test"
 
diff --git a/e2e-tests/test_sessionjob_kubernetes_ha.sh 
b/e2e-tests/test_sessionjob_kubernetes_ha.sh
index 7a0fa813..b768d435 100755
--- a/e2e-tests/test_sessionjob_kubernetes_ha.sh
+++ b/e2e-tests/test_sessionjob_kubernetes_ha.sh
@@ -48,7 +48,7 @@ wait_for_logs $jm_pod_name "Completed checkpoint [0-9]+ for 
job" ${TIMEOUT} || e
 wait_for_status $SESSION_CLUSTER_IDENTIFIER 
'.status.jobManagerDeploymentStatus' READY ${TIMEOUT} || exit 1
 wait_for_status $SESSION_JOB_IDENTIFIER '.status.jobStatus.state' RUNNING 
${TIMEOUT} || exit 1
 
-check_operator_log_for_errors || exit 1
+check_operator_log_for_errors '|grep -v "REST service in session cluster is 
bad now"' || exit 1
 
 echo "Successfully run the Flink Session Job HA test"
 
diff --git a/e2e-tests/utils.sh b/e2e-tests/utils.sh
index 76ee9190..7149e251 100755
--- a/e2e-tests/utils.sh
+++ b/e2e-tests/utils.sh
@@ -131,6 +131,7 @@ function retry_times() {
 }
 
 function check_operator_log_for_errors {
+  local ignore=$1
   echo "Checking for operator log errors..."
   #https://issues.apache.org/jira/browse/FLINK-30310
   echo "Error checking is temporarily turned off."
@@ -139,13 +140,18 @@ function check_operator_log_for_errors {
   operator_pod_namespace=$(get_operator_pod_namespace)
   operator_pod_name=$(get_operator_pod_name)
   echo "Operator namespace: ${operator_pod_namespace} pod: 
${operator_pod_name}"
-  errors=$(kubectl logs -n "${operator_pod_namespace}" "${operator_pod_name}" \
-      | grep -v "Failed to submit a listener notification task" 
`#https://issues.apache.org/jira/browse/FLINK-30147` \
-      | grep -v "Failed to submit job to session cluster" 
`#https://issues.apache.org/jira/browse/FLINK-30148` \
-      | grep -v "Error during event processing" 
`#https://issues.apache.org/jira/browse/FLINK-30149` \
-      | grep -v "REST service in session cluster is bad now" 
`#https://issues.apache.org/jira/browse/FLINK-30150` \
-      | grep -v "Error while patching status" 
`#https://issues.apache.org/jira/browse/FLINK-30283` \
-      | grep -e "\[\s*ERROR\s*\]" || true)
+
+  local cmd="kubectl logs -n ${operator_pod_namespace} ${operator_pod_name}
+    | grep -e '\[\s*ERROR\s*\]'
+    | grep -v 'Failed to submit a listener notification task' 
`#https://issues.apache.org/jira/browse/FLINK-30147`
+    | grep -v 'Failed to submit job to session cluster' 
`#https://issues.apache.org/jira/browse/FLINK-30148`
+    | grep -v 'Error during event processing' 
`#https://issues.apache.org/jira/browse/FLINK-30149`
+    | grep -v 'Error while patching status' 
`#https://issues.apache.org/jira/browse/FLINK-30283`
+    ${ignore}"
+
+  echo "Filter command: ${cmd}"
+  errors=$(eval ${cmd} || true)
+
   if [ -z "${errors}" ]; then
     echo "No errors in log files."
     return 0

Reply via email to