Skip to content

Adding the merge_type param to the ingest simulate API #5140

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Aug 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 30 additions & 1 deletion output/schema/schema.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions output/typescript/types.ts

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions specification/_json_spec/simulate.ingest.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@
"pipeline": {
"type": "string",
"description": "The pipeline id to preprocess incoming documents with if no pipeline is given for a particular document"
},
"merge_type": {
"type": "string",
"description": "The method to be used when merging mapping_additions existing mappings"
}
},
"body": {
Expand Down
12 changes: 12 additions & 0 deletions specification/simulate/ingest/SimulateIngestRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,13 @@ export interface Request extends RequestBase {
* This value can be used to override the default pipeline of the index.
*/
pipeline?: PipelineName
/**
* The method to be used when merging mapping_additions existing mappings. Mappings can be merged in the way mapping changes are merged into an existing index, or in
* the way mapping changes are merged into existing templates. Some changes are allowed to templates that are not allowed to indices. For example,
* a field cannot be changed to an incompatible type in an index, but can in a template.
* @server_default index
*/
merge_type?: MergeType
}
body: {
/**
Expand All @@ -98,3 +105,8 @@ export interface Request extends RequestBase {
pipeline_substitutions?: Dictionary<string, Pipeline>
}
}

enum MergeType {
index,
template
}