Github user manuzhang commented on a diff in the pull request: https://github.com/apache/incubator-gearpump/pull/223#discussion_r139061587 --- Diff: core/src/main/scala/org/apache/gearpump/util/Graph.scala --- @@ -243,13 +258,36 @@ class Graph[N, E](vertexList: List[N], edgeList: List[(N, E, N)]) extends Serial * The node returned by Iterator is stable sorted. */ def topologicalOrderIterator: Iterator[N] = { - val newGraph = copy - var output = List.empty[N] + tryTopologicalOrderIterator match { + case Success(intertor) => intertor --- End diff -- intertor ?
---