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 2015/03/04 10:57:53 UTC
flink git commit: [FLINK-1637] Reduce number of files in uberjar for
java 6
Repository: flink
Updated Branches:
refs/heads/travis_test [created] 393612ba3
[FLINK-1637] Reduce number of files in uberjar for java 6
Project: http://git-wip-us.apache.org/repos/asf/flink/repo
Commit: http://git-wip-us.apache.org/repos/asf/flink/commit/393612ba
Tree: http://git-wip-us.apache.org/repos/asf/flink/tree/393612ba
Diff: http://git-wip-us.apache.org/repos/asf/flink/diff/393612ba
Branch: refs/heads/travis_test
Commit: 393612ba3b65952847319f7633aa61256d33ff01
Parents: 94a66d5
Author: Robert Metzger <rm...@apache.org>
Authored: Tue Mar 3 12:44:21 2015 +0100
Committer: Robert Metzger <rm...@apache.org>
Committed: Wed Mar 4 10:54:20 2015 +0100
----------------------------------------------------------------------
.travis.yml | 8 +++----
flink-dist/pom.xml | 23 --------------------
.../examples/java/wordcount/WordCount.java | 3 ++-
tools/create_release_files.sh | 5 +++++
tools/deploy_to_maven.sh | 4 +---
tools/travis_mvn_watchdog.sh | 19 ++++++++++++++++
6 files changed, 31 insertions(+), 31 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flink/blob/393612ba/.travis.yml
----------------------------------------------------------------------
diff --git a/.travis.yml b/.travis.yml
index 48d4913..3c4e10d 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -14,13 +14,13 @@ language: java
#See https://issues.apache.org/jira/browse/FLINK-1072
matrix:
include:
- - jdk: "openjdk6"
- env: PROFILE="-Dhadoop.profile=1"
- jdk: "oraclejdk7"
env: PROFILE="-Dhadoop.profile=1"
- - jdk: "openjdk6"
+ - jdk: "openjdk6" # this will also deploy a uberjar to s3 at some point
+ env: PROFILE="-Dhadoop.profile=1"
+ - jdk: "openjdk7"
env: PROFILE="-P!include-yarn -Dhadoop.version=2.0.0-alpha"
- - jdk: "oraclejdk7"
+ - jdk: "openjdk6" # we must use openjdk6 here to deploy a java6 compatible uber-jar for YARN
env: PROFILE="-Dhadoop.version=2.2.0"
- jdk: "oraclejdk8"
env: PROFILE="-Dhadoop.version=2.6.0"
http://git-wip-us.apache.org/repos/asf/flink/blob/393612ba/flink-dist/pom.xml
----------------------------------------------------------------------
diff --git a/flink-dist/pom.xml b/flink-dist/pom.xml
index 1ac8bea..af3b100 100644
--- a/flink-dist/pom.xml
+++ b/flink-dist/pom.xml
@@ -115,12 +115,6 @@ under the License.
<dependency>
<groupId>org.apache.flink</groupId>
- <artifactId>flink-streaming-connectors</artifactId>
- <version>${project.version}</version>
- </dependency>
-
- <dependency>
- <groupId>org.apache.flink</groupId>
<artifactId>flink-streaming-examples</artifactId>
<version>${project.version}</version>
</dependency>
@@ -236,23 +230,6 @@ under the License.
</profile>
<profile>
- <id>hadoop-2</id>
- <activation>
- <property>
- <!-- Please do not remove the 'hadoop2' comment. See ./tools/generate_specific_pom.sh -->
- <!--hadoop2--><name>!hadoop.profile</name>
- </property>
- </activation>
- <dependencies>
- <dependency>
- <groupId>org.apache.flink</groupId>
- <artifactId>flink-hbase</artifactId>
- <version>${project.version}</version>
- </dependency>
- </dependencies>
- </profile>
-
- <profile>
<id>debian-package</id>
<build>
<plugins>
http://git-wip-us.apache.org/repos/asf/flink/blob/393612ba/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/wordcount/WordCount.java
----------------------------------------------------------------------
diff --git a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/wordcount/WordCount.java b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/wordcount/WordCount.java
index 6be5368..07aa2ce 100644
--- a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/wordcount/WordCount.java
+++ b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/wordcount/WordCount.java
@@ -53,7 +53,8 @@ public class WordCount {
// *************************************************************************
public static void main(String[] args) throws Exception {
-
+
+
if(!parseParameters(args)) {
return;
}
http://git-wip-us.apache.org/repos/asf/flink/blob/393612ba/tools/create_release_files.sh
----------------------------------------------------------------------
diff --git a/tools/create_release_files.sh b/tools/create_release_files.sh
index 09b4e7a..c9b1aaa 100755
--- a/tools/create_release_files.sh
+++ b/tools/create_release_files.sh
@@ -28,6 +28,11 @@
#
# https://github.com/apache/spark/blob/master/dev/create-release/create-release.sh
#
+
+# Added by rmetzger
+echo "Please make sure to use java 6 OPENJDK (not oracle) to build the release binaries"
+exit 1
+
CURR_DIR=`pwd`
if [[ `basename $CURR_DIR` != "tools" ]] ; then
echo "You have to call the script from the tools/ dir"
http://git-wip-us.apache.org/repos/asf/flink/blob/393612ba/tools/deploy_to_maven.sh
----------------------------------------------------------------------
diff --git a/tools/deploy_to_maven.sh b/tools/deploy_to_maven.sh
index f4290af..d1f0001 100755
--- a/tools/deploy_to_maven.sh
+++ b/tools/deploy_to_maven.sh
@@ -27,9 +27,7 @@
# 4. deploy snapshot and s3 (hadoop2 - 2.2.0)
# 5. Nothing (hadoop2 - 2.5.1)
-# Changes (since travis changed the id assignment)
-# switched 2. with 3.
-# switched 5. with 6.
+
echo "install lifecylce mapping fake plugin"
git clone https://github.com/mfriedenhagen/dummy-lifecycle-mapping-plugin.git
http://git-wip-us.apache.org/repos/asf/flink/blob/393612ba/tools/travis_mvn_watchdog.sh
----------------------------------------------------------------------
diff --git a/tools/travis_mvn_watchdog.sh b/tools/travis_mvn_watchdog.sh
index e770a97..d94f977 100755
--- a/tools/travis_mvn_watchdog.sh
+++ b/tools/travis_mvn_watchdog.sh
@@ -179,5 +179,24 @@ rm $MVN_EXIT
upload_artifacts_s3
+# Check the number of files in the uber jar and fail the build if there are too many files (see: FLINK-1637)
+
+# since we are in flink/tools/artifacts
+# we are going back to
+cd ../../
+
+
+UBERJAR=`find . | grep uberjar | head -n 1`
+if [ -z "$UBERJAR" ] ; then
+ echo "Uberjar not found. Assuming failed build";
+else
+ jar tf $UBERJAR | wc -l > num_files_in_uberjar
+ NUM_FILES_IN_UBERJAR=`cat num_files_in_uberjar`
+ echo "Files in uberjar: $NUM_FILES_IN_UBERJAR. Uberjar: $UBERJAR"
+ if [ "$NUM_FILES_IN_UBERJAR" -ge "65536" ] ; then
+ echo "WARN: The number of files in the uberjar ($NUM_FILES_IN_UBERJAR) exceeds the maximum number of possible files for Java 6 (65536)"
+ fi
+fi
+
# Exit code for Travis build success/failure
exit $EXIT_CODE