{"action":"created","issue":{"url":"https://api.github.com/repos/elasticsearch/elasticsearch/issues/9199","labels_url":"https://api.github.com/repos/elasticsearch/elasticsearch/issues/9199/labels{/name}","comments_url":"https://api.github.com/repos/elasticsearch/elasticsearch/issues/9199/comments","events_url":"https://api.github.com/repos/elasticsearch/elasticsearch/issues/9199/events","html_url":"https://github.com/elasticsearch/elasticsearch/pull/9199","id":53761040,"number":9199,"title":"Nested sorting: only use random access bitset for parent","user":{"login":"martijnvg","id":580421,"avatar_url":"https://avatars.githubusercontent.com/u/580421?v=3","gravatar_id":"","url":"https://api.github.com/users/martijnvg","html_url":"https://github.com/martijnvg","followers_url":"https://api.github.com/users/martijnvg/followers","following_url":"https://api.github.com/users/martijnvg/following{/other_user}","gists_url":"https://api.github.com/users/martijnvg/gists{/gist_id}","starred_url":"https://api.github.com/users/martijnvg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/martijnvg/subscriptions","organizations_url":"https://api.github.com/users/martijnvg/orgs","repos_url":"https://api.github.com/users/martijnvg/repos","events_url":"https://api.github.com/users/martijnvg/events{/privacy}","received_events_url":"https://api.github.com/users/martijnvg/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/elasticsearch/elasticsearch/labels/review","name":"review","color":"0052cc"},{"url":"https://api.github.com/repos/elasticsearch/elasticsearch/labels/v1.4.3","name":"v1.4.3","color":"dddddd"},{"url":"https://api.github.com/repos/elasticsearch/elasticsearch/labels/v1.5.0","name":"v1.5.0","color":"dddddd"},{"url":"https://api.github.com/repos/elasticsearch/elasticsearch/labels/v2.0.0","name":"v2.0.0","color":"dddddd"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-01-08T15:16:38Z","updated_at":"2015-01-19T23:32:47Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/elasticsearch/elasticsearch/pulls/9199","html_url":"https://github.com/elasticsearch/elasticsearch/pull/9199","diff_url":"https://github.com/elasticsearch/elasticsearch/pull/9199.diff","patch_url":"https://github.com/elasticsearch/elasticsearch/pull/9199.patch"},"body":"By executing in docid order the nested sorting doesn't need two random access bitsets, but just one (the parent bitset). In practise for mappings with only single level nested fields this means that only one bitset needs to be put in the bitset cache.\r\n\r\nBecause FieldComparator can't tell the IndexSearcher to not execute out of order like a Collector, this PR adds a setting the SearchContext that enforces in order docid execution, which the sort parsing enables if it encounters nested sorting. This was the cleanest way I could find in order for nested sorting to not use many bitsets which get cached by the bitset cache.\r\n\r\nPR for #8810"},"comment":{"url":"https://api.github.com/repos/elasticsearch/elasticsearch/issues/comments/70579741","html_url":"https://github.com/elasticsearch/elasticsearch/pull/9199#issuecomment-70579741","issue_url":"https://api.github.com/repos/elasticsearch/elasticsearch/issues/9199","id":70579741,"user":{"login":"jpountz","id":299848,"avatar_url":"https://avatars.githubusercontent.com/u/299848?v=3","gravatar_id":"","url":"https://api.github.com/users/jpountz","html_url":"https://github.com/jpountz","followers_url":"https://api.github.com/users/jpountz/followers","following_url":"https://api.github.com/users/jpountz/following{/other_user}","gists_url":"https://api.github.com/users/jpountz/gists{/gist_id}","starred_url":"https://api.github.com/users/jpountz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jpountz/subscriptions","organizations_url":"https://api.github.com/users/jpountz/orgs","repos_url":"https://api.github.com/users/jpountz/repos","events_url":"https://api.github.com/users/jpountz/events{/privacy}","received_events_url":"https://api.github.com/users/jpountz/received_events","type":"User","site_admin":false},"created_at":"2015-01-19T23:32:47Z","updated_at":"2015-01-19T23:32:47Z","body":"How important is it to have this change on 1.x?"}}