{"action":"created","comment":{"url":"https://api.github.com/repos/druid-io/druid/pulls/comments/62404559","id":62404559,"diff_hunk":"@@ -241,10 +241,28 @@ public SearchHit apply(@Nullable Object input)\n   }\n \n   @Override\n-  public QueryRunner<Result<SearchResultValue>> preMergeQueryDecoration(QueryRunner<Result<SearchResultValue>> runner)\n+  public QueryRunner<Result<SearchResultValue>> preMergeQueryDecoration(final QueryRunner<Result<SearchResultValue>> runner)\n   {\n     return new SearchThresholdAdjustingQueryRunner(\n-        intervalChunkingQueryRunnerDecorator.decorate(runner, this),\n+        intervalChunkingQueryRunnerDecorator.decorate(\n+            new QueryRunner<Result<SearchResultValue>>()\n+            {\n+              @Override\n+              public Sequence<Result<SearchResultValue>> run(\n+                  Query<Result<SearchResultValue>> query, Map<String, Object> responseContext\n+              )\n+              {\n+                if (!(query instanceof SearchQuery)) {","path":"processing/src/main/java/io/druid/query/search/SearchQueryQueryToolChest.java","position":17,"original_position":17,"commit_id":"895e0c7fc986306366a2058d4637807cef02f877","original_commit_id":"895e0c7fc986306366a2058d4637807cef02f877","user":{"login":"gianm","id":1214075,"avatar_url":"https://avatars.githubusercontent.com/u/1214075?v=3","gravatar_id":"","url":"https://api.github.com/users/gianm","html_url":"https://github.com/gianm","followers_url":"https://api.github.com/users/gianm/followers","following_url":"https://api.github.com/users/gianm/following{/other_user}","gists_url":"https://api.github.com/users/gianm/gists{/gist_id}","starred_url":"https://api.github.com/users/gianm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gianm/subscriptions","organizations_url":"https://api.github.com/users/gianm/orgs","repos_url":"https://api.github.com/users/gianm/repos","events_url":"https://api.github.com/users/gianm/events{/privacy}","received_events_url":"https://api.github.com/users/gianm/received_events","type":"User","site_admin":false},"body":"It would be super weird to get anything other than a SearchQuery here, so I think it'd be OK to just do the cast without checking instanceof. If the cast fails due to some insanity then we'll still get a pretty reasonable ClassCastException.","created_at":"2016-05-06T23:37:09Z","updated_at":"2016-05-06T23:37:09Z","html_url":"https://github.com/druid-io/druid/pull/2931#discussion_r62404559","pull_request_url":"https://api.github.com/repos/druid-io/druid/pulls/2931","_links":{"self":{"href":"https://api.github.com/repos/druid-io/druid/pulls/comments/62404559"},"html":{"href":"https://github.com/druid-io/druid/pull/2931#discussion_r62404559"},"pull_request":{"href":"https://api.github.com/repos/druid-io/druid/pulls/2931"}}},"pull_request":{"url":"https://api.github.com/repos/druid-io/druid/pulls/2931","id":69216202,"html_url":"https://github.com/druid-io/druid/pull/2931","diff_url":"https://github.com/druid-io/druid/pull/2931.diff","patch_url":"https://github.com/druid-io/druid/pull/2931.patch","issue_url":"https://api.github.com/repos/druid-io/druid/issues/2931","number":2931,"state":"open","locked":false,"title":"Optimize filter for timeseries, search, and select queries","user":{"login":"acslk","id":11131839,"avatar_url":"https://avatars.githubusercontent.com/u/11131839?v=3","gravatar_id":"","url":"https://api.github.com/users/acslk","html_url":"https://github.com/acslk","followers_url":"https://api.github.com/users/acslk/followers","following_url":"https://api.github.com/users/acslk/following{/other_user}","gists_url":"https://api.github.com/users/acslk/gists{/gist_id}","starred_url":"https://api.github.com/users/acslk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/acslk/subscriptions","organizations_url":"https://api.github.com/users/acslk/orgs","repos_url":"https://api.github.com/users/acslk/repos","events_url":"https://api.github.com/users/acslk/events{/privacy}","received_events_url":"https://api.github.com/users/acslk/received_events","type":"User","site_admin":false},"body":"#2766 \r\nAdded runner that optimizes the dimension filter for TimeSeries, Search, and Select queries. Note these query types are the only queries other than TopN and GroupBy that has dimension filter. The runner is added in preMergeQueryDecoration of QueryToolChest, which should only be called on the broker once for each query.","created_at":"2016-05-06T21:57:45Z","updated_at":"2016-05-06T23:37:09Z","closed_at":null,"merged_at":null,"merge_commit_sha":"99530e0b42ced4df851416b6bd07dad8203abbcb","assignee":null,"milestone":{"url":"https://api.github.com/repos/druid-io/druid/milestones/18","html_url":"https://github.com/druid-io/druid/milestones/0.9.1","labels_url":"https://api.github.com/repos/druid-io/druid/milestones/18/labels","id":1526819,"number":18,"title":"0.9.1","description":"","creator":{"login":"fjy","id":428325,"avatar_url":"https://avatars.githubusercontent.com/u/428325?v=3","gravatar_id":"","url":"https://api.github.com/users/fjy","html_url":"https://github.com/fjy","followers_url":"https://api.github.com/users/fjy/followers","following_url":"https://api.github.com/users/fjy/following{/other_user}","gists_url":"https://api.github.com/users/fjy/gists{/gist_id}","starred_url":"https://api.github.com/users/fjy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fjy/subscriptions","organizations_url":"https://api.github.com/users/fjy/orgs","repos_url":"https://api.github.com/users/fjy/repos","events_url":"https://api.github.com/users/fjy/events{/privacy}","received_events_url":"https://api.github.com/users/fjy/received_events","type":"User","site_admin":false},"open_issues":12,"closed_issues":237,"state":"open","created_at":"2016-01-20T19:04:22Z","updated_at":"2016-05-06T23:08:09Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/druid-io/druid/pulls/2931/commits","review_comments_url":"https://api.github.com/repos/druid-io/druid/pulls/2931/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/2931/comments","statuses_url":"https://api.github.com/repos/druid-io/druid/statuses/895e0c7fc986306366a2058d4637807cef02f877","head":{"label":"acslk:feature-opt","ref":"feature-opt","sha":"895e0c7fc986306366a2058d4637807cef02f877","user":{"login":"acslk","id":11131839,"avatar_url":"https://avatars.githubusercontent.com/u/11131839?v=3","gravatar_id":"","url":"https://api.github.com/users/acslk","html_url":"https://github.com/acslk","followers_url":"https://api.github.com/users/acslk/followers","following_url":"https://api.github.com/users/acslk/following{/other_user}","gists_url":"https://api.github.com/users/acslk/gists{/gist_id}","starred_url":"https://api.github.com/users/acslk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/acslk/subscriptions","organizations_url":"https://api.github.com/users/acslk/orgs","repos_url":"https://api.github.com/users/acslk/repos","events_url":"https://api.github.com/users/acslk/events{/privacy}","received_events_url":"https://api.github.com/users/acslk/received_events","type":"User","site_admin":false},"repo":{"id":58234003,"name":"druid","full_name":"acslk/druid","owner":{"login":"acslk","id":11131839,"avatar_url":"https://avatars.githubusercontent.com/u/11131839?v=3","gravatar_id":"","url":"https://api.github.com/users/acslk","html_url":"https://github.com/acslk","followers_url":"https://api.github.com/users/acslk/followers","following_url":"https://api.github.com/users/acslk/following{/other_user}","gists_url":"https://api.github.com/users/acslk/gists{/gist_id}","starred_url":"https://api.github.com/users/acslk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/acslk/subscriptions","organizations_url":"https://api.github.com/users/acslk/orgs","repos_url":"https://api.github.com/users/acslk/repos","events_url":"https://api.github.com/users/acslk/events{/privacy}","received_events_url":"https://api.github.com/users/acslk/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/acslk/druid","description":"Column oriented distributed data store ideal for powering interactive applications","fork":true,"url":"https://api.github.com/repos/acslk/druid","forks_url":"https://api.github.com/repos/acslk/druid/forks","keys_url":"https://api.github.com/repos/acslk/druid/keys{/key_id}","collaborators_url":"https://api.github.com/repos/acslk/druid/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/acslk/druid/teams","hooks_url":"https://api.github.com/repos/acslk/druid/hooks","issue_events_url":"https://api.github.com/repos/acslk/druid/issues/events{/number}","events_url":"https://api.github.com/repos/acslk/druid/events","assignees_url":"https://api.github.com/repos/acslk/druid/assignees{/user}","branches_url":"https://api.github.com/repos/acslk/druid/branches{/branch}","tags_url":"https://api.github.com/repos/acslk/druid/tags","blobs_url":"https://api.github.com/repos/acslk/druid/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/acslk/druid/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/acslk/druid/git/refs{/sha}","trees_url":"https://api.github.com/repos/acslk/druid/git/trees{/sha}","statuses_url":"https://api.github.com/repos/acslk/druid/statuses/{sha}","languages_url":"https://api.github.com/repos/acslk/druid/languages","stargazers_url":"https://api.github.com/repos/acslk/druid/stargazers","contributors_url":"https://api.github.com/repos/acslk/druid/contributors","subscribers_url":"https://api.github.com/repos/acslk/druid/subscribers","subscription_url":"https://api.github.com/repos/acslk/druid/subscription","commits_url":"https://api.github.com/repos/acslk/druid/commits{/sha}","git_commits_url":"https://api.github.com/repos/acslk/druid/git/commits{/sha}","comments_url":"https://api.github.com/repos/acslk/druid/comments{/number}","issue_comment_url":"https://api.github.com/repos/acslk/druid/issues/comments{/number}","contents_url":"https://api.github.com/repos/acslk/druid/contents/{+path}","compare_url":"https://api.github.com/repos/acslk/druid/compare/{base}...{head}","merges_url":"https://api.github.com/repos/acslk/druid/merges","archive_url":"https://api.github.com/repos/acslk/druid/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/acslk/druid/downloads","issues_url":"https://api.github.com/repos/acslk/druid/issues{/number}","pulls_url":"https://api.github.com/repos/acslk/druid/pulls{/number}","milestones_url":"https://api.github.com/repos/acslk/druid/milestones{/number}","notifications_url":"https://api.github.com/repos/acslk/druid/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/acslk/druid/labels{/name}","releases_url":"https://api.github.com/repos/acslk/druid/releases{/id}","deployments_url":"https://api.github.com/repos/acslk/druid/deployments","created_at":"2016-05-06T20:47:11Z","updated_at":"2016-05-06T20:47:19Z","pushed_at":"2016-05-06T22:35:21Z","git_url":"git://github.com/acslk/druid.git","ssh_url":"git@github.com:acslk/druid.git","clone_url":"https://github.com/acslk/druid.git","svn_url":"https://github.com/acslk/druid","homepage":"http://druid.io","size":106189,"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":"druid-io:master","ref":"master","sha":"8b570ab1301f8dd4ebd7839d7bd5bc47b0a92188","user":{"login":"druid-io","id":4203474,"avatar_url":"https://avatars.githubusercontent.com/u/4203474?v=3","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://avatars.githubusercontent.com/u/4203474?v=3","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":"2016-05-06T19:32:37Z","pushed_at":"2016-05-06T23:20:31Z","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":129589,"stargazers_count":3177,"watchers_count":3177,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":696,"mirror_url":null,"open_issues_count":416,"forks":696,"open_issues":416,"watchers":3177,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/druid-io/druid/pulls/2931"},"html":{"href":"https://github.com/druid-io/druid/pull/2931"},"issue":{"href":"https://api.github.com/repos/druid-io/druid/issues/2931"},"comments":{"href":"https://api.github.com/repos/druid-io/druid/issues/2931/comments"},"review_comments":{"href":"https://api.github.com/repos/druid-io/druid/pulls/2931/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/2931/commits"},"statuses":{"href":"https://api.github.com/repos/druid-io/druid/statuses/895e0c7fc986306366a2058d4637807cef02f877"}}}}