GitHub PullRequestReviewCommentEvent at 2014-09-11 09:39:50
Repository: akka
Actor: rkuhn
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/akka/akka/pulls/comments/17412195","id":17412195,"diff_hunk":"@@ -223,6 +229,17 @@ class FlowGraphBuilder private (graph: Graph[FlowGraphInternal.Vertex, LDiEdge])\n     this\n   }\n \n+  private def addGraphEdge[In, Out](from: Vertex, to: Vertex, flow: ProcessorFlow[In, Out]): Unit = {\n+    @tailrec def tryAdd(i: Int): Unit = {\n+      if (i == Int.MaxValue) throw new IllegalArgumentException(s\"Too many edges $from ~> $to\")\n+      val label = EdgeLabel(i)(flow.asInstanceOf[ProcessorFlow[Any, Any]])\n+      if (!graph.addLEdge(from, to)(label))\n+        tryAdd(i + 1) // existing edge from ~> to\n+    }\n+\n+    tryAdd(0)","path":"akka-stream/src/main/scala/akka/stream/scaladsl2/FlowGraph.scala","position":100,"original_position":100,"commit_id":"c7271c4ad7ea2f62dd25f835e6796f524e99270f","original_commit_id":"c7271c4ad7ea2f62dd25f835e6796f524e99270f","user":{"login":"rkuhn","id":470469,"avatar_url":"https://avatars.githubusercontent.com/u/470469?v=2","gravatar_id":"262b1ab25e66b1e15a48fa3f68703aad","url":"https://api.github.com/users/rkuhn","html_url":"https://github.com/rkuhn","followers_url":"https://api.github.com/users/rkuhn/followers","following_url":"https://api.github.com/users/rkuhn/following{/other_user}","gists_url":"https://api.github.com/users/rkuhn/gists{/gist_id}","starred_url":"https://api.github.com/users/rkuhn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rkuhn/subscriptions","organizations_url":"https://api.github.com/users/rkuhn/orgs","repos_url":"https://api.github.com/users/rkuhn/repos","events_url":"https://api.github.com/users/rkuhn/events{/privacy}","received_events_url":"https://api.github.com/users/rkuhn/received_events","type":"User","site_admin":false},"body":"even if so, we could cache the result of this loop for this particular pair of vertices in this builder","created_at":"2014-09-11T09:39:50Z","updated_at":"2014-09-11T09:39:50Z","html_url":"https://github.com/akka/akka/pull/15855#discussion_r17412195","pull_request_url":"https://api.github.com/repos/akka/akka/pulls/15855","_links":{"self":{"href":"https://api.github.com/repos/akka/akka/pulls/comments/17412195"},"html":{"href":"https://github.com/akka/akka/pull/15855#discussion_r17412195"},"pull_request":{"href":"https://api.github.com/repos/akka/akka/pulls/15855"}}},"pull_request":{"url":"https://api.github.com/repos/akka/akka/pulls/15855","id":21068782,"html_url":"https://github.com/akka/akka/pull/15855","diff_url":"https://github.com/akka/akka/pull/15855.diff","patch_url":"https://github.com/akka/akka/pull/15855.patch","issue_url":"https://api.github.com/repos/akka/akka/issues/15855","number":15855,"state":"open","locked":false,"title":"=str #15844 Use key labeled edges to support multiple edges between same vertices","user":{"login":"patriknw","id":336161,"avatar_url":"https://avatars.githubusercontent.com/u/336161?v=2","gravatar_id":"a036dbdf494ae4c9d46e1d24b53fd5da","url":"https://api.github.com/users/patriknw","html_url":"https://github.com/patriknw","followers_url":"https://api.github.com/users/patriknw/followers","following_url":"https://api.github.com/users/patriknw/following{/other_user}","gists_url":"https://api.github.com/users/patriknw/gists{/gist_id}","starred_url":"https://api.github.com/users/patriknw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/patriknw/subscriptions","organizations_url":"https://api.github.com/users/patriknw/orgs","repos_url":"https://api.github.com/users/patriknw/repos","events_url":"https://api.github.com/users/patriknw/events{/privacy}","received_events_url":"https://api.github.com/users/patriknw/received_events","type":"User","site_admin":false},"body":"@rkuhn @drewhk The whole purpose of [key-labeled](http://www.scala-graph.org/guides/core-initializing.html) edges is this, of course. Sorry that I didn't realize immediately.\r\n\r\nWhen using `LkDiEdge` the edge label (equals/hashCode) will part of the edge identity.","created_at":"2014-09-11T06:29:48Z","updated_at":"2014-09-11T09:39:50Z","closed_at":null,"merged_at":null,"merge_commit_sha":"18473df97dd2cf364816c1fb1cfff1763e7192c4","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/akka/akka/pulls/15855/commits","review_comments_url":"https://api.github.com/repos/akka/akka/pulls/15855/comments","review_comment_url":"https://api.github.com/repos/akka/akka/pulls/comments/{number}","comments_url":"https://api.github.com/repos/akka/akka/issues/15855/comments","statuses_url":"https://api.github.com/repos/akka/akka/statuses/c7271c4ad7ea2f62dd25f835e6796f524e99270f","head":{"label":"akka:wip-15844-key-label-edge-patriknw","ref":"wip-15844-key-label-edge-patriknw","sha":"c7271c4ad7ea2f62dd25f835e6796f524e99270f","user":{"login":"akka","id":1496237,"avatar_url":"https://avatars.githubusercontent.com/u/1496237?v=2","gravatar_id":"0ff72320fb1bc5db35ba4fae61614eb0","url":"https://api.github.com/users/akka","html_url":"https://github.com/akka","followers_url":"https://api.github.com/users/akka/followers","following_url":"https://api.github.com/users/akka/following{/other_user}","gists_url":"https://api.github.com/users/akka/gists{/gist_id}","starred_url":"https://api.github.com/users/akka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akka/subscriptions","organizations_url":"https://api.github.com/users/akka/orgs","repos_url":"https://api.github.com/users/akka/repos","events_url":"https://api.github.com/users/akka/events{/privacy}","received_events_url":"https://api.github.com/users/akka/received_events","type":"Organization","site_admin":false},"repo":{"id":130013,"name":"akka","full_name":"akka/akka","owner":{"login":"akka","id":1496237,"avatar_url":"https://avatars.githubusercontent.com/u/1496237?v=2","gravatar_id":"0ff72320fb1bc5db35ba4fae61614eb0","url":"https://api.github.com/users/akka","html_url":"https://github.com/akka","followers_url":"https://api.github.com/users/akka/followers","following_url":"https://api.github.com/users/akka/following{/other_user}","gists_url":"https://api.github.com/users/akka/gists{/gist_id}","starred_url":"https://api.github.com/users/akka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akka/subscriptions","organizations_url":"https://api.github.com/users/akka/orgs","repos_url":"https://api.github.com/users/akka/repos","events_url":"https://api.github.com/users/akka/events{/privacy}","received_events_url":"https://api.github.com/users/akka/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/akka/akka","description":"Akka Project","fork":false,"url":"https://api.github.com/repos/akka/akka","forks_url":"https://api.github.com/repos/akka/akka/forks","keys_url":"https://api.github.com/repos/akka/akka/keys{/key_id}","collaborators_url":"https://api.github.com/repos/akka/akka/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/akka/akka/teams","hooks_url":"https://api.github.com/repos/akka/akka/hooks","issue_events_url":"https://api.github.com/repos/akka/akka/issues/events{/number}","events_url":"https://api.github.com/repos/akka/akka/events","assignees_url":"https://api.github.com/repos/akka/akka/assignees{/user}","branches_url":"https://api.github.com/repos/akka/akka/branches{/branch}","tags_url":"https://api.github.com/repos/akka/akka/tags","blobs_url":"https://api.github.com/repos/akka/akka/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/akka/akka/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/akka/akka/git/refs{/sha}","trees_url":"https://api.github.com/repos/akka/akka/git/trees{/sha}","statuses_url":"https://api.github.com/repos/akka/akka/statuses/{sha}","languages_url":"https://api.github.com/repos/akka/akka/languages","stargazers_url":"https://api.github.com/repos/akka/akka/stargazers","contributors_url":"https://api.github.com/repos/akka/akka/contributors","subscribers_url":"https://api.github.com/repos/akka/akka/subscribers","subscription_url":"https://api.github.com/repos/akka/akka/subscription","commits_url":"https://api.github.com/repos/akka/akka/commits{/sha}","git_commits_url":"https://api.github.com/repos/akka/akka/git/commits{/sha}","comments_url":"https://api.github.com/repos/akka/akka/comments{/number}","issue_comment_url":"https://api.github.com/repos/akka/akka/issues/comments/{number}","contents_url":"https://api.github.com/repos/akka/akka/contents/{+path}","compare_url":"https://api.github.com/repos/akka/akka/compare/{base}...{head}","merges_url":"https://api.github.com/repos/akka/akka/merges","archive_url":"https://api.github.com/repos/akka/akka/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/akka/akka/downloads","issues_url":"https://api.github.com/repos/akka/akka/issues{/number}","pulls_url":"https://api.github.com/repos/akka/akka/pulls{/number}","milestones_url":"https://api.github.com/repos/akka/akka/milestones{/number}","notifications_url":"https://api.github.com/repos/akka/akka/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/akka/akka/labels{/name}","releases_url":"https://api.github.com/repos/akka/akka/releases{/id}","created_at":"2009-02-16T12:51:54Z","updated_at":"2014-09-11T08:29:29Z","pushed_at":"2014-09-11T09:37:36Z","git_url":"git://github.com/akka/akka.git","ssh_url":"git@github.com:akka/akka.git","clone_url":"https://github.com/akka/akka.git","svn_url":"https://github.com/akka/akka","homepage":"http://akka.io","size":229269,"stargazers_count":2966,"watchers_count":2966,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":false,"forks_count":799,"mirror_url":null,"open_issues_count":405,"forks":799,"open_issues":405,"watchers":2966,"default_branch":"master"}},"base":{"label":"akka:release-2.3-dev","ref":"release-2.3-dev","sha":"9ed94601806335a211668c4e2ed51d07c0654454","user":{"login":"akka","id":1496237,"avatar_url":"https://avatars.githubusercontent.com/u/1496237?v=2","gravatar_id":"0ff72320fb1bc5db35ba4fae61614eb0","url":"https://api.github.com/users/akka","html_url":"https://github.com/akka","followers_url":"https://api.github.com/users/akka/followers","following_url":"https://api.github.com/users/akka/following{/other_user}","gists_url":"https://api.github.com/users/akka/gists{/gist_id}","starred_url":"https://api.github.com/users/akka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akka/subscriptions","organizations_url":"https://api.github.com/users/akka/orgs","repos_url":"https://api.github.com/users/akka/repos","events_url":"https://api.github.com/users/akka/events{/privacy}","received_events_url":"https://api.github.com/users/akka/received_events","type":"Organization","site_admin":false},"repo":{"id":130013,"name":"akka","full_name":"akka/akka","owner":{"login":"akka","id":1496237,"avatar_url":"https://avatars.githubusercontent.com/u/1496237?v=2","gravatar_id":"0ff72320fb1bc5db35ba4fae61614eb0","url":"https://api.github.com/users/akka","html_url":"https://github.com/akka","followers_url":"https://api.github.com/users/akka/followers","following_url":"https://api.github.com/users/akka/following{/other_user}","gists_url":"https://api.github.com/users/akka/gists{/gist_id}","starred_url":"https://api.github.com/users/akka/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akka/subscriptions","organizations_url":"https://api.github.com/users/akka/orgs","repos_url":"https://api.github.com/users/akka/repos","events_url":"https://api.github.com/users/akka/events{/privacy}","received_events_url":"https://api.github.com/users/akka/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/akka/akka","description":"Akka Project","fork":false,"url":"https://api.github.com/repos/akka/akka","forks_url":"https://api.github.com/repos/akka/akka/forks","keys_url":"https://api.github.com/repos/akka/akka/keys{/key_id}","collaborators_url":"https://api.github.com/repos/akka/akka/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/akka/akka/teams","hooks_url":"https://api.github.com/repos/akka/akka/hooks","issue_events_url":"https://api.github.com/repos/akka/akka/issues/events{/number}","events_url":"https://api.github.com/repos/akka/akka/events","assignees_url":"https://api.github.com/repos/akka/akka/assignees{/user}","branches_url":"https://api.github.com/repos/akka/akka/branches{/branch}","tags_url":"https://api.github.com/repos/akka/akka/tags","blobs_url":"https://api.github.com/repos/akka/akka/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/akka/akka/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/akka/akka/git/refs{/sha}","trees_url":"https://api.github.com/repos/akka/akka/git/trees{/sha}","statuses_url":"https://api.github.com/repos/akka/akka/statuses/{sha}","languages_url":"https://api.github.com/repos/akka/akka/languages","stargazers_url":"https://api.github.com/repos/akka/akka/stargazers","contributors_url":"https://api.github.com/repos/akka/akka/contributors","subscribers_url":"https://api.github.com/repos/akka/akka/subscribers","subscription_url":"https://api.github.com/repos/akka/akka/subscription","commits_url":"https://api.github.com/repos/akka/akka/commits{/sha}","git_commits_url":"https://api.github.com/repos/akka/akka/git/commits{/sha}","comments_url":"https://api.github.com/repos/akka/akka/comments{/number}","issue_comment_url":"https://api.github.com/repos/akka/akka/issues/comments/{number}","contents_url":"https://api.github.com/repos/akka/akka/contents/{+path}","compare_url":"https://api.github.com/repos/akka/akka/compare/{base}...{head}","merges_url":"https://api.github.com/repos/akka/akka/merges","archive_url":"https://api.github.com/repos/akka/akka/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/akka/akka/downloads","issues_url":"https://api.github.com/repos/akka/akka/issues{/number}","pulls_url":"https://api.github.com/repos/akka/akka/pulls{/number}","milestones_url":"https://api.github.com/repos/akka/akka/milestones{/number}","notifications_url":"https://api.github.com/repos/akka/akka/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/akka/akka/labels{/name}","releases_url":"https://api.github.com/repos/akka/akka/releases{/id}","created_at":"2009-02-16T12:51:54Z","updated_at":"2014-09-11T08:29:29Z","pushed_at":"2014-09-11T09:37:36Z","git_url":"git://github.com/akka/akka.git","ssh_url":"git@github.com:akka/akka.git","clone_url":"https://github.com/akka/akka.git","svn_url":"https://github.com/akka/akka","homepage":"http://akka.io","size":229269,"stargazers_count":2966,"watchers_count":2966,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":false,"forks_count":799,"mirror_url":null,"open_issues_count":405,"forks":799,"open_issues":405,"watchers":2966,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/akka/akka/pulls/15855"},"html":{"href":"https://github.com/akka/akka/pull/15855"},"issue":{"href":"https://api.github.com/repos/akka/akka/issues/15855"},"comments":{"href":"https://api.github.com/repos/akka/akka/issues/15855/comments"},"review_comments":{"href":"https://api.github.com/repos/akka/akka/pulls/15855/comments"},"review_comment":{"href":"https://api.github.com/repos/akka/akka/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/akka/akka/pulls/15855/commits"},"statuses":{"href":"https://api.github.com/repos/akka/akka/statuses/c7271c4ad7ea2f62dd25f835e6796f524e99270f"}}}}