Splits an existing index into a new index with more primary shards Added in 6.1.0
Path parameters
-
Name of the source index to split.
-
Name of the target index to create.
Query parameters
-
master_timeout string
Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error.
-
timeout string
Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error.
-
wait_for_active_shards number | string
The number of shard copies that must be active before proceeding with the operation. Set to
all
or any positive integer up to the total number of shards in the index (number_of_replicas+1
).
PUT /{index}/_split/{target}
curl \
-X PUT http://api.example.com/{index}/_split/{target} \
-H "Content-Type: application/json" \
-d '{"aliases":{"additionalProperty1":{"filter":{},"index_routing":"string","is_hidden":true,"is_write_index":true,"routing":"string","search_routing":"string"},"additionalProperty2":{"filter":{},"index_routing":"string","is_hidden":true,"is_write_index":true,"routing":"string","search_routing":"string"}},"settings":{"additionalProperty1":{},"additionalProperty2":{}}}'
Request examples
{
"aliases": {
"additionalProperty1": {
"filter": {},
"index_routing": "string",
"is_hidden": true,
"is_write_index": true,
"routing": "string",
"search_routing": "string"
},
"additionalProperty2": {
"filter": {},
"index_routing": "string",
"is_hidden": true,
"is_write_index": true,
"routing": "string",
"search_routing": "string"
}
},
"settings": {
"additionalProperty1": {},
"additionalProperty2": {}
}
}
Response examples (200)
{
"acknowledged": true,
"shards_acknowledged": true,
"index": "string"
}