You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2018/10/16 19:57:59 UTC

[GitHub] zentol closed pull request #6080: [FLINK-9443]Remove unused parameter in generateNodeLocalHash

zentol closed pull request #6080: [FLINK-9443]Remove unused parameter in generateNodeLocalHash
URL: https://github.com/apache/flink/pull/6080
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/flink-streaming-java/src/main/java/org/apache/flink/streaming/api/graph/StreamGraphHasherV2.java b/flink-streaming-java/src/main/java/org/apache/flink/streaming/api/graph/StreamGraphHasherV2.java
index 9bbcec0c091..d7c51bcbdeb 100644
--- a/flink-streaming-java/src/main/java/org/apache/flink/streaming/api/graph/StreamGraphHasherV2.java
+++ b/flink-streaming-java/src/main/java/org/apache/flink/streaming/api/graph/StreamGraphHasherV2.java
@@ -67,7 +67,7 @@
 	 *
 	 * <p>The generated hash is deterministic with respect to:
 	 * <ul>
-	 *   <li>node-local properties (like parallelism, UDF, node ID),
+	 *   <li>node-local properties (node ID),
 	 *   <li>chained output nodes, and
 	 *   <li>input nodes hashes
 	 * </ul>
@@ -216,16 +216,15 @@ private boolean generateNodeHash(
 		// hashes as the ID. We cannot use the node's ID, because it is
 		// assigned from a static counter. This will result in two identical
 		// programs having different hashes.
-		generateNodeLocalHash(node, hasher, hashes.size());
+		generateNodeLocalHash(hasher, hashes.size());
 
 		// Include chained nodes to hash
 		for (StreamEdge outEdge : node.getOutEdges()) {
 			if (isChainable(outEdge, isChainingEnabled)) {
-				StreamNode chainedNode = outEdge.getTargetVertex();
 
 				// Use the hash size again, because the nodes are chained to
 				// this node. This does not add a hash for the chained nodes.
-				generateNodeLocalHash(chainedNode, hasher, hashes.size());
+				generateNodeLocalHash(hasher, hashes.size());
 			}
 		}
 
@@ -265,15 +264,14 @@ private boolean generateNodeHash(
 	}
 
 	/**
-	 * Applies the {@link Hasher} to the {@link StreamNode} (only node local
-	 * attributes are taken into account). The hasher encapsulates the current
-	 * state of the hash.
+	 * Applies the {@link Hasher} to the {@link StreamNode} . The hasher encapsulates
+	 * the current state of the hash.
 	 *
 	 * <p>The specified ID is local to this node. We cannot use the
 	 * {@link StreamNode#id}, because it is incremented in a static counter.
 	 * Therefore, the IDs for identical jobs will otherwise be different.
 	 */
-	private void generateNodeLocalHash(StreamNode node, Hasher hasher, int id) {
+	private void generateNodeLocalHash(Hasher hasher, int id) {
 		// This resolves conflicts for otherwise identical source nodes. BUT
 		// the generated hash codes depend on the ordering of the nodes in the
 		// stream graph.


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services