Add documentation about disabling _field_names. (#26813)

This field has significant index-time overhead.

Closes #26779
This commit is contained in:
Adrien Grand 2017-10-06 16:49:15 +02:00 committed by GitHub
parent 100e3c9a8a
commit 4e1ff8d086
2 changed files with 29 additions and 0 deletions

View File

@ -114,6 +114,13 @@ The default is `10%` which is often plenty: for example, if you give the JVM
10GB of memory, it will give 1GB to the index buffer, which is enough to host
two shards that are heavily indexing.
[float]
=== Disable `_field_names`
The <<mapping-field-names-field,`_field_names` field>> introduces some
index-time overhead, so you might want to disable it if you never need to
run `exists` queries.
[float]
=== Additional optimizations

View File

@ -35,3 +35,25 @@ GET my_index/_search
// CONSOLE
<1> Querying on the `_field_names` field (also see the <<query-dsl-exists-query,`exists`>> query)
==== Disabling `_field_names`
Because `_field_names` introduce some index-time overhead, you might want to
disable this field if you want to optimize for indexing speed and do not need
`exists` queries.
[source,js]
--------------------------------------------------
PUT tweets
{
"mappings": {
"tweet": {
"_field_names": {
"enabled": false
}
}
}
}
--------------------------------------------------
// CONSOLE