flink-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mbala...@apache.org
Subject flink git commit: Fixed a few trivial issues:
Date Wed, 10 Jun 2015 09:40:32 GMT
Repository: flink
Updated Branches:
  refs/heads/release-0.9 e0e6f59f3 -> c59d291b1


Fixed a few trivial issues:

- The description of the input format for the graph examples
  showed an example input as having a newline at the end
  of the last line, but CsvInputFormat doesn't allow that
  (it says "Row too short" for the empty line).
- Fixed a link to local_execution.html in a javadoc.
- ConcatenatedExtract had a typo in its name.
- The creation of the jar for the SessionWindowing example was missing
  from the pom.

Closes #809


Project: http://git-wip-us.apache.org/repos/asf/flink/repo
Commit: http://git-wip-us.apache.org/repos/asf/flink/commit/c59d291b
Tree: http://git-wip-us.apache.org/repos/asf/flink/tree/c59d291b
Diff: http://git-wip-us.apache.org/repos/asf/flink/diff/c59d291b

Branch: refs/heads/release-0.9
Commit: c59d291b10f743beff58a70b5bfefc2d71dff234
Parents: e0e6f59
Author: Gabor Gevay <ggab90@gmail.com>
Authored: Tue Jun 9 15:10:35 2015 +0200
Committer: mbalassi <mbalassi@apache.org>
Committed: Wed Jun 10 11:40:06 2015 +0200

----------------------------------------------------------------------
 .../java/graph/ConnectedComponents.java         |  4 +-
 .../examples/java/graph/EnumTrianglesBasic.java |  2 +-
 .../examples/java/graph/EnumTrianglesOpt.java   |  2 +-
 .../examples/java/graph/PageRankBasic.java      |  4 +-
 .../java/misc/CollectionExecutionExample.java   |  2 +-
 .../scala/graph/ConnectedComponents.scala       |  4 +-
 .../scala/graph/EnumTrianglesBasic.scala        |  2 +-
 .../examples/scala/graph/EnumTrianglesOpt.scala |  2 +-
 .../examples/scala/graph/PageRankBasic.scala    |  4 +-
 .../extractor/ConcatenatedExtract.java          | 68 ++++++++++++++++
 .../extractor/ConcatinatedExtract.java          | 68 ----------------
 .../extractor/ConcatenatedExtractTest.java      | 77 ++++++++++++++++++
 .../extractor/ConcatinatedExtractTest.java      | 83 --------------------
 .../flink-streaming-examples/pom.xml            | 23 ++++++
 .../flink/examples/scala/PageRankTable.scala    |  4 +-
 15 files changed, 183 insertions(+), 166 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/ConnectedComponents.java
----------------------------------------------------------------------
diff --git a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/ConnectedComponents.java
b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/ConnectedComponents.java
index 56f98a7..535bf9d 100644
--- a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/ConnectedComponents.java
+++ b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/ConnectedComponents.java
@@ -55,10 +55,10 @@ import org.apache.flink.examples.java.graph.util.ConnectedComponentsData;
  * Input files are plain text files and must be formatted as follows:
  * <ul>
  * <li>Vertices represented as IDs and separated by new-line characters.<br>

- * For example <code>"1\n2\n12\n42\n63\n"</code> gives five vertices (1), (2),
(12), (42), and (63). 
+ * For example <code>"1\n2\n12\n42\n63"</code> gives five vertices (1), (2),
(12), (42), and (63).
  * <li>Edges are represented as pairs for vertex IDs which are separated by space 
  * characters. Edges are separated by new-line characters.<br>
- * For example <code>"1 2\n2 12\n1 12\n42 63\n"</code> gives four (undirected)
edges (1)-(2), (2)-(12), (1)-(12), and (42)-(63).
+ * For example <code>"1 2\n2 12\n1 12\n42 63"</code> gives four (undirected)
edges (1)-(2), (2)-(12), (1)-(12), and (42)-(63).
  * </ul>
  * 
  * <p>

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/EnumTrianglesBasic.java
----------------------------------------------------------------------
diff --git a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/EnumTrianglesBasic.java
b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/EnumTrianglesBasic.java
index 423edc7..c815ca4 100644
--- a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/EnumTrianglesBasic.java
+++ b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/EnumTrianglesBasic.java
@@ -50,7 +50,7 @@ import org.apache.flink.examples.java.graph.util.EnumTrianglesDataTypes.Triad;
  * <ul>
  * <li>Edges are represented as pairs for vertex IDs which are separated by space 
  * characters. Edges are separated by new-line characters.<br>
- * For example <code>"1 2\n2 12\n1 12\n42 63\n"</code> gives four (undirected)
edges (1)-(2), (2)-(12), (1)-(12), and (42)-(63)
+ * For example <code>"1 2\n2 12\n1 12\n42 63"</code> gives four (undirected)
edges (1)-(2), (2)-(12), (1)-(12), and (42)-(63)
  * that include a triangle
  * </ul>
  * <pre>

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/EnumTrianglesOpt.java
----------------------------------------------------------------------
diff --git a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/EnumTrianglesOpt.java
b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/EnumTrianglesOpt.java
index 56b448e..3937161 100644
--- a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/EnumTrianglesOpt.java
+++ b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/EnumTrianglesOpt.java
@@ -60,7 +60,7 @@ import org.apache.flink.examples.java.graph.util.EnumTrianglesDataTypes.Triad;
  * <ul>
  * <li>Edges are represented as pairs for vertex IDs which are separated by space 
  * characters. Edges are separated by new-line characters.<br>
- * For example <code>"1 2\n2 12\n1 12\n42 63\n"</code> gives four (undirected)
edges (1)-(2), (2)-(12), (1)-(12), and (42)-(63)
+ * For example <code>"1 2\n2 12\n1 12\n42 63"</code> gives four (undirected)
edges (1)-(2), (2)-(12), (1)-(12), and (42)-(63)
  * that include a triangle
  * </ul>
  * <pre>

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/PageRankBasic.java
----------------------------------------------------------------------
diff --git a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/PageRankBasic.java
b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/PageRankBasic.java
index a374d0c..f05a15d 100644
--- a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/PageRankBasic.java
+++ b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/graph/PageRankBasic.java
@@ -50,10 +50,10 @@ import org.apache.flink.examples.java.graph.util.PageRankData;
  * Input files are plain text files and must be formatted as follows:
  * <ul>
  * <li>Pages represented as an (long) ID separated by new-line characters.<br>

- * For example <code>"1\n2\n12\n42\n63\n"</code> gives five pages with IDs 1,
2, 12, 42, and 63.
+ * For example <code>"1\n2\n12\n42\n63"</code> gives five pages with IDs 1, 2,
12, 42, and 63.
  * <li>Links are represented as pairs of page IDs which are separated by space 
  * characters. Links are separated by new-line characters.<br>
- * For example <code>"1 2\n2 12\n1 12\n42 63\n"</code> gives four (directed)
links (1)->(2), (2)->(12), (1)->(12), and (42)->(63).<br>
+ * For example <code>"1 2\n2 12\n1 12\n42 63"</code> gives four (directed) links
(1)->(2), (2)->(12), (1)->(12), and (42)->(63).<br>
  * For this simple implementation it is required that each page has at least one incoming
and one outgoing link (a page can point to itself).
  * </ul>
  * 

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/misc/CollectionExecutionExample.java
----------------------------------------------------------------------
diff --git a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/misc/CollectionExecutionExample.java
b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/misc/CollectionExecutionExample.java
index 57ab3f6..e5b94e9 100644
--- a/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/misc/CollectionExecutionExample.java
+++ b/flink-examples/flink-java-examples/src/main/java/org/apache/flink/examples/java/misc/CollectionExecutionExample.java
@@ -31,7 +31,7 @@ import org.apache.flink.api.java.tuple.Tuple2;
  * DataSet transformations are executed on Java collections.
  * 
  * See the "Local Execution" section in the documentation for more details: 
- * 	http://flink.apache.org/docs/latest/local_execution.html
+ * 	http://flink.apache.org/docs/latest/apis/local_execution.html
  * 
  */
 public class CollectionExecutionExample {

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/ConnectedComponents.scala
----------------------------------------------------------------------
diff --git a/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/ConnectedComponents.scala
b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/ConnectedComponents.scala
index 9e23ed7..38c7f40 100644
--- a/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/ConnectedComponents.scala
+++ b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/ConnectedComponents.scala
@@ -39,9 +39,9 @@ import org.apache.flink.util.Collector
  * Input files are plain text files and must be formatted as follows:
  *
  *   - Vertices represented as IDs and separated by new-line characters. For example,
- *     `"1\n2\n12\n42\n63\n"` gives five vertices (1), (2), (12), (42), and (63).
+ *     `"1\n2\n12\n42\n63"` gives five vertices (1), (2), (12), (42), and (63).
  *   - Edges are represented as pairs for vertex IDs which are separated by space characters.
Edges
- *     are separated by new-line characters. For example `"1 2\n2 12\n1 12\n42 63\n"`
+ *     are separated by new-line characters. For example `"1 2\n2 12\n1 12\n42 63"`
  *     gives four (undirected) edges (1)-(2), (2)-(12), (1)-(12), and (42)-(63).
  *
  * Usage:

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/EnumTrianglesBasic.scala
----------------------------------------------------------------------
diff --git a/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/EnumTrianglesBasic.scala
b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/EnumTrianglesBasic.scala
index a9000b3..4c05fbb 100644
--- a/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/EnumTrianglesBasic.scala
+++ b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/EnumTrianglesBasic.scala
@@ -42,7 +42,7 @@ import scala.collection.mutable
  *
  *  - Edges are represented as pairs for vertex IDs which are separated by space
  *   characters. Edges are separated by new-line characters.
- *   For example `"1 2\n2 12\n1 12\n42 63\n"` gives four (undirected) edges (1)-(2), (2)-(12),
+ *   For example `"1 2\n2 12\n1 12\n42 63"` gives four (undirected) edges (1)-(2), (2)-(12),
  *   (1)-(12), and (42)-(63) that include a triangle
  *
  * <pre>

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/EnumTrianglesOpt.scala
----------------------------------------------------------------------
diff --git a/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/EnumTrianglesOpt.scala
b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/EnumTrianglesOpt.scala
index cc7c33f..ad7e3a4 100644
--- a/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/EnumTrianglesOpt.scala
+++ b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/EnumTrianglesOpt.scala
@@ -49,7 +49,7 @@ import scala.collection.mutable
  *
  *  - Edges are represented as pairs for vertex IDs which are separated by space
  *    characters. Edges are separated by new-line characters.
- *    For example `"1 2\n2 12\n1 12\n42 63\n"` gives four (undirected) edges (1)-(2), (2)-(12),
+ *    For example `"1 2\n2 12\n1 12\n42 63"` gives four (undirected) edges (1)-(2), (2)-(12),
  *    (1)-(12), and (42)-(63) that include a triangle
  *
  * <pre>

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/PageRankBasic.scala
----------------------------------------------------------------------
diff --git a/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/PageRankBasic.scala
b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/PageRankBasic.scala
index 5b5f6c2..e1d4af6 100644
--- a/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/PageRankBasic.scala
+++ b/flink-examples/flink-scala-examples/src/main/scala/org/apache/flink/examples/scala/graph/PageRankBasic.scala
@@ -44,10 +44,10 @@ import scala.collection.JavaConverters._
  * Input files are plain text files and must be formatted as follows:
  *
  *  - Pages represented as an (long) ID separated by new-line characters.
- *    For example `"1\n2\n12\n42\n63\n"` gives five pages with IDs 1, 2, 12, 42, and 63.
+ *    For example `"1\n2\n12\n42\n63"` gives five pages with IDs 1, 2, 12, 42, and 63.
  *  - Links are represented as pairs of page IDs which are separated by space  characters.
Links
  *    are separated by new-line characters.
- *    For example `"1 2\n2 12\n1 12\n42 63\n"` gives four (directed) links (1)->(2), (2)->(12),
+ *    For example `"1 2\n2 12\n1 12\n42 63"` gives four (directed) links (1)->(2), (2)->(12),
  *    (1)->(12), and (42)->(63). For this simple implementation it is required that
each page has
  *    at least one incoming and one outgoing link (a page can point to itself).
  *

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-staging/flink-streaming/flink-streaming-core/src/main/java/org/apache/flink/streaming/api/windowing/extractor/ConcatenatedExtract.java
----------------------------------------------------------------------
diff --git a/flink-staging/flink-streaming/flink-streaming-core/src/main/java/org/apache/flink/streaming/api/windowing/extractor/ConcatenatedExtract.java
b/flink-staging/flink-streaming/flink-streaming-core/src/main/java/org/apache/flink/streaming/api/windowing/extractor/ConcatenatedExtract.java
new file mode 100644
index 0000000..a220abe
--- /dev/null
+++ b/flink-staging/flink-streaming/flink-streaming-core/src/main/java/org/apache/flink/streaming/api/windowing/extractor/ConcatenatedExtract.java
@@ -0,0 +1,68 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.flink.streaming.api.windowing.extractor;
+
+/**
+ * Combines two extractors which will be executed one after each other.
+ *
+ * @param <FROM>
+ *            The input type of the first extractor.
+ * @param <OVER>
+ *            The output type of the first and the input type of the second
+ *            extractor.
+ * @param <TO>
+ *            The output type of the second extractor and the output type of the
+ *            over all extraction.
+ */
+public class ConcatenatedExtract<FROM, OVER, TO> implements Extractor<FROM, TO>
{
+
+	/**
+	 * auto-generated id
+	 */
+	private static final long serialVersionUID = -7807197760725651752L;
+
+	private Extractor<FROM, OVER> e1;
+	private Extractor<OVER, TO> e2;
+
+	/**
+	 * Combines two extractors which will be executed one after each other.
+	 * 
+	 * @param e1
+	 *            First extractor: This extractor gets applied to the input data
+	 *            first. Its output as then passed as input to the second
+	 *            extractor.
+	 * @param e2
+	 *            Second extractor: This extractor gets the output of the first
+	 *            extractor as input. Its output is then the result of the over
+	 *            all extraction.
+	 */
+	public ConcatenatedExtract(Extractor<FROM, OVER> e1, Extractor<OVER, TO> e2)
{
+		this.e1 = e1;
+		this.e2 = e2;
+	}
+
+	@Override
+	public TO extract(FROM in) {
+		return e2.extract(e1.extract(in));
+	}
+
+	public <OUT> ConcatenatedExtract<FROM, TO, OUT> add(Extractor<TO, OUT>
e3) {
+		return new ConcatenatedExtract<FROM, TO, OUT>(this, e3);
+	}
+
+}

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-staging/flink-streaming/flink-streaming-core/src/main/java/org/apache/flink/streaming/api/windowing/extractor/ConcatinatedExtract.java
----------------------------------------------------------------------
diff --git a/flink-staging/flink-streaming/flink-streaming-core/src/main/java/org/apache/flink/streaming/api/windowing/extractor/ConcatinatedExtract.java
b/flink-staging/flink-streaming/flink-streaming-core/src/main/java/org/apache/flink/streaming/api/windowing/extractor/ConcatinatedExtract.java
deleted file mode 100644
index 9048a3c..0000000
--- a/flink-staging/flink-streaming/flink-streaming-core/src/main/java/org/apache/flink/streaming/api/windowing/extractor/ConcatinatedExtract.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.flink.streaming.api.windowing.extractor;
-
-/**
- * Combines two extractors which will be executed one after each other.
- *
- * @param <FROM>
- *            The input type of the first extractor.
- * @param <OVER>
- *            The output type of the first and the input type of the second
- *            extractor.
- * @param <TO>
- *            The output type of the second extractor and the output type of the
- *            over all extraction.
- */
-public class ConcatinatedExtract<FROM, OVER, TO> implements Extractor<FROM, TO>
{
-
-	/**
-	 * auto-generated id
-	 */
-	private static final long serialVersionUID = -7807197760725651752L;
-
-	private Extractor<FROM, OVER> e1;
-	private Extractor<OVER, TO> e2;
-
-	/**
-	 * Combines two extractors which will be executed one after each other.
-	 * 
-	 * @param e1
-	 *            First extractor: This extractor gets applied to the input data
-	 *            first. Its output as then passed as input to the second
-	 *            extractor.
-	 * @param e2
-	 *            Second extractor: This extractor gets the output of the first
-	 *            extractor as input. Its output is then the result of the over
-	 *            all extraction.
-	 */
-	public ConcatinatedExtract(Extractor<FROM, OVER> e1, Extractor<OVER, TO> e2)
{
-		this.e1 = e1;
-		this.e2 = e2;
-	}
-
-	@Override
-	public TO extract(FROM in) {
-		return e2.extract(e1.extract(in));
-	}
-
-	public <OUT> ConcatinatedExtract<FROM, TO, OUT> add(Extractor<TO, OUT>
e3) {
-		return new ConcatinatedExtract<FROM, TO, OUT>(this, e3);
-	}
-
-}

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-staging/flink-streaming/flink-streaming-core/src/test/java/org/apache/flink/streaming/api/windowing/extractor/ConcatenatedExtractTest.java
----------------------------------------------------------------------
diff --git a/flink-staging/flink-streaming/flink-streaming-core/src/test/java/org/apache/flink/streaming/api/windowing/extractor/ConcatenatedExtractTest.java
b/flink-staging/flink-streaming/flink-streaming-core/src/test/java/org/apache/flink/streaming/api/windowing/extractor/ConcatenatedExtractTest.java
new file mode 100644
index 0000000..e99de38
--- /dev/null
+++ b/flink-staging/flink-streaming/flink-streaming-core/src/test/java/org/apache/flink/streaming/api/windowing/extractor/ConcatenatedExtractTest.java
@@ -0,0 +1,77 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.flink.streaming.api.windowing.extractor;
+
+import static org.junit.Assert.*;
+
+import org.apache.flink.api.java.tuple.Tuple2;
+import org.junit.Before;
+import org.junit.Test;
+
+public class ConcatenatedExtractTest {
+
+	private String[] testStringArray1 = { "1", "2", "3" };
+	private int[] testIntArray1 = { 1, 2, 3 };
+	private String[] testStringArray2 = { "4", "5", "6" };
+	private int[] testIntArray2 = { 4, 5, 6 };
+	private String[] testStringArray3 = { "7", "8", "9" };
+	private int[] testIntArray3 = { 7, 8, 9 };
+	private Tuple2<String[], int[]>[] testTuple2Array;
+	private Tuple2<String[], int[]> testTuple2;
+	private Tuple2<Tuple2<String[], int[]>, Tuple2<String[], int[]>[]> testData;
+
+	@SuppressWarnings("unchecked")
+	@Before
+	public void setupData() {
+		testTuple2Array = new Tuple2[2];
+		testTuple2Array[0] = new Tuple2<String[], int[]>(testStringArray1, testIntArray2);
+		testTuple2Array[1] = new Tuple2<String[], int[]>(testStringArray2, testIntArray1);
+
+		testTuple2 = new Tuple2<String[], int[]>(testStringArray3, testIntArray3);
+
+		testData = new Tuple2<Tuple2<String[], int[]>, Tuple2<String[], int[]>[]>(testTuple2,
+				testTuple2Array);
+	}
+
+	@SuppressWarnings({ "rawtypes", "unchecked" })
+	@Test
+	public void test1() {
+		Extractor ext = new ConcatenatedExtract(new FieldFromTuple(0), new FieldFromTuple(1))
+				.add(new FieldsFromArray(Integer.class, 2, 1, 0));
+		int[] expected = { testIntArray3[2], testIntArray3[1], testIntArray3[0] };
+		assertEquals(new Integer(expected[0]), ((Integer[]) ext.extract(testData))[0]);
+		assertEquals(new Integer(expected[1]), ((Integer[]) ext.extract(testData))[1]);
+		assertEquals(new Integer(expected[2]), ((Integer[]) ext.extract(testData))[2]);
+	}
+
+	@SuppressWarnings({ "unchecked", "rawtypes" })
+	@Test
+	public void test2() {
+		Extractor ext = new ConcatenatedExtract(new FieldFromTuple(1), // Tuple2<String[],int[]>[]
+				new FieldsFromArray(Tuple2.class, 1)) // Tuple2<String[],int[]>[]
+				.add(new FieldFromArray(0)) // Tuple2<String[],int[]>
+				.add(new ArrayFromTuple(0)) // Object[] (Containing String[])
+				.add(new FieldFromArray(0)) // String[]
+				.add(new FieldFromArray(1)); // String
+
+		String expected2 = testStringArray2[1];
+		assertEquals(expected2, ext.extract(testData));
+
+	}
+
+}

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-staging/flink-streaming/flink-streaming-core/src/test/java/org/apache/flink/streaming/api/windowing/extractor/ConcatinatedExtractTest.java
----------------------------------------------------------------------
diff --git a/flink-staging/flink-streaming/flink-streaming-core/src/test/java/org/apache/flink/streaming/api/windowing/extractor/ConcatinatedExtractTest.java
b/flink-staging/flink-streaming/flink-streaming-core/src/test/java/org/apache/flink/streaming/api/windowing/extractor/ConcatinatedExtractTest.java
deleted file mode 100644
index 82a876a..0000000
--- a/flink-staging/flink-streaming/flink-streaming-core/src/test/java/org/apache/flink/streaming/api/windowing/extractor/ConcatinatedExtractTest.java
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.flink.streaming.api.windowing.extractor;
-
-import static org.junit.Assert.*;
-
-import org.apache.flink.api.java.tuple.Tuple2;
-import org.apache.flink.streaming.api.windowing.extractor.ArrayFromTuple;
-import org.apache.flink.streaming.api.windowing.extractor.ConcatinatedExtract;
-import org.apache.flink.streaming.api.windowing.extractor.Extractor;
-import org.apache.flink.streaming.api.windowing.extractor.FieldFromArray;
-import org.apache.flink.streaming.api.windowing.extractor.FieldFromTuple;
-import org.apache.flink.streaming.api.windowing.extractor.FieldsFromArray;
-import org.junit.Before;
-import org.junit.Test;
-
-public class ConcatinatedExtractTest {
-
-	private String[] testStringArray1 = { "1", "2", "3" };
-	private int[] testIntArray1 = { 1, 2, 3 };
-	private String[] testStringArray2 = { "4", "5", "6" };
-	private int[] testIntArray2 = { 4, 5, 6 };
-	private String[] testStringArray3 = { "7", "8", "9" };
-	private int[] testIntArray3 = { 7, 8, 9 };
-	private Tuple2<String[], int[]>[] testTuple2Array;
-	private Tuple2<String[], int[]> testTuple2;
-	private Tuple2<Tuple2<String[], int[]>, Tuple2<String[], int[]>[]> testData;
-
-	@SuppressWarnings("unchecked")
-	@Before
-	public void setupData() {
-		testTuple2Array = new Tuple2[2];
-		testTuple2Array[0] = new Tuple2<String[], int[]>(testStringArray1, testIntArray2);
-		testTuple2Array[1] = new Tuple2<String[], int[]>(testStringArray2, testIntArray1);
-
-		testTuple2 = new Tuple2<String[], int[]>(testStringArray3, testIntArray3);
-
-		testData = new Tuple2<Tuple2<String[], int[]>, Tuple2<String[], int[]>[]>(testTuple2,
-				testTuple2Array);
-	}
-
-	@SuppressWarnings({ "rawtypes", "unchecked" })
-	@Test
-	public void test1() {
-		Extractor ext = new ConcatinatedExtract(new FieldFromTuple(0), new FieldFromTuple(1))
-				.add(new FieldsFromArray(Integer.class, 2, 1, 0));
-		int[] expected = { testIntArray3[2], testIntArray3[1], testIntArray3[0] };
-		assertEquals(new Integer(expected[0]), ((Integer[]) ext.extract(testData))[0]);
-		assertEquals(new Integer(expected[1]), ((Integer[]) ext.extract(testData))[1]);
-		assertEquals(new Integer(expected[2]), ((Integer[]) ext.extract(testData))[2]);
-	}
-
-	@SuppressWarnings({ "unchecked", "rawtypes" })
-	@Test
-	public void test2() {
-		Extractor ext = new ConcatinatedExtract(new FieldFromTuple(1), // Tuple2<String[],int[]>[]
-				new FieldsFromArray(Tuple2.class, 1)) // Tuple2<String[],int[]>[]
-				.add(new FieldFromArray(0)) // Tuple2<String[],int[]>
-				.add(new ArrayFromTuple(0)) // Object[] (Containing String[])
-				.add(new FieldFromArray(0)) // String[]
-				.add(new FieldFromArray(1)); // String
-
-		String expected2 = testStringArray2[1];
-		assertEquals(expected2, ext.extract(testData));
-
-	}
-
-}

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-staging/flink-streaming/flink-streaming-examples/pom.xml
----------------------------------------------------------------------
diff --git a/flink-staging/flink-streaming/flink-streaming-examples/pom.xml b/flink-staging/flink-streaming/flink-streaming-examples/pom.xml
index 531cb4e..77eb00f 100644
--- a/flink-staging/flink-streaming/flink-streaming-examples/pom.xml
+++ b/flink-staging/flink-streaming/flink-streaming-examples/pom.xml
@@ -337,6 +337,29 @@ under the License.
 						</configuration>
 					</execution>
 
+					<!-- SessionWindowing -->
+					<execution>
+						<id>SessionWindowing</id>
+						<phase>package</phase>
+						<goals>
+							<goal>jar</goal>
+						</goals>
+						<configuration>
+							<classifier>SessionWindowing</classifier>
+
+							<archive>
+								<manifestEntries>
+									<program-class>org.apache.flink.streaming.examples.windowing.SessionWindowing</program-class>
+								</manifestEntries>
+							</archive>
+
+							<includes>
+								<include>org/apache/flink/streaming/examples/windowing/SessionWindowing.class</include>
+								<include>org/apache/flink/streaming/examples/windowing/SessionWindowing$*.class</include>
+							</includes>
+						</configuration>
+					</execution>
+
 				</executions>
 			</plugin>
 

http://git-wip-us.apache.org/repos/asf/flink/blob/c59d291b/flink-staging/flink-table/src/main/scala/org/apache/flink/examples/scala/PageRankTable.scala
----------------------------------------------------------------------
diff --git a/flink-staging/flink-table/src/main/scala/org/apache/flink/examples/scala/PageRankTable.scala
b/flink-staging/flink-table/src/main/scala/org/apache/flink/examples/scala/PageRankTable.scala
index d944bab..7a26e0e 100644
--- a/flink-staging/flink-table/src/main/scala/org/apache/flink/examples/scala/PageRankTable.scala
+++ b/flink-staging/flink-table/src/main/scala/org/apache/flink/examples/scala/PageRankTable.scala
@@ -42,10 +42,10 @@ import _root_.scala.collection.JavaConverters._
 * Input files are plain text files and must be formatted as follows:
 *
 *  - Pages represented as an (long) ID separated by new-line characters.
-*    For example `"1\n2\n12\n42\n63\n"` gives five pages with IDs 1, 2, 12, 42, and 63.
+*    For example `"1\n2\n12\n42\n63"` gives five pages with IDs 1, 2, 12, 42, and 63.
 *  - Links are represented as pairs of page IDs which are separated by space  characters.
Links
 *    are separated by new-line characters.
-*    For example `"1 2\n2 12\n1 12\n42 63\n"` gives four (directed) links (1)->(2), (2)->(12),
+*    For example `"1 2\n2 12\n1 12\n42 63"` gives four (directed) links (1)->(2), (2)->(12),
 *    (1)->(12), and (42)->(63). For this simple implementation it is required that
each page has
 *    at least one incoming and one outgoing link (a page can point to itself).
 *


Mime
View raw message