File tree 2 files changed +23
-1
lines changed
flink-end-to-end-tests/test-scripts
2 files changed +23
-1
lines changed Original file line number Diff line number Diff line change @@ -791,6 +791,27 @@ function retry_times_with_backoff_and_cleanup() {
791
791
return 1
792
792
}
793
793
794
+ function retry_times_with_exponential_backoff {
795
+ local retries=$1
796
+ shift
797
+
798
+ local count=0
799
+ echo " Executing command:" " $@ "
800
+ until " $@ " ; do
801
+ exit=$?
802
+ wait=$(( 2 ** $count ))
803
+ count=$(( $count + 1 ))
804
+ if [ $count -lt $retries ]; then
805
+ echo " Retry $count /$retries exited $exit , retrying in $wait seconds..."
806
+ sleep $wait
807
+ else
808
+ echo " Retry $count /$retries exited $exit , no more retries left."
809
+ return $exit
810
+ fi
811
+ done
812
+ return 0
813
+ }
814
+
794
815
JOB_ID_REGEX_EXTRACTOR=" .*JobID ([0-9,a-f]*)"
795
816
796
817
function extract_job_id_from_job_submission_return() {
Original file line number Diff line number Diff line change @@ -77,7 +77,8 @@ function _set_conf_ssl_helper {
77
77
# -> we need to build it ourselves
78
78
FLINK_SHADED_VERSION=$( cat ${END_TO_END_DIR} /../pom.xml | sed -n ' s/.*<flink.shaded.version>\(.*\)<\/flink.shaded.version>/\1/p' )
79
79
echo " BUILDING flink-shaded-netty-tcnative-static"
80
- git clone https://github.com/apache/flink-shaded.git
80
+ # Adding retry to git clone, due to FLINK-24971
81
+ retry_times_with_exponential_backoff 5 git clone https://github.com/apache/flink-shaded.git
81
82
cd flink-shaded
82
83
git checkout " release-${FLINK_SHADED_VERSION} "
83
84
run_mvn clean package -Pinclude-netty-tcnative-static -pl flink-shaded-netty-tcnative-static
You can’t perform that action at this time.
0 commit comments