Skip to content

[feature request]copy_index api(reindex with file copy not doc insert) #44128

@riverbuilding

Description

@riverbuilding

use case: copy old index as a backup to support rollback and then update the original index to move forward in the same cluster.

ES provide re-index API which can be used to copy index with many flexibility like schema change, doc filter etc.
although with many limitations, from performance side, the file copy method is much fast than reindex, especially when index size is big.

API:

POST _copyindex
{
"source": {
"index": "twitter"

},
"dest": {
"index": "new_twitter"
"replica": Number//must eq or less than orginal index replica, otherwise, fail request
}
}

it's really like snapshot-restore process only repository is ES itself

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions