mirror of
https://github.com/elastic/elasticsearch.git
synced 2025-06-30 10:23:41 -04:00
* Adding new `require_alias` option to indexing requests (#58917) This commit adds the `require_alias` flag to requests that create new documents. This flag, when `true` prevents the request from automatically creating an index. Instead, the destination of the request MUST be an alias. When the flag is not set, or `false`, the behavior defaults to the `action.auto_create_index` settings. This is useful when an alias is required instead of a concrete index. closes https://github.com/elastic/elasticsearch/issues/55267
This commit is contained in:
parent
65f6fb8e94
commit
b7f30fc929
30 changed files with 447 additions and 36 deletions
|
@ -25,9 +25,9 @@ and <<update-delete-docs-in-a-backing-index>>.
|
|||
|
||||
`POST /<target>/_create/<_id>`
|
||||
|
||||
IMPORTANT: You cannot add new documents to a data stream using the
|
||||
`PUT /<target>/_doc/<_id>` request format. To specify a document ID, use the
|
||||
`PUT /<target>/_create/<_id>` format instead. See
|
||||
IMPORTANT: You cannot add new documents to a data stream using the
|
||||
`PUT /<target>/_doc/<_id>` request format. To specify a document ID, use the
|
||||
`PUT /<target>/_create/<_id>` format instead. See
|
||||
<<add-documents-to-a-data-stream>>.
|
||||
|
||||
[[docs-index-api-path-params]]
|
||||
|
@ -94,6 +94,8 @@ include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=version_type]
|
|||
|
||||
include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=wait_for_active_shards]
|
||||
|
||||
include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=require-alias]
|
||||
|
||||
[[docs-index-api-request-body]]
|
||||
==== {api-request-body-title}
|
||||
|
||||
|
|
|
@ -53,6 +53,8 @@ include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=if_primary_term]
|
|||
`lang`::
|
||||
(Optional, string) The script language. Default: `painless`.
|
||||
|
||||
include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=require-alias]
|
||||
|
||||
include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=refresh]
|
||||
|
||||
`retry_on_conflict`::
|
||||
|
|
|
@ -592,6 +592,12 @@ such as `1264`.
|
|||
A value of `-1` indicates {es} was unable to compute this number.
|
||||
end::memory[]
|
||||
|
||||
tag::require-alias[]
|
||||
`require_alias`::
|
||||
(Optional, boolean) When true, this requires the destination to be an alias.
|
||||
Defaults to false.
|
||||
end::require-alias[]
|
||||
|
||||
tag::node-filter[]
|
||||
`<node_filter>`::
|
||||
(Optional, string)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue