GitHub PullRequestReviewCommentEvent at 2014-09-02 13:33:33
Repository: geomesa
Actor: ronq
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/locationtech/geomesa/pulls/comments/16986477","id":16986477,"diff_hunk":"@@ -148,4 +148,21 @@ object FilterHelper {\n     case Nil => None\n     case _ => Some(ff.and(filters))\n   }\n+\n+  def pickout(pred: Filter => Boolean)(s: Seq[Filter]): (Option[Filter], Seq[Filter]) =\n+    if (s.isEmpty) (None, s) else {\n+      val h = s.head\n+      val t = s.tail\n+      if (pred(h)) (Some(h), t) else {\n+        val (x, xs) = pickout(pred)(t)\n+        (x, h +: xs)\n+      }\n+    }\n+\n+  def decomposeAnd(f: Filter): Seq[Filter] = {\n+    f match {\n+      case b: And => b.getChildren.toSeq.flatMap(decomposeAnd)\n+      case f: Filter => Seq(f)\n+    }\n+  }","path":"geomesa-core/src/main/scala/org/locationtech/geomesa/core/index/FilterHelper.scala","position":29,"original_position":29,"commit_id":"19e6b2218d56c62f09a4a176e6f43a85856243f7","original_commit_id":"19e6b2218d56c62f09a4a176e6f43a85856243f7","user":{"login":"ronq","id":5257756,"avatar_url":"https://avatars.githubusercontent.com/u/5257756?v=2","gravatar_id":"90c634d0b668abb35c72667ddd060bc1","url":"https://api.github.com/users/ronq","html_url":"https://github.com/ronq","followers_url":"https://api.github.com/users/ronq/followers","following_url":"https://api.github.com/users/ronq/following{/other_user}","gists_url":"https://api.github.com/users/ronq/gists{/gist_id}","starred_url":"https://api.github.com/users/ronq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ronq/subscriptions","organizations_url":"https://api.github.com/users/ronq/orgs","repos_url":"https://api.github.com/users/ronq/repos","events_url":"https://api.github.com/users/ronq/events{/privacy}","received_events_url":"https://api.github.com/users/ronq/received_events","type":"User","site_admin":false},"body":"And perhaps move `filterListAsAnd` as well. \r\n\r\nIf not, then we should do the inverse, and move everything into `FilterHelper`","created_at":"2014-09-02T13:33:33Z","updated_at":"2014-09-02T13:33:33Z","html_url":"https://github.com/locationtech/geomesa/pull/269#discussion_r16986477","pull_request_url":"https://api.github.com/repos/locationtech/geomesa/pulls/269","_links":{"self":{"href":"https://api.github.com/repos/locationtech/geomesa/pulls/comments/16986477"},"html":{"href":"https://github.com/locationtech/geomesa/pull/269#discussion_r16986477"},"pull_request":{"href":"https://api.github.com/repos/locationtech/geomesa/pulls/269"}}},"pull_request":{"url":"https://api.github.com/repos/locationtech/geomesa/pulls/269","id":20508219,"html_url":"https://github.com/locationtech/geomesa/pull/269","diff_url":"https://github.com/locationtech/geomesa/pull/269.diff","patch_url":"https://github.com/locationtech/geomesa/pull/269.patch","issue_url":"https://api.github.com/repos/locationtech/geomesa/issues/269","number":269,"state":"open","locked":false,"title":"GEOMESA-313 Handle Id and * queries","user":{"login":"ronq","id":5257756,"avatar_url":"https://avatars.githubusercontent.com/u/5257756?v=2","gravatar_id":"90c634d0b668abb35c72667ddd060bc1","url":"https://api.github.com/users/ronq","html_url":"https://github.com/ronq","followers_url":"https://api.github.com/users/ronq/followers","following_url":"https://api.github.com/users/ronq/following{/other_user}","gists_url":"https://api.github.com/users/ronq/gists{/gist_id}","starred_url":"https://api.github.com/users/ronq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ronq/subscriptions","organizations_url":"https://api.github.com/users/ronq/orgs","repos_url":"https://api.github.com/users/ronq/repos","events_url":"https://api.github.com/users/ronq/events{/privacy}","received_events_url":"https://api.github.com/users/ronq/received_events","type":"User","site_admin":false},"body":"When an ID predicate is present in the ECQL filter, a scan of the record table is performed, optionally with SimpleFeature Filtering, regardless of the type of the other ECQL predicates.","created_at":"2014-08-29T16:05:28Z","updated_at":"2014-09-02T13:33:33Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4b159a7d0c01706df658810cef5c3c45dd6bc5a1","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/locationtech/geomesa/pulls/269/commits","review_comments_url":"https://api.github.com/repos/locationtech/geomesa/pulls/269/comments","review_comment_url":"https://api.github.com/repos/locationtech/geomesa/pulls/comments/{number}","comments_url":"https://api.github.com/repos/locationtech/geomesa/issues/269/comments","statuses_url":"https://api.github.com/repos/locationtech/geomesa/statuses/19e6b2218d56c62f09a4a176e6f43a85856243f7","head":{"label":"ronq:f_id_and","ref":"f_id_and","sha":"19e6b2218d56c62f09a4a176e6f43a85856243f7","user":{"login":"ronq","id":5257756,"avatar_url":"https://avatars.githubusercontent.com/u/5257756?v=2","gravatar_id":"90c634d0b668abb35c72667ddd060bc1","url":"https://api.github.com/users/ronq","html_url":"https://github.com/ronq","followers_url":"https://api.github.com/users/ronq/followers","following_url":"https://api.github.com/users/ronq/following{/other_user}","gists_url":"https://api.github.com/users/ronq/gists{/gist_id}","starred_url":"https://api.github.com/users/ronq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ronq/subscriptions","organizations_url":"https://api.github.com/users/ronq/orgs","repos_url":"https://api.github.com/users/ronq/repos","events_url":"https://api.github.com/users/ronq/events{/privacy}","received_events_url":"https://api.github.com/users/ronq/received_events","type":"User","site_admin":false},"repo":{"id":20961229,"name":"geomesa","full_name":"ronq/geomesa","owner":{"login":"ronq","id":5257756,"avatar_url":"https://avatars.githubusercontent.com/u/5257756?v=2","gravatar_id":"90c634d0b668abb35c72667ddd060bc1","url":"https://api.github.com/users/ronq","html_url":"https://github.com/ronq","followers_url":"https://api.github.com/users/ronq/followers","following_url":"https://api.github.com/users/ronq/following{/other_user}","gists_url":"https://api.github.com/users/ronq/gists{/gist_id}","starred_url":"https://api.github.com/users/ronq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ronq/subscriptions","organizations_url":"https://api.github.com/users/ronq/orgs","repos_url":"https://api.github.com/users/ronq/repos","events_url":"https://api.github.com/users/ronq/events{/privacy}","received_events_url":"https://api.github.com/users/ronq/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ronq/geomesa","description":"","fork":true,"url":"https://api.github.com/repos/ronq/geomesa","forks_url":"https://api.github.com/repos/ronq/geomesa/forks","keys_url":"https://api.github.com/repos/ronq/geomesa/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ronq/geomesa/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ronq/geomesa/teams","hooks_url":"https://api.github.com/repos/ronq/geomesa/hooks","issue_events_url":"https://api.github.com/repos/ronq/geomesa/issues/events{/number}","events_url":"https://api.github.com/repos/ronq/geomesa/events","assignees_url":"https://api.github.com/repos/ronq/geomesa/assignees{/user}","branches_url":"https://api.github.com/repos/ronq/geomesa/branches{/branch}","tags_url":"https://api.github.com/repos/ronq/geomesa/tags","blobs_url":"https://api.github.com/repos/ronq/geomesa/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ronq/geomesa/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ronq/geomesa/git/refs{/sha}","trees_url":"https://api.github.com/repos/ronq/geomesa/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ronq/geomesa/statuses/{sha}","languages_url":"https://api.github.com/repos/ronq/geomesa/languages","stargazers_url":"https://api.github.com/repos/ronq/geomesa/stargazers","contributors_url":"https://api.github.com/repos/ronq/geomesa/contributors","subscribers_url":"https://api.github.com/repos/ronq/geomesa/subscribers","subscription_url":"https://api.github.com/repos/ronq/geomesa/subscription","commits_url":"https://api.github.com/repos/ronq/geomesa/commits{/sha}","git_commits_url":"https://api.github.com/repos/ronq/geomesa/git/commits{/sha}","comments_url":"https://api.github.com/repos/ronq/geomesa/comments{/number}","issue_comment_url":"https://api.github.com/repos/ronq/geomesa/issues/comments/{number}","contents_url":"https://api.github.com/repos/ronq/geomesa/contents/{+path}","compare_url":"https://api.github.com/repos/ronq/geomesa/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ronq/geomesa/merges","archive_url":"https://api.github.com/repos/ronq/geomesa/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ronq/geomesa/downloads","issues_url":"https://api.github.com/repos/ronq/geomesa/issues{/number}","pulls_url":"https://api.github.com/repos/ronq/geomesa/pulls{/number}","milestones_url":"https://api.github.com/repos/ronq/geomesa/milestones{/number}","notifications_url":"https://api.github.com/repos/ronq/geomesa/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ronq/geomesa/labels{/name}","releases_url":"https://api.github.com/repos/ronq/geomesa/releases{/id}","created_at":"2014-06-18T12:29:23Z","updated_at":"2014-07-22T21:27:38Z","pushed_at":"2014-09-01T17:57:48Z","git_url":"git://github.com/ronq/geomesa.git","ssh_url":"git@github.com:ronq/geomesa.git","clone_url":"https://github.com/ronq/geomesa.git","svn_url":"https://github.com/ronq/geomesa","homepage":null,"size":3682,"stargazers_count":0,"watchers_count":0,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"accumulo1.5.x/1.x"}},"base":{"label":"locationtech:rel_breaking_changes_1.5","ref":"rel_breaking_changes_1.5","sha":"51cbd0fcdf3906ee6b5ffd6719d6018f806cd983","user":{"login":"locationtech","id":1991411,"avatar_url":"https://avatars.githubusercontent.com/u/1991411?v=2","gravatar_id":"c043b60ab8bed0c48ca8252132150aa8","url":"https://api.github.com/users/locationtech","html_url":"https://github.com/locationtech","followers_url":"https://api.github.com/users/locationtech/followers","following_url":"https://api.github.com/users/locationtech/following{/other_user}","gists_url":"https://api.github.com/users/locationtech/gists{/gist_id}","starred_url":"https://api.github.com/users/locationtech/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/locationtech/subscriptions","organizations_url":"https://api.github.com/users/locationtech/orgs","repos_url":"https://api.github.com/users/locationtech/repos","events_url":"https://api.github.com/users/locationtech/events{/privacy}","received_events_url":"https://api.github.com/users/locationtech/received_events","type":"Organization","site_admin":false},"repo":{"id":13226069,"name":"geomesa","full_name":"locationtech/geomesa","owner":{"login":"locationtech","id":1991411,"avatar_url":"https://avatars.githubusercontent.com/u/1991411?v=2","gravatar_id":"c043b60ab8bed0c48ca8252132150aa8","url":"https://api.github.com/users/locationtech","html_url":"https://github.com/locationtech","followers_url":"https://api.github.com/users/locationtech/followers","following_url":"https://api.github.com/users/locationtech/following{/other_user}","gists_url":"https://api.github.com/users/locationtech/gists{/gist_id}","starred_url":"https://api.github.com/users/locationtech/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/locationtech/subscriptions","organizations_url":"https://api.github.com/users/locationtech/orgs","repos_url":"https://api.github.com/users/locationtech/repos","events_url":"https://api.github.com/users/locationtech/events{/privacy}","received_events_url":"https://api.github.com/users/locationtech/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/locationtech/geomesa","description":"","fork":false,"url":"https://api.github.com/repos/locationtech/geomesa","forks_url":"https://api.github.com/repos/locationtech/geomesa/forks","keys_url":"https://api.github.com/repos/locationtech/geomesa/keys{/key_id}","collaborators_url":"https://api.github.com/repos/locationtech/geomesa/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/locationtech/geomesa/teams","hooks_url":"https://api.github.com/repos/locationtech/geomesa/hooks","issue_events_url":"https://api.github.com/repos/locationtech/geomesa/issues/events{/number}","events_url":"https://api.github.com/repos/locationtech/geomesa/events","assignees_url":"https://api.github.com/repos/locationtech/geomesa/assignees{/user}","branches_url":"https://api.github.com/repos/locationtech/geomesa/branches{/branch}","tags_url":"https://api.github.com/repos/locationtech/geomesa/tags","blobs_url":"https://api.github.com/repos/locationtech/geomesa/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/locationtech/geomesa/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/locationtech/geomesa/git/refs{/sha}","trees_url":"https://api.github.com/repos/locationtech/geomesa/git/trees{/sha}","statuses_url":"https://api.github.com/repos/locationtech/geomesa/statuses/{sha}","languages_url":"https://api.github.com/repos/locationtech/geomesa/languages","stargazers_url":"https://api.github.com/repos/locationtech/geomesa/stargazers","contributors_url":"https://api.github.com/repos/locationtech/geomesa/contributors","subscribers_url":"https://api.github.com/repos/locationtech/geomesa/subscribers","subscription_url":"https://api.github.com/repos/locationtech/geomesa/subscription","commits_url":"https://api.github.com/repos/locationtech/geomesa/commits{/sha}","git_commits_url":"https://api.github.com/repos/locationtech/geomesa/git/commits{/sha}","comments_url":"https://api.github.com/repos/locationtech/geomesa/comments{/number}","issue_comment_url":"https://api.github.com/repos/locationtech/geomesa/issues/comments/{number}","contents_url":"https://api.github.com/repos/locationtech/geomesa/contents/{+path}","compare_url":"https://api.github.com/repos/locationtech/geomesa/compare/{base}...{head}","merges_url":"https://api.github.com/repos/locationtech/geomesa/merges","archive_url":"https://api.github.com/repos/locationtech/geomesa/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/locationtech/geomesa/downloads","issues_url":"https://api.github.com/repos/locationtech/geomesa/issues{/number}","pulls_url":"https://api.github.com/repos/locationtech/geomesa/pulls{/number}","milestones_url":"https://api.github.com/repos/locationtech/geomesa/milestones{/number}","notifications_url":"https://api.github.com/repos/locationtech/geomesa/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/locationtech/geomesa/labels{/name}","releases_url":"https://api.github.com/repos/locationtech/geomesa/releases{/id}","created_at":"2013-09-30T20:13:46Z","updated_at":"2014-09-02T12:49:31Z","pushed_at":"2014-09-02T12:50:32Z","git_url":"git://github.com/locationtech/geomesa.git","ssh_url":"git@github.com:locationtech/geomesa.git","clone_url":"https://github.com/locationtech/geomesa.git","svn_url":"https://github.com/locationtech/geomesa","homepage":null,"size":15508,"stargazers_count":22,"watchers_count":22,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":false,"forks_count":20,"mirror_url":null,"open_issues_count":7,"forks":20,"open_issues":7,"watchers":22,"default_branch":"accumulo1.5.x/1.x"}},"_links":{"self":{"href":"https://api.github.com/repos/locationtech/geomesa/pulls/269"},"html":{"href":"https://github.com/locationtech/geomesa/pull/269"},"issue":{"href":"https://api.github.com/repos/locationtech/geomesa/issues/269"},"comments":{"href":"https://api.github.com/repos/locationtech/geomesa/issues/269/comments"},"review_comments":{"href":"https://api.github.com/repos/locationtech/geomesa/pulls/269/comments"},"review_comment":{"href":"https://api.github.com/repos/locationtech/geomesa/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/locationtech/geomesa/pulls/269/commits"},"statuses":{"href":"https://api.github.com/repos/locationtech/geomesa/statuses/19e6b2218d56c62f09a4a176e6f43a85856243f7"}}}}