We are using Elastic Search 2.4. we use the java client to invoke scan and scroll api to scan through large num of docs..However, i dont see a performance boost as much as it is expected of scan and scroll api...I just wanted to check if my configurations require any more optimizations.
This is how i am doing scan
client().prepareSearch(content.getIndexName())
.setQuery("match_all_query")).setSearchType(SearchType.QUERY_AND_FETCH)
.setScroll(new TimeValue(15000)).setSize(size);
and this is how i am using scroll
client().prepareSearchScroll(scrollID).setScroll(new TimeValue(15000)).execute().actionGet();
I see that in ES 2.4, Using Searchtype.SCAN is deprecated. And i am also aware that scan api doesnt perform any sorting by default....
-
Is it the same case with QUERY_AND_FETCH or do we have to explicitly specify the sort order to not sort the results
-
also, do we have a limit on the number of results returned by SCAN/QUERY_AND_FETCH
-
Do we have any standard optimal configuration which ElasticSearch recommends, given that my usecase is just to scan through all the docs stored in index and delete them conditionally