{"action":"created","comment":{"url":"https://api.github.com/repos/apache/spark/pulls/comments/31828705","id":31828705,"diff_hunk":"@@ -214,8 +213,10 @@ private[spark] class AkkaRpcEnv private[akka] (\n \n   override def asyncSetupEndpointRefByURI(uri: String): Future[RpcEndpointRef] = {\n     import actorSystem.dispatcher\n-    actorSystem.actorSelection(uri).resolveOne(defaultLookupTimeout).\n-      map(new AkkaRpcEndpointRef(defaultAddress, _, conf))\n+    defaultLookupTimeout.addMessageIfTimeout(\n+      actorSystem.actorSelection(uri).resolveOne(_).\n+        map(new AkkaRpcEndpointRef(defaultAddress, _, conf))\n+    )","path":"core/src/main/scala/org/apache/spark/rpc/akka/AkkaRpcEnv.scala","position":17,"original_position":17,"commit_id":"2f9409599940e582feeb376f4f93c419d579ee7d","original_commit_id":"2f9409599940e582feeb376f4f93c419d579ee7d","user":{"login":"squito","id":71240,"avatar_url":"https://avatars.githubusercontent.com/u/71240?v=3","gravatar_id":"","url":"https://api.github.com/users/squito","html_url":"https://github.com/squito","followers_url":"https://api.github.com/users/squito/followers","following_url":"https://api.github.com/users/squito/following{/other_user}","gists_url":"https://api.github.com/users/squito/gists{/gist_id}","starred_url":"https://api.github.com/users/squito/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/squito/subscriptions","organizations_url":"https://api.github.com/users/squito/orgs","repos_url":"https://api.github.com/users/squito/repos","events_url":"https://api.github.com/users/squito/events{/privacy}","received_events_url":"https://api.github.com/users/squito/received_events","type":"User","site_admin":false},"body":"yeah I think its better to be more explicit, its not clear what the first `_` is.  Also I think it would be a bit clearer in two statements, so you can add a comment explaining, eg.\r\n\r\n```\r\nval future = actorSystem.actorSelection(uri).resolveOne(defaultLookupTimeout.duration)\r\n  .map(new AkkaRpcEndpointRef(defaultAddress, _, conf))\r\n// this is just in case there is a timeout from creating the future in resolveOne, we want the\r\n// exception to indicate the conf that determines the timeout\r\ndefaultLookupTimeout.addMessageIfTimeout(future)\r\n```","created_at":"2015-06-05T16:36:32Z","updated_at":"2015-06-05T16:36:32Z","html_url":"https://github.com/apache/spark/pull/6205#discussion_r31828705","pull_request_url":"https://api.github.com/repos/apache/spark/pulls/6205","_links":{"self":{"href":"https://api.github.com/repos/apache/spark/pulls/comments/31828705"},"html":{"href":"https://github.com/apache/spark/pull/6205#discussion_r31828705"},"pull_request":{"href":"https://api.github.com/repos/apache/spark/pulls/6205"}}},"pull_request":{"url":"https://api.github.com/repos/apache/spark/pulls/6205","id":35561436,"html_url":"https://github.com/apache/spark/pull/6205","diff_url":"https://github.com/apache/spark/pull/6205.diff","patch_url":"https://github.com/apache/spark/pull/6205.patch","issue_url":"https://api.github.com/repos/apache/spark/issues/6205","number":6205,"state":"open","locked":false,"title":"[SPARK-6980] [CORE] [WIP] Akka timeout exceptions indicate which conf controls them (RPC Layer)","user":{"login":"BryanCutler","id":4534389,"avatar_url":"https://avatars.githubusercontent.com/u/4534389?v=3","gravatar_id":"","url":"https://api.github.com/users/BryanCutler","html_url":"https://github.com/BryanCutler","followers_url":"https://api.github.com/users/BryanCutler/followers","following_url":"https://api.github.com/users/BryanCutler/following{/other_user}","gists_url":"https://api.github.com/users/BryanCutler/gists{/gist_id}","starred_url":"https://api.github.com/users/BryanCutler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BryanCutler/subscriptions","organizations_url":"https://api.github.com/users/BryanCutler/orgs","repos_url":"https://api.github.com/users/BryanCutler/repos","events_url":"https://api.github.com/users/BryanCutler/events{/privacy}","received_events_url":"https://api.github.com/users/BryanCutler/received_events","type":"User","site_admin":false},"body":"Latest changes after refactoring to the RPC layer.  I rebased against trunk to make sure to get any recent changes since it had been a while.  I wasn't crazy about the name `ConfigureTimeout` and `RpcTimeout` seemed to fit better, but I'm open to suggestions!\r\n\r\nI ran most of the tests and they pass, but others would get stuck with \"WARN TaskSchedulerImpl: Initial job has not accepted any resources\".  I think its just my machine, so I'd though I would push what I have anyway.  \r\n\r\nStill left to do:\r\n* I only added a couple unit tests so far, there are probably some more cases to test\r\n* Make sure all uses require a `RpcTimeout`\r\n* Right now, both the `ask` and `Await.result` use the same timeout, should we differentiate between these in the TimeoutException message?\r\n* I wrapped `Await.result` in `RpcTimeout`, should we also wrap `Await.ready`?\r\n* Proper scoping of classes and methods\r\n\r\n@hardmettle, feel free to help out with any of these!","created_at":"2015-05-16T00:20:10Z","updated_at":"2015-06-05T16:36:32Z","closed_at":null,"merged_at":null,"merge_commit_sha":"287ea96add59fa25caaa023d1b4699be11d3bc2a","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/apache/spark/pulls/6205/commits","review_comments_url":"https://api.github.com/repos/apache/spark/pulls/6205/comments","review_comment_url":"https://api.github.com/repos/apache/spark/pulls/comments{/number}","comments_url":"https://api.github.com/repos/apache/spark/issues/6205/comments","statuses_url":"https://api.github.com/repos/apache/spark/statuses/2f9409599940e582feeb376f4f93c419d579ee7d","head":{"label":"BryanCutler:configTimeout-6980","ref":"configTimeout-6980","sha":"2f9409599940e582feeb376f4f93c419d579ee7d","user":{"login":"BryanCutler","id":4534389,"avatar_url":"https://avatars.githubusercontent.com/u/4534389?v=3","gravatar_id":"","url":"https://api.github.com/users/BryanCutler","html_url":"https://github.com/BryanCutler","followers_url":"https://api.github.com/users/BryanCutler/followers","following_url":"https://api.github.com/users/BryanCutler/following{/other_user}","gists_url":"https://api.github.com/users/BryanCutler/gists{/gist_id}","starred_url":"https://api.github.com/users/BryanCutler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BryanCutler/subscriptions","organizations_url":"https://api.github.com/users/BryanCutler/orgs","repos_url":"https://api.github.com/users/BryanCutler/repos","events_url":"https://api.github.com/users/BryanCutler/events{/privacy}","received_events_url":"https://api.github.com/users/BryanCutler/received_events","type":"User","site_admin":false},"repo":{"id":34092463,"name":"spark","full_name":"BryanCutler/spark","owner":{"login":"BryanCutler","id":4534389,"avatar_url":"https://avatars.githubusercontent.com/u/4534389?v=3","gravatar_id":"","url":"https://api.github.com/users/BryanCutler","html_url":"https://github.com/BryanCutler","followers_url":"https://api.github.com/users/BryanCutler/followers","following_url":"https://api.github.com/users/BryanCutler/following{/other_user}","gists_url":"https://api.github.com/users/BryanCutler/gists{/gist_id}","starred_url":"https://api.github.com/users/BryanCutler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BryanCutler/subscriptions","organizations_url":"https://api.github.com/users/BryanCutler/orgs","repos_url":"https://api.github.com/users/BryanCutler/repos","events_url":"https://api.github.com/users/BryanCutler/events{/privacy}","received_events_url":"https://api.github.com/users/BryanCutler/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/BryanCutler/spark","description":"Mirror of Apache Spark","fork":true,"url":"https://api.github.com/repos/BryanCutler/spark","forks_url":"https://api.github.com/repos/BryanCutler/spark/forks","keys_url":"https://api.github.com/repos/BryanCutler/spark/keys{/key_id}","collaborators_url":"https://api.github.com/repos/BryanCutler/spark/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/BryanCutler/spark/teams","hooks_url":"https://api.github.com/repos/BryanCutler/spark/hooks","issue_events_url":"https://api.github.com/repos/BryanCutler/spark/issues/events{/number}","events_url":"https://api.github.com/repos/BryanCutler/spark/events","assignees_url":"https://api.github.com/repos/BryanCutler/spark/assignees{/user}","branches_url":"https://api.github.com/repos/BryanCutler/spark/branches{/branch}","tags_url":"https://api.github.com/repos/BryanCutler/spark/tags","blobs_url":"https://api.github.com/repos/BryanCutler/spark/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/BryanCutler/spark/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/BryanCutler/spark/git/refs{/sha}","trees_url":"https://api.github.com/repos/BryanCutler/spark/git/trees{/sha}","statuses_url":"https://api.github.com/repos/BryanCutler/spark/statuses/{sha}","languages_url":"https://api.github.com/repos/BryanCutler/spark/languages","stargazers_url":"https://api.github.com/repos/BryanCutler/spark/stargazers","contributors_url":"https://api.github.com/repos/BryanCutler/spark/contributors","subscribers_url":"https://api.github.com/repos/BryanCutler/spark/subscribers","subscription_url":"https://api.github.com/repos/BryanCutler/spark/subscription","commits_url":"https://api.github.com/repos/BryanCutler/spark/commits{/sha}","git_commits_url":"https://api.github.com/repos/BryanCutler/spark/git/commits{/sha}","comments_url":"https://api.github.com/repos/BryanCutler/spark/comments{/number}","issue_comment_url":"https://api.github.com/repos/BryanCutler/spark/issues/comments{/number}","contents_url":"https://api.github.com/repos/BryanCutler/spark/contents/{+path}","compare_url":"https://api.github.com/repos/BryanCutler/spark/compare/{base}...{head}","merges_url":"https://api.github.com/repos/BryanCutler/spark/merges","archive_url":"https://api.github.com/repos/BryanCutler/spark/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/BryanCutler/spark/downloads","issues_url":"https://api.github.com/repos/BryanCutler/spark/issues{/number}","pulls_url":"https://api.github.com/repos/BryanCutler/spark/pulls{/number}","milestones_url":"https://api.github.com/repos/BryanCutler/spark/milestones{/number}","notifications_url":"https://api.github.com/repos/BryanCutler/spark/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/BryanCutler/spark/labels{/name}","releases_url":"https://api.github.com/repos/BryanCutler/spark/releases{/id}","created_at":"2015-04-17T02:35:36Z","updated_at":"2015-05-03T18:05:53Z","pushed_at":"2015-06-04T23:11:18Z","git_url":"git://github.com/BryanCutler/spark.git","ssh_url":"git@github.com:BryanCutler/spark.git","clone_url":"https://github.com/BryanCutler/spark.git","svn_url":"https://github.com/BryanCutler/spark","homepage":null,"size":109448,"stargazers_count":0,"watchers_count":0,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"apache:master","ref":"master","sha":"f1646e1023bd03e27268a8aa2ea11b6cc284075f","user":{"login":"apache","id":47359,"avatar_url":"https://avatars.githubusercontent.com/u/47359?v=3","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"repo":{"id":17165658,"name":"spark","full_name":"apache/spark","owner":{"login":"apache","id":47359,"avatar_url":"https://avatars.githubusercontent.com/u/47359?v=3","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/apache/spark","description":"Mirror of Apache Spark","fork":false,"url":"https://api.github.com/repos/apache/spark","forks_url":"https://api.github.com/repos/apache/spark/forks","keys_url":"https://api.github.com/repos/apache/spark/keys{/key_id}","collaborators_url":"https://api.github.com/repos/apache/spark/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/apache/spark/teams","hooks_url":"https://api.github.com/repos/apache/spark/hooks","issue_events_url":"https://api.github.com/repos/apache/spark/issues/events{/number}","events_url":"https://api.github.com/repos/apache/spark/events","assignees_url":"https://api.github.com/repos/apache/spark/assignees{/user}","branches_url":"https://api.github.com/repos/apache/spark/branches{/branch}","tags_url":"https://api.github.com/repos/apache/spark/tags","blobs_url":"https://api.github.com/repos/apache/spark/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/apache/spark/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/apache/spark/git/refs{/sha}","trees_url":"https://api.github.com/repos/apache/spark/git/trees{/sha}","statuses_url":"https://api.github.com/repos/apache/spark/statuses/{sha}","languages_url":"https://api.github.com/repos/apache/spark/languages","stargazers_url":"https://api.github.com/repos/apache/spark/stargazers","contributors_url":"https://api.github.com/repos/apache/spark/contributors","subscribers_url":"https://api.github.com/repos/apache/spark/subscribers","subscription_url":"https://api.github.com/repos/apache/spark/subscription","commits_url":"https://api.github.com/repos/apache/spark/commits{/sha}","git_commits_url":"https://api.github.com/repos/apache/spark/git/commits{/sha}","comments_url":"https://api.github.com/repos/apache/spark/comments{/number}","issue_comment_url":"https://api.github.com/repos/apache/spark/issues/comments{/number}","contents_url":"https://api.github.com/repos/apache/spark/contents/{+path}","compare_url":"https://api.github.com/repos/apache/spark/compare/{base}...{head}","merges_url":"https://api.github.com/repos/apache/spark/merges","archive_url":"https://api.github.com/repos/apache/spark/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/apache/spark/downloads","issues_url":"https://api.github.com/repos/apache/spark/issues{/number}","pulls_url":"https://api.github.com/repos/apache/spark/pulls{/number}","milestones_url":"https://api.github.com/repos/apache/spark/milestones{/number}","notifications_url":"https://api.github.com/repos/apache/spark/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/apache/spark/labels{/name}","releases_url":"https://api.github.com/repos/apache/spark/releases{/id}","created_at":"2014-02-25T08:00:08Z","updated_at":"2015-06-05T09:15:43Z","pushed_at":"2015-06-05T16:21:28Z","git_url":"git://github.com/apache/spark.git","ssh_url":"git@github.com:apache/spark.git","clone_url":"https://github.com/apache/spark.git","svn_url":"https://github.com/apache/spark","homepage":null,"size":1439944,"stargazers_count":4237,"watchers_count":4237,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":3714,"mirror_url":"git://git.apache.org/spark.git","open_issues_count":344,"forks":3714,"open_issues":344,"watchers":4237,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/apache/spark/pulls/6205"},"html":{"href":"https://github.com/apache/spark/pull/6205"},"issue":{"href":"https://api.github.com/repos/apache/spark/issues/6205"},"comments":{"href":"https://api.github.com/repos/apache/spark/issues/6205/comments"},"review_comments":{"href":"https://api.github.com/repos/apache/spark/pulls/6205/comments"},"review_comment":{"href":"https://api.github.com/repos/apache/spark/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/apache/spark/pulls/6205/commits"},"statuses":{"href":"https://api.github.com/repos/apache/spark/statuses/2f9409599940e582feeb376f4f93c419d579ee7d"}}}}