elastic / elasticsearch

Free and Open Source, Distributed, RESTful Search Engine
https://www.elastic.co/products/elasticsearch
Other
69.73k stars 24.68k forks source link

Avoid retrying bad search requests on replicas #72349

Open jtibshirani opened 3 years ago

jtibshirani commented 3 years ago

If a shard fails during a search phase, then we retry the shard request on its replicas. This makes sense for many types of errors, but for bad_request errors we know that the replicas will fail as well. Could we avoid retrying on replicas in this case? Some examples of bad request errors we see in search: invalid query syntax, too many docvalue_fields requested, attempting to run a query or agg on a field whose type isn't supported.

elasticmachine commented 3 years ago

Pinging @elastic/es-search (Team:Search)

dnhatn commented 3 years ago

+1

elasticsearchmachine commented 2 months ago

Pinging @elastic/es-search-foundations (Team:Search Foundations)