{"action":"created","comment":{"url":"https://api.github.com/repos/druid-io/druid/pulls/comments/170082750","pull_request_review_id":98711822,"id":170082750,"diff_hunk":"@@ -49,6 +51,11 @@ public static ExecutorService dummy()\n     return DummyExecutorService.INSTANCE;\n   }\n \n+  public static ListeningExecutorService sameThreadExecutor()","path":"java-util/src/main/java/io/druid/java/util/common/concurrent/Execs.java","position":13,"original_position":13,"commit_id":"8ad1173195c15ab004ca7ae41214ffe74e0185fe","original_commit_id":"8ad1173195c15ab004ca7ae41214ffe74e0185fe","user":{"login":"leventov","id":609240,"avatar_url":"https://avatars0.githubusercontent.com/u/609240?v=4","gravatar_id":"","url":"https://api.github.com/users/leventov","html_url":"https://github.com/leventov","followers_url":"https://api.github.com/users/leventov/followers","following_url":"https://api.github.com/users/leventov/following{/other_user}","gists_url":"https://api.github.com/users/leventov/gists{/gist_id}","starred_url":"https://api.github.com/users/leventov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leventov/subscriptions","organizations_url":"https://api.github.com/users/leventov/orgs","repos_url":"https://api.github.com/users/leventov/repos","events_url":"https://api.github.com/users/leventov/events{/privacy}","received_events_url":"https://api.github.com/users/leventov/received_events","type":"User","site_admin":false},"body":"It was a mistake in Guava's API to call this method this way, because it gives full impression that some static constant is returned from it (I thought that until now), while in reality this method (and the removed method in Guava) creates a new Object each time. (Guava developers fixed this mistake by calling the new method *new*DirectExecutorService().)\r\n\r\nHowever, I think that Druid actually never tries to terminate this service, so it would be better to keep the method name as is, actually cache the executor service, and simplify it's implementation, by either throwing an `UnsupportedOperationException` in `shutdown()` and `shutdownNow()` or making them no-ops, and always returning `false` from `isTerminated()`, and removing all state and synchronization from the class.","created_at":"2018-02-22T20:25:20Z","updated_at":"2018-02-22T20:25:54Z","html_url":"https://github.com/druid-io/druid/pull/5413#discussion_r170082750","pull_request_url":"https://api.github.com/repos/druid-io/druid/pulls/5413","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/druid-io/druid/pulls/comments/170082750"},"html":{"href":"https://github.com/druid-io/druid/pull/5413#discussion_r170082750"},"pull_request":{"href":"https://api.github.com/repos/druid-io/druid/pulls/5413"}}},"pull_request":{"url":"https://api.github.com/repos/druid-io/druid/pulls/5413","id":170658363,"html_url":"https://github.com/druid-io/druid/pull/5413","diff_url":"https://github.com/druid-io/druid/pull/5413.diff","patch_url":"https://github.com/druid-io/druid/pull/5413.patch","issue_url":"https://api.github.com/repos/druid-io/druid/issues/5413","number":5413,"state":"open","locked":false,"title":"Guava-free Same Thread Executor","user":{"login":"drcrallen","id":8213081,"avatar_url":"https://avatars2.githubusercontent.com/u/8213081?v=4","gravatar_id":"","url":"https://api.github.com/users/drcrallen","html_url":"https://github.com/drcrallen","followers_url":"https://api.github.com/users/drcrallen/followers","following_url":"https://api.github.com/users/drcrallen/following{/other_user}","gists_url":"https://api.github.com/users/drcrallen/gists{/gist_id}","starred_url":"https://api.github.com/users/drcrallen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/drcrallen/subscriptions","organizations_url":"https://api.github.com/users/drcrallen/orgs","repos_url":"https://api.github.com/users/drcrallen/repos","events_url":"https://api.github.com/users/drcrallen/events{/privacy}","received_events_url":"https://api.github.com/users/drcrallen/received_events","type":"User","site_admin":false},"body":"The `MoreExecs.sameThreadExecutor()` is deprecated as per\r\nhttps://github.com/google/guava/blob/v18.0/guava/src/com/google/common/util/concurrent/MoreExecutors.java#L266-L267\r\nand the function signature moves around a lot in future guava releases.\r\n\r\nThis creates a new `SameThreadExecutorService` using more modern java\r\nfeatures.","created_at":"2018-02-22T05:10:16Z","updated_at":"2018-02-22T20:25:54Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f04ae5a6400e9a93fd163321db0b10c2f3908b9d","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":606691557,"url":"https://api.github.com/repos/druid-io/druid/labels/Compatibility","name":"Compatibility","color":"c5def5","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/druid-io/druid/pulls/5413/commits","review_comments_url":"https://api.github.com/repos/druid-io/druid/pulls/5413/comments","review_comment_url":"https://api.github.com/repos/druid-io/druid/pulls/comments{/number}","comments_url":"https://api.github.com/repos/druid-io/druid/issues/5413/comments","statuses_url":"https://api.github.com/repos/druid-io/druid/statuses/8ad1173195c15ab004ca7ae41214ffe74e0185fe","head":{"label":"drcrallen:guava/noSameThreadExecutor","ref":"guava/noSameThreadExecutor","sha":"8ad1173195c15ab004ca7ae41214ffe74e0185fe","user":{"login":"drcrallen","id":8213081,"avatar_url":"https://avatars2.githubusercontent.com/u/8213081?v=4","gravatar_id":"","url":"https://api.github.com/users/drcrallen","html_url":"https://github.com/drcrallen","followers_url":"https://api.github.com/users/drcrallen/followers","following_url":"https://api.github.com/users/drcrallen/following{/other_user}","gists_url":"https://api.github.com/users/drcrallen/gists{/gist_id}","starred_url":"https://api.github.com/users/drcrallen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/drcrallen/subscriptions","organizations_url":"https://api.github.com/users/drcrallen/orgs","repos_url":"https://api.github.com/users/drcrallen/repos","events_url":"https://api.github.com/users/drcrallen/events{/privacy}","received_events_url":"https://api.github.com/users/drcrallen/received_events","type":"User","site_admin":false},"repo":{"id":28249158,"name":"druid","full_name":"drcrallen/druid","owner":{"login":"drcrallen","id":8213081,"avatar_url":"https://avatars2.githubusercontent.com/u/8213081?v=4","gravatar_id":"","url":"https://api.github.com/users/drcrallen","html_url":"https://github.com/drcrallen","followers_url":"https://api.github.com/users/drcrallen/followers","following_url":"https://api.github.com/users/drcrallen/following{/other_user}","gists_url":"https://api.github.com/users/drcrallen/gists{/gist_id}","starred_url":"https://api.github.com/users/drcrallen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/drcrallen/subscriptions","organizations_url":"https://api.github.com/users/drcrallen/orgs","repos_url":"https://api.github.com/users/drcrallen/repos","events_url":"https://api.github.com/users/drcrallen/events{/privacy}","received_events_url":"https://api.github.com/users/drcrallen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/drcrallen/druid","description":"Real²time Exploratory Analytics on Large Datasets","fork":true,"url":"https://api.github.com/repos/drcrallen/druid","forks_url":"https://api.github.com/repos/drcrallen/druid/forks","keys_url":"https://api.github.com/repos/drcrallen/druid/keys{/key_id}","collaborators_url":"https://api.github.com/repos/drcrallen/druid/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/drcrallen/druid/teams","hooks_url":"https://api.github.com/repos/drcrallen/druid/hooks","issue_events_url":"https://api.github.com/repos/drcrallen/druid/issues/events{/number}","events_url":"https://api.github.com/repos/drcrallen/druid/events","assignees_url":"https://api.github.com/repos/drcrallen/druid/assignees{/user}","branches_url":"https://api.github.com/repos/drcrallen/druid/branches{/branch}","tags_url":"https://api.github.com/repos/drcrallen/druid/tags","blobs_url":"https://api.github.com/repos/drcrallen/druid/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/drcrallen/druid/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/drcrallen/druid/git/refs{/sha}","trees_url":"https://api.github.com/repos/drcrallen/druid/git/trees{/sha}","statuses_url":"https://api.github.com/repos/drcrallen/druid/statuses/{sha}","languages_url":"https://api.github.com/repos/drcrallen/druid/languages","stargazers_url":"https://api.github.com/repos/drcrallen/druid/stargazers","contributors_url":"https://api.github.com/repos/drcrallen/druid/contributors","subscribers_url":"https://api.github.com/repos/drcrallen/druid/subscribers","subscription_url":"https://api.github.com/repos/drcrallen/druid/subscription","commits_url":"https://api.github.com/repos/drcrallen/druid/commits{/sha}","git_commits_url":"https://api.github.com/repos/drcrallen/druid/git/commits{/sha}","comments_url":"https://api.github.com/repos/drcrallen/druid/comments{/number}","issue_comment_url":"https://api.github.com/repos/drcrallen/druid/issues/comments{/number}","contents_url":"https://api.github.com/repos/drcrallen/druid/contents/{+path}","compare_url":"https://api.github.com/repos/drcrallen/druid/compare/{base}...{head}","merges_url":"https://api.github.com/repos/drcrallen/druid/merges","archive_url":"https://api.github.com/repos/drcrallen/druid/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/drcrallen/druid/downloads","issues_url":"https://api.github.com/repos/drcrallen/druid/issues{/number}","pulls_url":"https://api.github.com/repos/drcrallen/druid/pulls{/number}","milestones_url":"https://api.github.com/repos/drcrallen/druid/milestones{/number}","notifications_url":"https://api.github.com/repos/drcrallen/druid/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/drcrallen/druid/labels{/name}","releases_url":"https://api.github.com/repos/drcrallen/druid/releases{/id}","deployments_url":"https://api.github.com/repos/drcrallen/druid/deployments","created_at":"2014-12-19T22:40:47Z","updated_at":"2016-11-12T15:32:25Z","pushed_at":"2018-02-22T16:29:22Z","git_url":"git://github.com/drcrallen/druid.git","ssh_url":"git@github.com:drcrallen/druid.git","clone_url":"https://github.com/drcrallen/druid.git","svn_url":"https://github.com/drcrallen/druid","homepage":"http://druid.io","size":131273,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"druid-io:master","ref":"master","sha":"5c56d01daa94e50611e457ad726d4b1c84bfa6c8","user":{"login":"druid-io","id":4203474,"avatar_url":"https://avatars0.githubusercontent.com/u/4203474?v=4","gravatar_id":"","url":"https://api.github.com/users/druid-io","html_url":"https://github.com/druid-io","followers_url":"https://api.github.com/users/druid-io/followers","following_url":"https://api.github.com/users/druid-io/following{/other_user}","gists_url":"https://api.github.com/users/druid-io/gists{/gist_id}","starred_url":"https://api.github.com/users/druid-io/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/druid-io/subscriptions","organizations_url":"https://api.github.com/users/druid-io/orgs","repos_url":"https://api.github.com/users/druid-io/repos","events_url":"https://api.github.com/users/druid-io/events{/privacy}","received_events_url":"https://api.github.com/users/druid-io/received_events","type":"Organization","site_admin":false},"repo":{"id":6358188,"name":"druid","full_name":"druid-io/druid","owner":{"login":"druid-io","id":4203474,"avatar_url":"https://avatars0.githubusercontent.com/u/4203474?v=4","gravatar_id":"","url":"https://api.github.com/users/druid-io","html_url":"https://github.com/druid-io","followers_url":"https://api.github.com/users/druid-io/followers","following_url":"https://api.github.com/users/druid-io/following{/other_user}","gists_url":"https://api.github.com/users/druid-io/gists{/gist_id}","starred_url":"https://api.github.com/users/druid-io/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/druid-io/subscriptions","organizations_url":"https://api.github.com/users/druid-io/orgs","repos_url":"https://api.github.com/users/druid-io/repos","events_url":"https://api.github.com/users/druid-io/events{/privacy}","received_events_url":"https://api.github.com/users/druid-io/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/druid-io/druid","description":"Column oriented distributed data store ideal for powering interactive applications","fork":false,"url":"https://api.github.com/repos/druid-io/druid","forks_url":"https://api.github.com/repos/druid-io/druid/forks","keys_url":"https://api.github.com/repos/druid-io/druid/keys{/key_id}","collaborators_url":"https://api.github.com/repos/druid-io/druid/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/druid-io/druid/teams","hooks_url":"https://api.github.com/repos/druid-io/druid/hooks","issue_events_url":"https://api.github.com/repos/druid-io/druid/issues/events{/number}","events_url":"https://api.github.com/repos/druid-io/druid/events","assignees_url":"https://api.github.com/repos/druid-io/druid/assignees{/user}","branches_url":"https://api.github.com/repos/druid-io/druid/branches{/branch}","tags_url":"https://api.github.com/repos/druid-io/druid/tags","blobs_url":"https://api.github.com/repos/druid-io/druid/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/druid-io/druid/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/druid-io/druid/git/refs{/sha}","trees_url":"https://api.github.com/repos/druid-io/druid/git/trees{/sha}","statuses_url":"https://api.github.com/repos/druid-io/druid/statuses/{sha}","languages_url":"https://api.github.com/repos/druid-io/druid/languages","stargazers_url":"https://api.github.com/repos/druid-io/druid/stargazers","contributors_url":"https://api.github.com/repos/druid-io/druid/contributors","subscribers_url":"https://api.github.com/repos/druid-io/druid/subscribers","subscription_url":"https://api.github.com/repos/druid-io/druid/subscription","commits_url":"https://api.github.com/repos/druid-io/druid/commits{/sha}","git_commits_url":"https://api.github.com/repos/druid-io/druid/git/commits{/sha}","comments_url":"https://api.github.com/repos/druid-io/druid/comments{/number}","issue_comment_url":"https://api.github.com/repos/druid-io/druid/issues/comments{/number}","contents_url":"https://api.github.com/repos/druid-io/druid/contents/{+path}","compare_url":"https://api.github.com/repos/druid-io/druid/compare/{base}...{head}","merges_url":"https://api.github.com/repos/druid-io/druid/merges","archive_url":"https://api.github.com/repos/druid-io/druid/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/druid-io/druid/downloads","issues_url":"https://api.github.com/repos/druid-io/druid/issues{/number}","pulls_url":"https://api.github.com/repos/druid-io/druid/pulls{/number}","milestones_url":"https://api.github.com/repos/druid-io/druid/milestones{/number}","notifications_url":"https://api.github.com/repos/druid-io/druid/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/druid-io/druid/labels{/name}","releases_url":"https://api.github.com/repos/druid-io/druid/releases{/id}","deployments_url":"https://api.github.com/repos/druid-io/druid/deployments","created_at":"2012-10-23T19:08:07Z","updated_at":"2018-02-22T19:56:55Z","pushed_at":"2018-02-22T20:03:08Z","git_url":"git://github.com/druid-io/druid.git","ssh_url":"git@github.com:druid-io/druid.git","clone_url":"https://github.com/druid-io/druid.git","svn_url":"https://github.com/druid-io/druid","homepage":"http://druid.io","size":134445,"stargazers_count":6117,"watchers_count":6117,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1504,"mirror_url":null,"archived":false,"open_issues_count":910,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":1504,"open_issues":910,"watchers":6117,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/druid-io/druid/pulls/5413"},"html":{"href":"https://github.com/druid-io/druid/pull/5413"},"issue":{"href":"https://api.github.com/repos/druid-io/druid/issues/5413"},"comments":{"href":"https://api.github.com/repos/druid-io/druid/issues/5413/comments"},"review_comments":{"href":"https://api.github.com/repos/druid-io/druid/pulls/5413/comments"},"review_comment":{"href":"https://api.github.com/repos/druid-io/druid/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/druid-io/druid/pulls/5413/commits"},"statuses":{"href":"https://api.github.com/repos/druid-io/druid/statuses/8ad1173195c15ab004ca7ae41214ffe74e0185fe"}},"author_association":"OWNER"}}
{"actor":{"display_login":"leventov"}}