Elasticsearch 2.1: Result window is too large (index.max_result_window)

后端 未结 7 1959
余生分开走
余生分开走 2020-11-28 05:18

We retrieve information from Elasticsearch 2.1 and allow the user to page thru the results. When the user requests a high page number we get the following error message:

7条回答
  •  野趣味
    野趣味 (楼主)
    2020-11-28 05:28

    2) It does not seem that the scrolling API is an option for me but that I have to increase "index.max_result_window". Does anyone have any experience with this?

    --> You can define this value in index templates , es template will be applicable for new indexes only ,so you either have to delete old indexes after creating template or wait for new data to be ingested in elasticsearch .

    { "order": 1, "template": "index_template*", "settings": { "index.number_of_replicas": "0", "index.number_of_shards": "1", "index.max_result_window": 2147483647 },

提交回复
热议问题