mirror of https://github.com/pelias/api.git
Browse Source
It's possible for the `text` input to /v1/autocomplete to be of non-zero length after trimming whitespace and quotes, but still be insufficient to use for geocoding. One common case is that it contains only commas, slashes, or other delimiters. Our query logic currently does not handle this case, and will generate Elasticsearch queries that do not have a primary `must` clause and end up searching every document in the index. These queries are slow, take up cluster resources, and are not useful. By detecting unsubstantial inputs, we can prevent this.pull/1214/head
Julian Simioni
6 years ago
2 changed files with 41 additions and 0 deletions
Loading…
Reference in new issue