Skip to content

Commit f0addee

Browse files
authored
[DOCS] Clarifies destination index mappings for Transforms. (#63794) (#63803)
1 parent b3f76c0 commit f0addee

File tree

2 files changed

+17
-6
lines changed

2 files changed

+17
-6
lines changed

docs/reference/rest-api/common-parms.asciidoc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,11 @@ The destination for the {transform}.
155155
end::dest[]
156156

157157
tag::dest-index[]
158-
The _destination index_ for the {transform}.
158+
The _destination index_ for the {transform}. The mappings of the destination
159+
index are deduced based on the source fields when possible. If alternate
160+
mappings are required, use the
161+
https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-create-index.html[Create index API]
162+
prior to starting the {transform}.
159163
end::dest-index[]
160164

161165
tag::dest-pipeline[]

docs/reference/transform/limitations.asciidoc

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,11 +56,18 @@ or <<search-aggregations-pipeline-bucket-script-aggregation,`bucket_scripts`>>,
5656
<<dynamic-mapping,dynamic mappings>> will be used. In some instances the
5757
deduced mappings may be incompatible with the actual data. For example, numeric
5858
overflows might occur or dynamically mapped fields might contain both numbers
59-
and strings. Please check {es} logs if you think this may have occurred. As a
60-
workaround, you may define custom mappings prior to starting the
61-
{transform}. For example,
62-
<<indices-create-index,create a custom destination index>> or
63-
<<indices-templates,define an index template>>.
59+
and strings. Please check {es} logs if you think this may have occurred.
60+
61+
You can view the deduced mappings by using the
62+
https://www.elastic.co/guide/en/elasticsearch/reference/current/preview-transform.html[Preview transform API].
63+
See the `generated_dest_index` object in the API response.
64+
65+
If it's required, you may define custom mappings prior to starting the
66+
{transform} by creating a custom destination index using the
67+
https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-create-index.html[Create index API].
68+
As deduced mappings cannot be overwritten by an index template, use the Create
69+
index API to define custom mappings. The index templates only apply to fields
70+
derived from scripts that use dynamic mappings.
6471

6572
[discrete]
6673
[[transform-batch-limitations]]

0 commit comments

Comments
 (0)