afterincomparableyum commented on code in PR #3877:
URL: https://github.com/apache/celeborn/pull/3877#discussion_r4311190005
##########
build/sbt-launch-lib.bash:
##########
@@ -73,16 +79,25 @@ acquire_sbt_jar () {
# Download
printf "Attempting to fetch sbt\n"
JAR_DL="${JAR}.part"
- if [ $(command -v curl) ]; then
- curl --fail --location --silent ${URL1} > "${JAR_DL}" &&\
- mv "${JAR_DL}" "${JAR}"
- elif [ $(command -v wget) ]; then
- wget --quiet ${URL1} -O "${JAR_DL}" &&\
- mv "${JAR_DL}" "${JAR}"
- else
- printf "You do not have curl or wget installed, please install sbt
manually from https://www.scala-sbt.org/\n"
- exit -1
+ CURL_RETRY_OPTS="--retry 3 --retry-delay 5"
+ # --retry alone skips DNS, connection and 403 errors; --retry-all-errors
needs curl 7.71+.
+ if [ $(command -v curl) ] && curl --help all 2>/dev/null | grep -q --
"--retry-all-errors"; then
+ CURL_RETRY_OPTS="${CURL_RETRY_OPTS} --retry-all-errors"
fi
+ for URL in ${URLS}; do
+ if [ $(command -v curl) ]; then
+ curl --fail --location --silent --show-error ${CURL_RETRY_OPTS} ${URL}
> "${JAR_DL}" &&\
Review Comment:
thank you, I have applied the change @zaynt4606
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]