Skip to content
Browse files

[SPARK-25854][BUILD] fix `build/mvn` not to fail during Zinc server s…


the final line in the mvn helper script in build/ attempts to shut down the zinc server.  due to the zinc server being set up w/a 30min timeout, by the time the mvn test instantiation finishes, the server times out.

this means that when the mvn script tries to shut down zinc, it returns w/an exit code of 1.  this will then automatically fail the entire build (even if the build passes).

i set up a test build:

Closes #22854 from shaneknapp/fix-mvn-helper-script.

Authored-by: shane knapp <>
Signed-off-by: Sean Owen <>
(cherry picked from commit 6aa5063)
Signed-off-by: Sean Owen <>
  • Loading branch information...
shaneknapp authored and srowen committed Oct 26, 2018
1 parent 0a05cf9 commit 3afb3a20e670c73677ab96d6fe5fcb3380800f33
Showing with 8 additions and 4 deletions.
  1. +8 −4 build/mvn
@@ -144,7 +144,7 @@ if [ -n "${ZINC_INSTALL_FLAG}" -o -z "`"${ZINC_BIN}" -status -port ${ZINC_PORT}`
"${ZINC_BIN}" -shutdown -port ${ZINC_PORT}
"${ZINC_BIN}" -start -port ${ZINC_PORT} \
-server -idle-timeout 30m \
-server -idle-timeout 3h \
-scala-compiler "${SCALA_COMPILER}" \
-scala-library "${SCALA_LIBRARY}" &>/dev/null
@@ -154,8 +154,12 @@ export MAVEN_OPTS=${MAVEN_OPTS:-"$_COMPILE_JVM_OPTS"}

echo "Using \`mvn\` from path: $MVN_BIN" 1>&2

# Last, call the `mvn` command as usual
${MVN_BIN} -DzincPort=${ZINC_PORT} "$@"
# call the `mvn` command as usual
# SPARK-25854
"${MVN_BIN}" -DzincPort=${ZINC_PORT} "$@"

# Try to shut down zinc explicitly
# Try to shut down zinc explicitly if the server is still running.
"${ZINC_BIN}" -shutdown -port ${ZINC_PORT}


0 comments on commit 3afb3a2

Please sign in to comment.
You can’t perform that action at this time.