Skip to content

Commit

Permalink
Docfix: the default mode is the dynamic mode. (#4684)
Browse files Browse the repository at this point in the history
* Docfix: the default mode is the dynamic mode.

Closes #4679
  • Loading branch information
fulmicoton authored Mar 6, 2024
1 parent 6cd6379 commit 55b10d2
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions docs/guides/schemaless.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,15 +57,20 @@ indexing_settings:
```
The `mode` attribute controls what should be done if an ingested document
contains a field that is not defined in the document mapping. By default, it takes the `lenient` value. In `lenient` mode, the fields that do not appear in the document mapping will simply be ignored.
contains a field that is not defined in the document mapping. By default, your index is in the `dynamic` mode. In `dynamic` mode, the fields that do not appear in the document mapping will be indexed in a schemaless fashion.
See details in the [dynamic mode section](#dynamic-mode).


If `mode` is set to `strict` on the other hand, documents containing fields
that are not defined in the mapping will be entirely discarded.

## Schemaless with a partial schema
Finally the last possible value for `mode` is `lenient`. In lenient mode, fields that are not present in the field mapping will simply be ignored.

## The dynamic mode: schemaless with a partial schema {#dynamic-mode}

`mode` can take another value: `dynamic`.
`mode` can take the value: `dynamic`.
When set to dynamic, all extra fields will actually be mapped using a catch-all configuration.

By default, this catch-all configuration indexes and stores all of these fields, but this can be configured by setting the [`dynamic_mapping` attribute](../configuration/index-config#mode).
A minimalist, yet perfectly valid and useful index configuration is then:

Expand Down

0 comments on commit 55b10d2

Please sign in to comment.