Commit graph

656 commits

Author SHA1 Message Date
Christoph Büscher
c327794ae8
Fix range query on date fields for number inputs (#63692)
Currently, if you write a date range query with numeric 'to' or 'from' bounds,
they can be interpreted as years if no format is provided. We use
"strict_date_optional_time||epoch_millis" in this case that can interpret inputs
like 1000 as the year 1000 for example. 
This PR change this to always interpret and parse numbers with the "epoch_millis"
parser if no other formatter was provided.

Closes #63680
2020-12-01 18:49:50 +01:00
James Rodewig
1ea83359bb
[DOCS] Fix case for 'Boolean' (#64299) 2020-10-29 09:04:43 -04:00
Ignacio Vera
b72be253a9
Enable geo_distance and geo_bounding_box queries on geo_shape field type (#64224) 2020-10-29 07:30:53 +01:00
markharwood
81b334913a
Search - make term/prefix/wildcard/regex query parsing more lenient (#63926)
* Remove errors when case_insensitive flag set to false

Closes #63893
2020-10-21 10:51:22 +01:00
Josh Devins
9b8b20a32b
[DOCS] Clarifies the effect of per-field boosting (#63733)
The original description of per-field boosting is incorrect. Boosting a
field does not imply that it is more important relative to other fields.
It simply means that the score is multiplied by the supplied boost
value. Due to the differences in each field's term and document
statistics, it's not possible to imply relative importance of fields
based on the per-field boost value alone.
2020-10-15 09:24:32 -04:00
Przemyslaw Gomulka
b38eaae47f
[doc] Rounding range query rules (#63109)
a documentation explaining defaulting of missing fields when using date math parser.
relates #62268
2020-10-02 08:59:27 +02:00
markharwood
fe9145fa5e
Search - add case insensitive flag for "term" family of queries (#61596)
Adds  case insensitive flag for term, prefix, and wildcard queries

Closes #61546
2020-09-18 17:17:08 +01:00
James Rodewig
224ff408de
[DOCS] Fix range query admon for clarity (#62163) 2020-09-09 10:17:58 -04:00
James Rodewig
ea80a542a7
[DOCS] Fix typo in range query docs (#61722) 2020-08-31 10:46:06 -04:00
markharwood
7adf766fc4
Search - add case insensitive support for regex queries. (#59441)
Added case insensitive support for regex queries.
Forks a copy of Lucene’s RegexpQuery and RegExp from Lucene master.
This can be removed when 8.7 Lucene is released.

Closes #59235
2020-08-25 15:27:49 +01:00
James Rodewig
c688cb6bfd
[DOCS] Fix hyphenation for "time series" (#61472) 2020-08-24 10:34:41 -04:00
Dan Hermann
9397510778
[DOCS] Update tie_breaker defaults for bool_prefix and most_fields query types (#61112) 2020-08-19 07:55:54 -05:00
James Rodewig
a94e5cb7c4
[DOCS] Replace Wikipedia links with attribute (#61171) 2020-08-17 09:44:24 -04:00
James Rodewig
a0f4edff66
[DOCS] Fix chunking in query docs (#61053)
Changes:
* Moves "Notes" sections for the joining queries and percolate query
  pages to the parent page
* Adds related redirects for the moved "Notes" pages
* Assigns explicit anchor IDs to other "Notes" headings. This was required for
  the redirects to work.
2020-08-12 13:45:49 -04:00
James Rodewig
929033f9dd
[DOCS] Move named query content to bool query (#60748) 2020-08-05 13:27:10 -04:00
James Rodewig
56c778235c
[DOCS] Fix metadata field refs (#60764) 2020-08-05 13:21:00 -04:00
James Rodewig
78b1cc426c
[DOCS] Fix query docs formatting (#60752) 2020-08-05 12:28:09 -04:00
James Rodewig
a4dc336c16
[DOCS] Replace twitter dataset in search/agg docs (#60667) 2020-08-04 13:31:52 -04:00
James Rodewig
ae01606785
[DOCS] Replace twitter dataset in docs (#60604) 2020-08-03 12:49:56 -04:00
Alexander Reelsen
c7ac9e7073
[DOCS] http -> https, remove outdated plugin docs (#60380)
Plugin discovery documentation contained information about installing
Elasticsearch 2.0 and installing an oracle JDK, both of which is no
longer valid.

While noticing that the instructions used cleartext HTTP to install
packages, this commit replaces HTTPs links instead of HTTP where possible.

In addition a few community links have been removed, as they do not seem
to exist anymore.
2020-07-31 15:58:38 -04:00
James Rodewig
700c04d629
[DOCS] Fix fuzzy_rewrite ref in match query docs (#60237) 2020-07-27 15:17:17 -04:00
James Rodewig
441c3a21b1
[DOCS] Update my-index examples (#60132)
Changes the following example index names to `my-index-000001` for consistency:

* `my-index`
* `my_index`
* `myindex`
2020-07-27 14:46:39 -04:00
homersimpsons
b0cc62f69e
[DOCS] Fix rewrite => fuzzy_rewrite in multi match query docs (#60175) 2020-07-27 12:13:33 -04:00
Ulas Keles
a20fd49533
[DOCS] Fix formatting in simple query string query docs 2020-07-27 11:54:19 -04:00
James Rodewig
d5b03f668b
[DOCS] Move search sort docs to separate page (#60123)
Moves the search sort docs from the deprecated 'Request Body Search'
page to a new subpage of 'Run a search'.

No substantive changes were made to the content.
2020-07-23 12:58:57 -04:00
James Rodewig
2774cd6938
[DOCS] Swap [float] for [discrete] (#60124)
Changes instances of `[float]` in our docs for `[discrete]`.

Asciidoctor prefers the `[discrete]` tag for floating headings:
https://asciidoctor.org/docs/asciidoc-asciidoctor-diffs/#blocks
2020-07-23 11:48:22 -04:00
James Rodewig
80b674fb25
[DOCS] Reformat snippets to use two-space indents (#59973) 2020-07-21 12:24:26 -04:00
James Rodewig
8a57800f1b
[DOCS] Add performance warning for scripts (#59890) 2020-07-20 14:04:35 -04:00
James Rodewig
aa3ddfeefb
[DOCS] Move highlighting docs to separate page (#59768)
Moves the highlighting docs from the deprecated 'Request Body Search'
chapter to the new subpage of the 'Run a search chapter' section.

No substantive changes were made to the content.
2020-07-17 10:15:20 -04:00
homersimpsons
38aa0c18cd
[DOCS] MatchQuery: transpositions to fuzzy_transpositions (#59371) 2020-07-13 09:39:30 -04:00
James Rodewig
2be9db01c8
[DOCS] Replace datatype with data type (#58972) 2020-07-07 13:52:10 -04:00
István Zoltán Szabó
d1e480e5bd
[DOCS] Extends geo_shape query docs to explain behavior when data is indexed as array of shapes (#57806)
Co-authored-by: James Rodewig <james.rodewig@elastic.co>
2020-06-08 15:03:59 +02:00
Tal Levy
cfb36c3fcc
Update geo_point docs for geo_shape queries (#57487)
This commit highlights the ability for geo_point fields to be
used in geo_shape queries. It also adds an explicit geo_point
example in the geo_shape query documentation

Closes #56927.
2020-06-02 12:56:13 -07:00
Florian Kelbert
911c13bcf1
[DOCS] Fix typo in rank feature query docs (#57401) 2020-06-01 08:42:09 -04:00
Christoph Büscher
4e8134cfaf
Remove deprecated SimpleQueryStringBuilder parameters (#57200)
The `lowercase_expand_terms`, `locale` and `all_fields` parameters for
`simple_query_string` have been deprecated and a no-op for at least until 6.0
so we can remove them in 8.0
2020-05-28 16:36:32 +02:00
bellengao
e0191438ed
[Docs] Fix typo in match-bool-prefix-query doc (#56077) 2020-05-04 14:17:00 +02:00
James Rodewig
3791a92603
[DOCS] Warn about searching across all fields wt. query_string (#55853)
Warn about potential performance impact when a large number of fields
is used with query string query and no default field.

Re-adds content from #35570.
That content was erroneously removed in #45296.

Co-authored-by: Peter Dyson <peter.dyson@geekpete.com>
2020-04-28 09:19:24 -04:00
James Rodewig
4ec2424442
[DOCS] Add query reference docs template (#52292) 2020-04-10 08:46:47 -04:00
Ignacio Vera
6182db5b77
Add new point field. (#53804)
This commit adds a new point field that is able to index arbitrary pair of values (x/y)
 in the cartesian space. It only supports filtering using shape queries at the moment.
2020-04-07 13:08:02 +02:00
Christoph Büscher
440fb48869
[Docs] Correct date rounding example for range query (#51524)
Looking into #50237 I realized that two of the examples given in the
documentation around date math rounding for range queries on date fields using
`gt` and `lt` is slightly off by a nanosecond. This PR changes this to the
bounds that are currently parsed using these parameters.
2020-04-06 17:02:38 +02:00
Alan Woodward
0f7cf7b720
TermsLookup fields should be marked as Required in docs (#53784)
The terms-lookup section of our terms query docs currently state that the
index, id and path fields are optional. They should be marked instead
as required.
2020-03-20 15:38:43 +00:00
Dominic Page
d1cbdfb753
Geo shape query vs geo point (#52382)
Enable geo_shape query to work on geo_point fields for shapes: circle, polygon, multipolygon, rectangle

see: #48928

Co-Authored-By:  @iverase
2020-03-18 17:03:52 +01:00
Ralph Ursprung
2a44c29222
[Docs] Fix highlighting in match-query example (#52426) 2020-03-18 11:52:50 +01:00
Yash Joshi
f9cbc76908 [Docs] Fix typo in range query (#53656) 2020-03-18 10:18:37 +01:00
Adam Canady
83baca1bbc [Docs] Correct examples for * and + in regexp-syntax.asciidoc (#53210) 2020-03-06 17:19:37 +01:00
Mayya Sharipova
556ee9a719
Correct boost calculation in script_score query (#52478)
Before boost in script_score query was wrongly applied only to the subquery.
This commit makes sure that the boost is applied to the whole score
that comes out of script.

Closes #48465
2020-02-24 10:46:33 -05:00
Marios Trivyzas
a8b39ed842
Add a cluster setting to disallow expensive queries (#51385)
Add a new cluster setting `search.allow_expensive_queries` which by
default is `true`. If set to `false`, certain queries that have 
usually slow performance cannot be executed and an error message
is returned.

- Queries that need to do linear scans to identify matches:
  - Script queries
- Queries that have a high up-front cost:
  - Fuzzy queries
  - Regexp queries
  - Prefix queries (without index_prefixes enabled
  - Wildcard queries
  - Range queries on text and keyword fields
- Joining queries
  - HasParent queries
  - HasChild queries
  - ParentId queries
  - Nested queries
- Queries on deprecated 6.x geo shapes (using PrefixTree implementation)
- Queries that may have a high per-document cost:
  - Script score queries
  - Percolate queries

Closes: #29050
2020-02-12 18:06:04 +01:00
Mayya Sharipova
620996287a
Remove docs related to index time boosting (#51704)
As there is no really index time boosting,
as boost is only applied during query time,
this removes mentions of index time boosting.
2020-01-31 09:01:52 -05:00
Russ Cam
ff22445364 [Docs] Including leading slash in range query doc example URLs (#51277) 2020-01-22 09:38:52 +01:00
Tal Levy
6c86606d2a
Adds support for geo-bounds filtering in geogrid aggregations (#50002)
It is fairly common to filter the geo point candidates in
geohash_grid and geotile_grid aggregations according to some
viewable bounding box. This change introduces the option of
specifying this filter directly in the tiling aggregation.

This is even more relevant to `geo_shape` where the bounds will restrict
the shape to be within the bounds

this optional `bounds` parameter is parsed in an equivalent fashion to 
the bounds specified in the geo_bounding_box query.
2020-01-14 08:29:10 -08:00