From 7d59f495295e7701f7fd11e557d3f6f7c00103d3 Mon Sep 17 00:00:00 2001 From: James Rodewig <40268737+jrodewig@users.noreply.github.com> Date: Wed, 17 Mar 2021 17:35:13 -0400 Subject: [PATCH] [DOCS] Document `index.query.default_field` index setting (#69922) (#70529) --- docs/reference/index-modules.asciidoc | 21 +++++++++++++++++---- docs/reference/query-dsl/mlt-query.asciidoc | 5 ++++- 2 files changed, 21 insertions(+), 5 deletions(-) diff --git a/docs/reference/index-modules.asciidoc b/docs/reference/index-modules.asciidoc index e1b8e28ead6f5..af682ec2e6f2f 100644 --- a/docs/reference/index-modules.asciidoc +++ b/docs/reference/index-modules.asciidoc @@ -2,9 +2,6 @@ [[index-modules]] = Index modules -[partintro] --- - Index Modules are modules created per index and control all aspects related to an index. @@ -249,6 +246,23 @@ specific index module: The maximum length of regex that can be used in Regexp Query. Defaults to `1000`. + +`index.query.default_field`:: ++ +-- +(string or array of strings) +Wildcard (`*`) patterns matching one or more fields. The following query types +search these matching fields by default: + +* <> +* <> +* <> +* <> + +Defaults to `*`, which matches all fields eligible for +<>, excluding metadata fields. +-- + `index.routing.allocation.enable`:: Controls shard allocation for this index. It can be set to: @@ -340,7 +354,6 @@ Other index settings are available in index modules: <>:: Specify the lifecycle policy and rollover alias for an index. --- include::index-modules/analysis.asciidoc[] diff --git a/docs/reference/query-dsl/mlt-query.asciidoc b/docs/reference/query-dsl/mlt-query.asciidoc index 2cd940493d88b..8550a34efaa4d 100644 --- a/docs/reference/query-dsl/mlt-query.asciidoc +++ b/docs/reference/query-dsl/mlt-query.asciidoc @@ -175,7 +175,10 @@ for documents `like: "Apple"`, but `unlike: "cake crumble tree"`. The syntax is the same as `like`. `fields`:: -A list of fields to fetch and analyze the text from. +A list of fields to fetch and analyze the text from. Defaults to the +`index.query.default_field` index setting, which has a default value of `*`. The +`*` value matches all fields eligible for <>, excluding metadata fields. [discrete] [[mlt-query-term-selection]]