[FLINK-1201] [gelly] replaced create with fromDataSet

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

Branch: refs/heads/master
Commit: f99691c02b1b260798e458e281cc56902f160204
Parents: ac477e8
Author: vasia <vasilikikala...@gmail.com>
Authored: Mon Jan 19 17:38:20 2015 +0100
Committer: Stephan Ewen <se...@apache.org>
Committed: Wed Feb 11 10:46:15 2015 +0100

----------------------------------------------------------------------
 .../org/apache/flink/graph/example/LabelPropagationExample.java  | 2 +-
 .../main/java/org/apache/flink/graph/example/MusicProfiles.java  | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flink/blob/f99691c0/flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/example/LabelPropagationExample.java
----------------------------------------------------------------------
diff --git 
a/flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/example/LabelPropagationExample.java
 
b/flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/example/LabelPropagationExample.java
index 7acabb9..50c9ae5 100644
--- 
a/flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/example/LabelPropagationExample.java
+++ 
b/flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/example/LabelPropagationExample.java
@@ -26,7 +26,7 @@ public class LabelPropagationExample implements 
ProgramDescription {
         DataSet<Vertex<Long, Long>> vertices = getVertexDataSet(env);
         DataSet<Edge<Long, NullValue>> edges = getEdgeDataSet(env);
 
-        Graph<Long, Long, NullValue> graph = new Graph<Long, Long, 
NullValue>(vertices, edges, env);
+        Graph<Long, Long, NullValue> graph = Graph.fromDataSet(vertices, 
edges, env);
 
         DataSet<Vertex<Long, Long>> verticesWithCommunity =
                 graph.run(new 
LabelPropagation<Long>(maxIterations)).getVertices();

http://git-wip-us.apache.org/repos/asf/flink/blob/f99691c0/flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/example/MusicProfiles.java
----------------------------------------------------------------------
diff --git 
a/flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/example/MusicProfiles.java
 
b/flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/example/MusicProfiles.java
index 91830a4..44f226f 100644
--- 
a/flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/example/MusicProfiles.java
+++ 
b/flink-staging/flink-gelly/src/main/java/org/apache/flink/graph/example/MusicProfiles.java
@@ -69,7 +69,7 @@ public class MusicProfiles implements ProgramDescription {
         */
        DataSet<Edge<String, Integer>> userSongEdges = validTriplets.map(new 
Tuple3ToEdgeMap<String, Integer>());
 
-       Graph<String, NullValue, Integer> userSongGraph = 
Graph.create(userSongEdges, env);
+       Graph<String, NullValue, Integer> userSongGraph = 
Graph.fromDataSet(userSongEdges, env);
 
        /**
         *  Get the top track (most listened) for each user
@@ -87,7 +87,7 @@ public class MusicProfiles implements ProgramDescription {
        DataSet<Edge<String, NullValue>> similarUsers = 
userSongGraph.getEdges().groupBy(1)
                        .reduceGroup(new CreateSimilarUserEdges()).distinct();
 
-       Graph<String, Long, NullValue> similarUsersGraph = 
Graph.create(similarUsers,
+       Graph<String, Long, NullValue> similarUsersGraph = 
Graph.fromDataSet(similarUsers,
 
                        new MapFunction<String, Long>() {
                                        public Long map(String value) { return 
1l; }

Reply via email to