which is the fastest possible filter I could use to exclude documents from a search, provided that I have control of what fields those documents have?
in an ecommerce search engine, we used to not to index products that were "out of stock". however, if for some reason the ecommerce owner wants to show the "out of stock" products, she has to reindex them again. following a tip from Igor Motov in another thread, I'm considering adding some "out_of_stock" field to every item, let them all be indexed, and use a filtered alias. since I have control on the field I'm using for filtering, I figured I could use the one that allows me "the fastest filter under the sun". I've assumed that would be the "missing field" filter, with "existence:True". i.e. only the documents that don't have the "out_of_stock" field pass the filter (I don't mind the field's value) Am I right? is this the fastest/more performant filter I can use? -- You received this message because you are subscribed to the Google Groups "elasticsearch" group. To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/ffae84ea-957c-4ecf-b5f1-9a1456437860%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.