You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flink.apache.org by rm...@apache.org on 2020/06/05 08:07:20 UTC

[flink] branch master updated: [FLINK-18069][CI] Test if Scala/JavaDocs builds are passing in the compile stage

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

rmetzger pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/flink.git


The following commit(s) were added to refs/heads/master by this push:
     new 46d42e5  [FLINK-18069][CI] Test if Scala/JavaDocs builds are passing in the compile stage
46d42e5 is described below

commit 46d42e5b718ea2cd914dc7feaf4425e04c3e4645
Author: Robert Metzger <rm...@apache.org>
AuthorDate: Tue Jun 2 15:07:44 2020 +0200

    [FLINK-18069][CI] Test if Scala/JavaDocs builds are passing in the compile stage
    
    This closes #12447
---
 tools/ci/compile.sh | 65 ++++++++++++++++++++++++++++++++++-------------------
 1 file changed, 42 insertions(+), 23 deletions(-)

diff --git a/tools/ci/compile.sh b/tools/ci/compile.sh
index b0b4803..00665ec 100755
--- a/tools/ci/compile.sh
+++ b/tools/ci/compile.sh
@@ -47,35 +47,54 @@ run_mvn clean install $MAVEN_OPTS -Dflink.convergence.phase=install -Pcheck-conv
 
 EXIT_CODE=$?
 
-if [ $EXIT_CODE == 0 ]; then
+if [ $EXIT_CODE != 0 ]; then
     echo "=============================================================================="
-    echo "Checking scala suffixes"
+    echo "Compiling Flink failed."
     echo "=============================================================================="
+    exit $EXIT_CODE
+fi
 
-    ${CI_DIR}/verify_scala_suffixes.sh "${PROFILE}"
-    EXIT_CODE=$?
-else
-    echo "=============================================================================="
-    echo "Previous build failure detected, skipping scala-suffixes check."
-    echo "=============================================================================="
+echo "============ Checking Javadocs ============"
+
+# use the same invocation as on buildbot (https://svn.apache.org/repos/infra/infrastructure/buildbot/aegis/buildmaster/master1/projects/flink.conf)
+run_mvn javadoc:aggregate -Paggregate-scaladoc -DadditionalJOption='-Xdoclint:none' \
+      -Dmaven.javadoc.failOnError=false -Dcheckstyle.skip=true -Denforcer.skip=true \
+      -Dheader=someTestHeader > javadoc.out
+EXIT_CODE=$?
+if [ $EXIT_CODE != 0 ] ; then
+  echo "ERROR in Javadocs. Printing full output:"
+  cat javadoc.out ; rm javadoc.out
+  exit $EXIT_CODE
 fi
 
-if [ $EXIT_CODE == 0 ]; then
-    check_shaded_artifacts
-    EXIT_CODE=$(($EXIT_CODE+$?))
-    check_shaded_artifacts_s3_fs hadoop
-    EXIT_CODE=$(($EXIT_CODE+$?))
-    check_shaded_artifacts_s3_fs presto
-    EXIT_CODE=$(($EXIT_CODE+$?))
-    check_shaded_artifacts_connector_elasticsearch 5
-    EXIT_CODE=$(($EXIT_CODE+$?))
-    check_shaded_artifacts_connector_elasticsearch 6
-    EXIT_CODE=$(($EXIT_CODE+$?))
-else
-    echo "=============================================================================="
-    echo "Previous build failure detected, skipping shaded dependency check."
-    echo "=============================================================================="
+echo "============ Checking Scaladocs ============"
+
+cd flink-scala
+run_mvn scala:doc 2> scaladoc.out
+EXIT_CODE=$?
+if [ $EXIT_CODE != 0 ] ; then
+  echo "ERROR in Scaladocs. Printing full output:"
+  cat scaladoc.out ; rm scaladoc.out
+  exit $EXIT_CODE
 fi
+cd ..
+
+echo "============ Checking scala suffixes ============"
+
+${CI_DIR}/verify_scala_suffixes.sh "${PROFILE}" || exit $?
+
+echo "============ Checking shaded dependencies ============"
+
+check_shaded_artifacts
+EXIT_CODE=$(($EXIT_CODE+$?))
+check_shaded_artifacts_s3_fs hadoop
+EXIT_CODE=$(($EXIT_CODE+$?))
+check_shaded_artifacts_s3_fs presto
+EXIT_CODE=$(($EXIT_CODE+$?))
+check_shaded_artifacts_connector_elasticsearch 5
+EXIT_CODE=$(($EXIT_CODE+$?))
+check_shaded_artifacts_connector_elasticsearch 6
+EXIT_CODE=$(($EXIT_CODE+$?))
 
 exit $EXIT_CODE