{"action":"created","comment":{"url":"https://api.github.com/repos/google/guava/pulls/comments/54640871","id":54640871,"diff_hunk":"@@ -326,7 +326,67 @@ public static boolean tryAcquireUninterruptibly(\n     }\n   }\n \n-  // TODO(user): Add support for waitUninterruptibly.\n+  /**\n+   * Invokes {@code object.}{@link Object#wait() wait()} uninterruptibly.\n+   *\n+   * @param object to wait upon.\n+   *\n+   * @throws IllegalMonitorStateException if the current thread is not\n+   *               the owner of the object's monitor.\n+   */\n+  @GwtIncompatible // concurrency\n+  public static void waitUninterruptibly(Object object) {\n+    Preconditions.checkNotNull(object);\n+    boolean interrupted = false;\n+    try {\n+      while (true) {\n+        try {\n+          object.wait();\n+          return;\n+        } catch (InterruptedException e) {\n+          interrupted = true;\n+        }\n+      }\n+    } finally {\n+      if (interrupted) {\n+        Thread.currentThread().interrupt();\n+      }\n+    }\n+  }\n+\n+  /**\n+   * Invokes {@code object.}{@link Object#wait(long, int) wait(millis, nanos)} uninterruptibly.\n+   *\n+   * @param object to wait upon.\n+   *\n+   * @throws IllegalMonitorStateException if the current thread is not the owner of the object's\n+   *          monitor.\n+   */\n+  @GwtIncompatible // concurrency\n+  public static void waitUninterruptibly(Object object, long timeout, TimeUnit unit) {\n+    Preconditions.checkNotNull(object);\n+    Preconditions.checkNotNull(unit);\n+    boolean interrupted = false;\n+    try {\n+      long remainingNanos = unit.toNanos(timeout);\n+      long end = System.nanoTime() + remainingNanos;\n+\n+      while (true) {\n+        try {\n+          // timedWait treats negative timeouts just like zero.\n+          NANOSECONDS.timedWait(object, remainingNanos);\n+          return;\n+        } catch (InterruptedException e) {\n+          interrupted = true;","path":"guava/src/com/google/common/util/concurrent/Uninterruptibles.java","position":56,"original_position":56,"commit_id":"1635ffaf989962ba14daef2df8d38f569e982dd8","original_commit_id":"1635ffaf989962ba14daef2df8d38f569e982dd8","user":{"login":"Ram-Kasam","id":10771375,"avatar_url":"https://avatars.githubusercontent.com/u/10771375?v=3","gravatar_id":"","url":"https://api.github.com/users/Ram-Kasam","html_url":"https://github.com/Ram-Kasam","followers_url":"https://api.github.com/users/Ram-Kasam/followers","following_url":"https://api.github.com/users/Ram-Kasam/following{/other_user}","gists_url":"https://api.github.com/users/Ram-Kasam/gists{/gist_id}","starred_url":"https://api.github.com/users/Ram-Kasam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ram-Kasam/subscriptions","organizations_url":"https://api.github.com/users/Ram-Kasam/orgs","repos_url":"https://api.github.com/users/Ram-Kasam/repos","events_url":"https://api.github.com/users/Ram-Kasam/events{/privacy}","received_events_url":"https://api.github.com/users/Ram-Kasam/received_events","type":"User","site_admin":false},"body":"Do you suggest we return here? or keep retrying till the timeout expires?","created_at":"2016-03-01T21:44:16Z","updated_at":"2016-03-01T21:44:16Z","html_url":"https://github.com/google/guava/pull/2383#discussion_r54640871","pull_request_url":"https://api.github.com/repos/google/guava/pulls/2383","_links":{"self":{"href":"https://api.github.com/repos/google/guava/pulls/comments/54640871"},"html":{"href":"https://github.com/google/guava/pull/2383#discussion_r54640871"},"pull_request":{"href":"https://api.github.com/repos/google/guava/pulls/2383"}}},"pull_request":{"url":"https://api.github.com/repos/google/guava/pulls/2383","id":58541815,"html_url":"https://github.com/google/guava/pull/2383","diff_url":"https://github.com/google/guava/pull/2383.diff","patch_url":"https://github.com/google/guava/pull/2383.patch","issue_url":"https://api.github.com/repos/google/guava/issues/2383","number":2383,"state":"open","locked":false,"title":"In Uninterruptibles, added waitUninterruptibly methods which call Object#wait methods","user":{"login":"RamAnvesh","id":2082745,"avatar_url":"https://avatars.githubusercontent.com/u/2082745?v=3","gravatar_id":"","url":"https://api.github.com/users/RamAnvesh","html_url":"https://github.com/RamAnvesh","followers_url":"https://api.github.com/users/RamAnvesh/followers","following_url":"https://api.github.com/users/RamAnvesh/following{/other_user}","gists_url":"https://api.github.com/users/RamAnvesh/gists{/gist_id}","starred_url":"https://api.github.com/users/RamAnvesh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RamAnvesh/subscriptions","organizations_url":"https://api.github.com/users/RamAnvesh/orgs","repos_url":"https://api.github.com/users/RamAnvesh/repos","events_url":"https://api.github.com/users/RamAnvesh/events{/privacy}","received_events_url":"https://api.github.com/users/RamAnvesh/received_events","type":"User","site_admin":false},"body":"https://github.com/google/guava/issues/1409","created_at":"2016-02-07T08:20:17Z","updated_at":"2016-03-01T21:44:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"03bf253db226fcf71ebf99873e9120459979bbbb","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/google/guava/pulls/2383/commits","review_comments_url":"https://api.github.com/repos/google/guava/pulls/2383/comments","review_comment_url":"https://api.github.com/repos/google/guava/pulls/comments{/number}","comments_url":"https://api.github.com/repos/google/guava/issues/2383/comments","statuses_url":"https://api.github.com/repos/google/guava/statuses/1635ffaf989962ba14daef2df8d38f569e982dd8","head":{"label":"RamAnvesh:waitUninterruptibly","ref":"waitUninterruptibly","sha":"1635ffaf989962ba14daef2df8d38f569e982dd8","user":{"login":"RamAnvesh","id":2082745,"avatar_url":"https://avatars.githubusercontent.com/u/2082745?v=3","gravatar_id":"","url":"https://api.github.com/users/RamAnvesh","html_url":"https://github.com/RamAnvesh","followers_url":"https://api.github.com/users/RamAnvesh/followers","following_url":"https://api.github.com/users/RamAnvesh/following{/other_user}","gists_url":"https://api.github.com/users/RamAnvesh/gists{/gist_id}","starred_url":"https://api.github.com/users/RamAnvesh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RamAnvesh/subscriptions","organizations_url":"https://api.github.com/users/RamAnvesh/orgs","repos_url":"https://api.github.com/users/RamAnvesh/repos","events_url":"https://api.github.com/users/RamAnvesh/events{/privacy}","received_events_url":"https://api.github.com/users/RamAnvesh/received_events","type":"User","site_admin":false},"repo":{"id":51211455,"name":"guava","full_name":"RamAnvesh/guava","owner":{"login":"RamAnvesh","id":2082745,"avatar_url":"https://avatars.githubusercontent.com/u/2082745?v=3","gravatar_id":"","url":"https://api.github.com/users/RamAnvesh","html_url":"https://github.com/RamAnvesh","followers_url":"https://api.github.com/users/RamAnvesh/followers","following_url":"https://api.github.com/users/RamAnvesh/following{/other_user}","gists_url":"https://api.github.com/users/RamAnvesh/gists{/gist_id}","starred_url":"https://api.github.com/users/RamAnvesh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RamAnvesh/subscriptions","organizations_url":"https://api.github.com/users/RamAnvesh/orgs","repos_url":"https://api.github.com/users/RamAnvesh/repos","events_url":"https://api.github.com/users/RamAnvesh/events{/privacy}","received_events_url":"https://api.github.com/users/RamAnvesh/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/RamAnvesh/guava","description":"Google Core Libraries for Java 6+","fork":true,"url":"https://api.github.com/repos/RamAnvesh/guava","forks_url":"https://api.github.com/repos/RamAnvesh/guava/forks","keys_url":"https://api.github.com/repos/RamAnvesh/guava/keys{/key_id}","collaborators_url":"https://api.github.com/repos/RamAnvesh/guava/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/RamAnvesh/guava/teams","hooks_url":"https://api.github.com/repos/RamAnvesh/guava/hooks","issue_events_url":"https://api.github.com/repos/RamAnvesh/guava/issues/events{/number}","events_url":"https://api.github.com/repos/RamAnvesh/guava/events","assignees_url":"https://api.github.com/repos/RamAnvesh/guava/assignees{/user}","branches_url":"https://api.github.com/repos/RamAnvesh/guava/branches{/branch}","tags_url":"https://api.github.com/repos/RamAnvesh/guava/tags","blobs_url":"https://api.github.com/repos/RamAnvesh/guava/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/RamAnvesh/guava/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/RamAnvesh/guava/git/refs{/sha}","trees_url":"https://api.github.com/repos/RamAnvesh/guava/git/trees{/sha}","statuses_url":"https://api.github.com/repos/RamAnvesh/guava/statuses/{sha}","languages_url":"https://api.github.com/repos/RamAnvesh/guava/languages","stargazers_url":"https://api.github.com/repos/RamAnvesh/guava/stargazers","contributors_url":"https://api.github.com/repos/RamAnvesh/guava/contributors","subscribers_url":"https://api.github.com/repos/RamAnvesh/guava/subscribers","subscription_url":"https://api.github.com/repos/RamAnvesh/guava/subscription","commits_url":"https://api.github.com/repos/RamAnvesh/guava/commits{/sha}","git_commits_url":"https://api.github.com/repos/RamAnvesh/guava/git/commits{/sha}","comments_url":"https://api.github.com/repos/RamAnvesh/guava/comments{/number}","issue_comment_url":"https://api.github.com/repos/RamAnvesh/guava/issues/comments{/number}","contents_url":"https://api.github.com/repos/RamAnvesh/guava/contents/{+path}","compare_url":"https://api.github.com/repos/RamAnvesh/guava/compare/{base}...{head}","merges_url":"https://api.github.com/repos/RamAnvesh/guava/merges","archive_url":"https://api.github.com/repos/RamAnvesh/guava/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/RamAnvesh/guava/downloads","issues_url":"https://api.github.com/repos/RamAnvesh/guava/issues{/number}","pulls_url":"https://api.github.com/repos/RamAnvesh/guava/pulls{/number}","milestones_url":"https://api.github.com/repos/RamAnvesh/guava/milestones{/number}","notifications_url":"https://api.github.com/repos/RamAnvesh/guava/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/RamAnvesh/guava/labels{/name}","releases_url":"https://api.github.com/repos/RamAnvesh/guava/releases{/id}","deployments_url":"https://api.github.com/repos/RamAnvesh/guava/deployments","created_at":"2016-02-06T16:55:00Z","updated_at":"2016-02-06T16:55:06Z","pushed_at":"2016-02-28T07:50:19Z","git_url":"git://github.com/RamAnvesh/guava.git","ssh_url":"git@github.com:RamAnvesh/guava.git","clone_url":"https://github.com/RamAnvesh/guava.git","svn_url":"https://github.com/RamAnvesh/guava","homepage":"","size":105888,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"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":"google:master","ref":"master","sha":"012d8f4f9c07228c89c728330abaaa6a87cd318d","user":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"repo":{"id":20300177,"name":"guava","full_name":"google/guava","owner":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/google/guava","description":"Google Core Libraries for Java 6+","fork":false,"url":"https://api.github.com/repos/google/guava","forks_url":"https://api.github.com/repos/google/guava/forks","keys_url":"https://api.github.com/repos/google/guava/keys{/key_id}","collaborators_url":"https://api.github.com/repos/google/guava/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/google/guava/teams","hooks_url":"https://api.github.com/repos/google/guava/hooks","issue_events_url":"https://api.github.com/repos/google/guava/issues/events{/number}","events_url":"https://api.github.com/repos/google/guava/events","assignees_url":"https://api.github.com/repos/google/guava/assignees{/user}","branches_url":"https://api.github.com/repos/google/guava/branches{/branch}","tags_url":"https://api.github.com/repos/google/guava/tags","blobs_url":"https://api.github.com/repos/google/guava/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/google/guava/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/google/guava/git/refs{/sha}","trees_url":"https://api.github.com/repos/google/guava/git/trees{/sha}","statuses_url":"https://api.github.com/repos/google/guava/statuses/{sha}","languages_url":"https://api.github.com/repos/google/guava/languages","stargazers_url":"https://api.github.com/repos/google/guava/stargazers","contributors_url":"https://api.github.com/repos/google/guava/contributors","subscribers_url":"https://api.github.com/repos/google/guava/subscribers","subscription_url":"https://api.github.com/repos/google/guava/subscription","commits_url":"https://api.github.com/repos/google/guava/commits{/sha}","git_commits_url":"https://api.github.com/repos/google/guava/git/commits{/sha}","comments_url":"https://api.github.com/repos/google/guava/comments{/number}","issue_comment_url":"https://api.github.com/repos/google/guava/issues/comments{/number}","contents_url":"https://api.github.com/repos/google/guava/contents/{+path}","compare_url":"https://api.github.com/repos/google/guava/compare/{base}...{head}","merges_url":"https://api.github.com/repos/google/guava/merges","archive_url":"https://api.github.com/repos/google/guava/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/google/guava/downloads","issues_url":"https://api.github.com/repos/google/guava/issues{/number}","pulls_url":"https://api.github.com/repos/google/guava/pulls{/number}","milestones_url":"https://api.github.com/repos/google/guava/milestones{/number}","notifications_url":"https://api.github.com/repos/google/guava/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/google/guava/labels{/name}","releases_url":"https://api.github.com/repos/google/guava/releases{/id}","deployments_url":"https://api.github.com/repos/google/guava/deployments","created_at":"2014-05-29T16:23:17Z","updated_at":"2016-03-01T21:42:40Z","pushed_at":"2016-03-01T18:56:33Z","git_url":"git://github.com/google/guava.git","ssh_url":"git@github.com:google/guava.git","clone_url":"https://github.com/google/guava.git","svn_url":"https://github.com/google/guava","homepage":"","size":111066,"stargazers_count":7668,"watchers_count":7668,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":1749,"mirror_url":null,"open_issues_count":618,"forks":1749,"open_issues":618,"watchers":7668,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/google/guava/pulls/2383"},"html":{"href":"https://github.com/google/guava/pull/2383"},"issue":{"href":"https://api.github.com/repos/google/guava/issues/2383"},"comments":{"href":"https://api.github.com/repos/google/guava/issues/2383/comments"},"review_comments":{"href":"https://api.github.com/repos/google/guava/pulls/2383/comments"},"review_comment":{"href":"https://api.github.com/repos/google/guava/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/google/guava/pulls/2383/commits"},"statuses":{"href":"https://api.github.com/repos/google/guava/statuses/1635ffaf989962ba14daef2df8d38f569e982dd8"}}}}