)]}'
{"doc/source/searchlightapi.rst":[{"author":{"_account_id":7665,"name":"Travis Tripp","email":"os.travis.tripp@gmail.com","username":"travis.tripp"},"change_message_id":"28d438bd07951db00ea7a19da8293f0315d58b82","unresolved":false,"context_lines":[{"line_number":549,"context_line":"It is possible to not return any options for facets. By default all options"},{"line_number":550,"context_line":"are returned for fields that support facet terms. Adding"},{"line_number":551,"context_line":"``exclude_options\u003dtrue`` as a query parameter will return only the facet"},{"line_number":552,"context_line":"field and not any of the options."},{"line_number":553,"context_line":""},{"line_number":554,"context_line":"Freeform queries"},{"line_number":555,"context_line":"****************"}],"source_content_type":"text/x-rst","patch_set":1,"id":"9a89bdaa_b3250b5d","line":552,"updated":"2016-09-08 01:33:21.000000000","message":"Also: This is specifically intended as a way to provide a performance boost and reduce load on ElasticSearch. Using this option will avoid causing an actual aggregation query to be performed.","commit_id":"917935270e8e55f9b8b5fd46afb5ad3cf03aab3f"},{"author":{"_account_id":14680,"name":"Rick Aulino","email":"rick.aulino@hpe.com","username":"ricka"},"change_message_id":"f6e90cebb15685a4efa9ed0fbb61ab3465949579","unresolved":false,"context_lines":[{"line_number":549,"context_line":"It is possible to not return any options for facets. By default all options"},{"line_number":550,"context_line":"are returned for fields that support facet terms. Adding"},{"line_number":551,"context_line":"``exclude_options\u003dtrue`` as a query parameter will return only the facet"},{"line_number":552,"context_line":"field and not any of the options."},{"line_number":553,"context_line":""},{"line_number":554,"context_line":"Freeform queries"},{"line_number":555,"context_line":"****************"}],"source_content_type":"text/x-rst","patch_set":1,"id":"9a89bdaa_8450bf0c","line":552,"in_reply_to":"9a89bdaa_b3250b5d","updated":"2016-09-08 03:43:08.000000000","message":"Done.","commit_id":"917935270e8e55f9b8b5fd46afb5ad3cf03aab3f"}],"releasenotes/notes/bug-1557778-facet-options-798bba4cb4e3067a.yaml":[{"author":{"_account_id":7665,"name":"Travis Tripp","email":"os.travis.tripp@gmail.com","username":"travis.tripp"},"change_message_id":"28d438bd07951db00ea7a19da8293f0315d58b82","unresolved":false,"context_lines":[{"line_number":6,"context_line":"    information relating to a facet field, including"},{"line_number":7,"context_line":"    the options. The new parameter \"exclude_options\""},{"line_number":8,"context_line":"    to the facet endpoint will prevent the options"},{"line_number":9,"context_line":"    for all facet fields from being returned."}],"source_content_type":"text/x-yaml","patch_set":1,"id":"9a89bdaa_f3231354","line":9,"updated":"2016-09-08 01:33:21.000000000","message":"This avoid aggregation queries from being performed against elastic search, which improves performance.","commit_id":"917935270e8e55f9b8b5fd46afb5ad3cf03aab3f"},{"author":{"_account_id":14680,"name":"Rick Aulino","email":"rick.aulino@hpe.com","username":"ricka"},"change_message_id":"f6e90cebb15685a4efa9ed0fbb61ab3465949579","unresolved":false,"context_lines":[{"line_number":6,"context_line":"    information relating to a facet field, including"},{"line_number":7,"context_line":"    the options. The new parameter \"exclude_options\""},{"line_number":8,"context_line":"    to the facet endpoint will prevent the options"},{"line_number":9,"context_line":"    for all facet fields from being returned."}],"source_content_type":"text/x-yaml","patch_set":1,"id":"9a89bdaa_a4530316","line":9,"in_reply_to":"9a89bdaa_f3231354","updated":"2016-09-08 03:43:08.000000000","message":"Done.","commit_id":"917935270e8e55f9b8b5fd46afb5ad3cf03aab3f"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"44386b02a38ed2c223dbbae959d4844f8c68ff7a","unresolved":false,"context_lines":[{"line_number":4,"context_line":"features:"},{"line_number":5,"context_line":"  - Currently the \"facet\" endpoint will return all"},{"line_number":6,"context_line":"    information relating to a facet field, including"},{"line_number":7,"context_line":"    the options. The new parameter \"exclude_options\""},{"line_number":8,"context_line":"    to the facet endpoint will prevent the options"},{"line_number":9,"context_line":"    for all facet fields from being returned. This option"},{"line_number":10,"context_line":"    will avoid an aggregation query being performed"},{"line_number":11,"context_line":"    on Elasticsearch, improving performance."}],"source_content_type":"text/x-yaml","patch_set":2,"id":"9a89bdaa_a2284e9b","line":11,"range":{"start_line":7,"start_character":17,"end_line":11,"end_character":44},"updated":"2016-09-08 08:09:37.000000000","message":"nit: should we mention the default behavior here? Is the default as is or is it the new way? I saw false in the code :-)","commit_id":"6a7164a192f0e847efe20bdfd303e15f8b9b56ca"},{"author":{"_account_id":14680,"name":"Rick Aulino","email":"rick.aulino@hpe.com","username":"ricka"},"change_message_id":"7e808422164f0fcb7bdb47ba0d6d3348fbeec6fd","unresolved":false,"context_lines":[{"line_number":4,"context_line":"features:"},{"line_number":5,"context_line":"  - Currently the \"facet\" endpoint will return all"},{"line_number":6,"context_line":"    information relating to a facet field, including"},{"line_number":7,"context_line":"    the options. The new parameter \"exclude_options\""},{"line_number":8,"context_line":"    to the facet endpoint will prevent the options"},{"line_number":9,"context_line":"    for all facet fields from being returned. This option"},{"line_number":10,"context_line":"    will avoid an aggregation query being performed"},{"line_number":11,"context_line":"    on Elasticsearch, improving performance."}],"source_content_type":"text/x-yaml","patch_set":2,"id":"9a89bdaa_2aea31db","line":11,"range":{"start_line":7,"start_character":17,"end_line":11,"end_character":44},"in_reply_to":"9a89bdaa_a2284e9b","updated":"2016-09-08 21:35:14.000000000","message":"The default behavior remains unchanged. The double negative in the code where \"\u0027exclude\u0027 \u003d\u003d false means \u0027include\u0027\" can be confusing :). But I think that\u0027s the nature of not not changing the default behavior. Since it wasn\u0027t clear, I\u0027ll modify the release note as you suggested.","commit_id":"6a7164a192f0e847efe20bdfd303e15f8b9b56ca"}],"searchlight/elasticsearch/plugins/base.py":[{"author":{"_account_id":16150,"name":"Lei Zhang","email":"lei.a.zhang@intel.com","username":"leizhang"},"change_message_id":"a55092db21742c49404906f0e31682dcd770293d","unresolved":false,"context_lines":[{"line_number":268,"context_line":"                           else field"},{"line_number":269,"context_line":"                           for field in options_fields]"},{"line_number":270,"context_line":""},{"line_number":271,"context_line":"        facet_terms, doc_count \u003d self._get_facet_terms("},{"line_number":272,"context_line":"            facet_terms_for, request_context, all_projects,"},{"line_number":273,"context_line":"            limit_terms\u003dlimit_terms)"},{"line_number":274,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9a89bdaa_e455e2f9","line":271,"updated":"2016-09-08 16:19:58.000000000","message":"The code still runs the aggregation in _get_facet_terms to fetch field options even if \u0027exclude_options\u0027 is true, it just ignore options result, right? It won\u0027t do help to performance boost.","commit_id":"6a7164a192f0e847efe20bdfd303e15f8b9b56ca"},{"author":{"_account_id":10063,"name":"Steve McLellan","email":"steven.j.mclellan@gmail.com","username":"sjmc7"},"change_message_id":"298d7c5afae842ecce9c05c8d93db7721f009af0","unresolved":false,"context_lines":[{"line_number":268,"context_line":"                           else field"},{"line_number":269,"context_line":"                           for field in options_fields]"},{"line_number":270,"context_line":""},{"line_number":271,"context_line":"        facet_terms, doc_count \u003d self._get_facet_terms("},{"line_number":272,"context_line":"            facet_terms_for, request_context, all_projects,"},{"line_number":273,"context_line":"            limit_terms\u003dlimit_terms)"},{"line_number":274,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9a89bdaa_deb26605","line":271,"in_reply_to":"9a89bdaa_e455e2f9","updated":"2016-09-08 17:18:30.000000000","message":"Right - the flag will need passing through to get_facet terms","commit_id":"6a7164a192f0e847efe20bdfd303e15f8b9b56ca"},{"author":{"_account_id":14680,"name":"Rick Aulino","email":"rick.aulino@hpe.com","username":"ricka"},"change_message_id":"7e808422164f0fcb7bdb47ba0d6d3348fbeec6fd","unresolved":false,"context_lines":[{"line_number":268,"context_line":"                           else field"},{"line_number":269,"context_line":"                           for field in options_fields]"},{"line_number":270,"context_line":""},{"line_number":271,"context_line":"        facet_terms, doc_count \u003d self._get_facet_terms("},{"line_number":272,"context_line":"            facet_terms_for, request_context, all_projects,"},{"line_number":273,"context_line":"            limit_terms\u003dlimit_terms)"},{"line_number":274,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9a89bdaa_41111b51","line":271,"in_reply_to":"9a89bdaa_e455e2f9","updated":"2016-09-08 21:35:14.000000000","message":"Yes. I didn\u0027t realize that was required until talking with Travis late yesterday. Fixed.","commit_id":"6a7164a192f0e847efe20bdfd303e15f8b9b56ca"},{"author":{"_account_id":10063,"name":"Steve McLellan","email":"steven.j.mclellan@gmail.com","username":"sjmc7"},"change_message_id":"298d7c5afae842ecce9c05c8d93db7721f009af0","unresolved":false,"context_lines":[{"line_number":272,"context_line":"            facet_terms_for, request_context, all_projects,"},{"line_number":273,"context_line":"            limit_terms\u003dlimit_terms)"},{"line_number":274,"context_line":""},{"line_number":275,"context_line":"        if not exclude_options:"},{"line_number":276,"context_line":"            if include_fields:"},{"line_number":277,"context_line":"                for facet in facets:"},{"line_number":278,"context_line":"                    if facet[\u0027name\u0027] in facet_terms:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9a89bdaa_9e8a9e19","line":275,"range":{"start_line":275,"start_character":14,"end_line":275,"end_character":15},"updated":"2016-09-08 17:18:30.000000000","message":"put the conditional on one line","commit_id":"6a7164a192f0e847efe20bdfd303e15f8b9b56ca"},{"author":{"_account_id":14680,"name":"Rick Aulino","email":"rick.aulino@hpe.com","username":"ricka"},"change_message_id":"7e808422164f0fcb7bdb47ba0d6d3348fbeec6fd","unresolved":false,"context_lines":[{"line_number":272,"context_line":"            facet_terms_for, request_context, all_projects,"},{"line_number":273,"context_line":"            limit_terms\u003dlimit_terms)"},{"line_number":274,"context_line":""},{"line_number":275,"context_line":"        if not exclude_options:"},{"line_number":276,"context_line":"            if include_fields:"},{"line_number":277,"context_line":"                for facet in facets:"},{"line_number":278,"context_line":"                    if facet[\u0027name\u0027] in facet_terms:"}],"source_content_type":"text/x-python","patch_set":2,"id":"9a89bdaa_d385f459","line":275,"range":{"start_line":275,"start_character":14,"end_line":275,"end_character":15},"in_reply_to":"9a89bdaa_9e8a9e19","updated":"2016-09-08 21:35:14.000000000","message":"Removed all together.","commit_id":"6a7164a192f0e847efe20bdfd303e15f8b9b56ca"}],"searchlight/tests/unit/v1/test_search.py":[{"author":{"_account_id":10063,"name":"Steve McLellan","email":"steven.j.mclellan@gmail.com","username":"sjmc7"},"change_message_id":"5e927987f48418519200638b5163e46608b7184f","unresolved":false,"context_lines":[{"line_number":198,"context_line":"           and mock mutliple levels of Servers/Requests/Catalogs/etc we will"},{"line_number":199,"context_line":"           go directly to the IndexBase call."},{"line_number":200,"context_line":"        \"\"\""},{"line_number":201,"context_line":"        class FakeRequest(object):"},{"line_number":202,"context_line":"            def __init__(self):"},{"line_number":203,"context_line":"                # Fields used by IndexBase._get_facet_terms()"},{"line_number":204,"context_line":"                self.user_role_filter \u003d \u0027admin\u0027"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a89bdaa_e0f825c7","line":201,"range":{"start_line":201,"start_character":14,"end_line":201,"end_character":25},"updated":"2016-09-09 19:05:54.000000000","message":"Not sure what the benefit of this is over using get_fake_request","commit_id":"c016baab20fe4828881b4041a97c7dd86d4bf091"},{"author":{"_account_id":14680,"name":"Rick Aulino","email":"rick.aulino@hpe.com","username":"ricka"},"change_message_id":"29954ca5f63fd06f8104e517e7a8fe8e26ae2d12","unresolved":false,"context_lines":[{"line_number":198,"context_line":"           and mock mutliple levels of Servers/Requests/Catalogs/etc we will"},{"line_number":199,"context_line":"           go directly to the IndexBase call."},{"line_number":200,"context_line":"        \"\"\""},{"line_number":201,"context_line":"        class FakeRequest(object):"},{"line_number":202,"context_line":"            def __init__(self):"},{"line_number":203,"context_line":"                # Fields used by IndexBase._get_facet_terms()"},{"line_number":204,"context_line":"                self.user_role_filter \u003d \u0027admin\u0027"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a89bdaa_be797e84","line":201,"range":{"start_line":201,"start_character":14,"end_line":201,"end_character":25},"in_reply_to":"9a89bdaa_e0f825c7","updated":"2016-09-13 01:01:29.000000000","message":"Because when I was first using get_fake_request() it was failing. Relooking at it based on this comment, it turns out I was using the returned request, not the returned request.context. Fixed!","commit_id":"c016baab20fe4828881b4041a97c7dd86d4bf091"},{"author":{"_account_id":10063,"name":"Steve McLellan","email":"steven.j.mclellan@gmail.com","username":"sjmc7"},"change_message_id":"5e927987f48418519200638b5163e46608b7184f","unresolved":false,"context_lines":[{"line_number":208,"context_line":"        mock_engine \u003d mock.Mock()"},{"line_number":209,"context_line":"        simple_plugin \u003d fake_plugins.FakeSimplePlugin(es_engine\u003dmock_engine)"},{"line_number":210,"context_line":"        mock_engine.search.return_value \u003d {\"hits\": {\"total\": 0}}"},{"line_number":211,"context_line":"        simple_plugin._get_facet_terms(fields\u003d{}, request_context\u003drequest,"},{"line_number":212,"context_line":"                                       all_projects\u003dFalse, limit_terms\u003dFalse,"},{"line_number":213,"context_line":"                                       exclude_options\u003dTrue)"},{"line_number":214,"context_line":"        # Verify there is no aggregation when searching Elasticsearch."}],"source_content_type":"text/x-python","patch_set":3,"id":"9a89bdaa_803039a0","line":211,"range":{"start_line":211,"start_character":21,"end_line":211,"end_character":22},"updated":"2016-09-09 19:05:54.000000000","message":"This probably belongs in test_plugin since it\u0027s got nothing to do with the searchcontroller","commit_id":"c016baab20fe4828881b4041a97c7dd86d4bf091"},{"author":{"_account_id":14680,"name":"Rick Aulino","email":"rick.aulino@hpe.com","username":"ricka"},"change_message_id":"29954ca5f63fd06f8104e517e7a8fe8e26ae2d12","unresolved":false,"context_lines":[{"line_number":208,"context_line":"        mock_engine \u003d mock.Mock()"},{"line_number":209,"context_line":"        simple_plugin \u003d fake_plugins.FakeSimplePlugin(es_engine\u003dmock_engine)"},{"line_number":210,"context_line":"        mock_engine.search.return_value \u003d {\"hits\": {\"total\": 0}}"},{"line_number":211,"context_line":"        simple_plugin._get_facet_terms(fields\u003d{}, request_context\u003drequest,"},{"line_number":212,"context_line":"                                       all_projects\u003dFalse, limit_terms\u003dFalse,"},{"line_number":213,"context_line":"                                       exclude_options\u003dTrue)"},{"line_number":214,"context_line":"        # Verify there is no aggregation when searching Elasticsearch."}],"source_content_type":"text/x-python","patch_set":3,"id":"9a89bdaa_de7e4269","line":211,"range":{"start_line":211,"start_character":21,"end_line":211,"end_character":22},"in_reply_to":"9a89bdaa_803039a0","updated":"2016-09-13 01:01:29.000000000","message":"Moved.","commit_id":"c016baab20fe4828881b4041a97c7dd86d4bf091"}]}
