Skip to content
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

Add rest endpoint for create_from_source_index #119250

Merged

Conversation

parkertimmins
Copy link
Contributor

@parkertimmins parkertimmins commented Dec 23, 2024

Add rest endpoint for create-index-from-source action. This endpoint will create a new index using the settings and mappings from an existing source index. Setting and mapping overrides can be added to the request which will override settings and mappings from the source index.

Request
Method: POST or PUT
Path: _create_from/{source}/{dest} where source is an existing source index and dest is the name of the index to create.
Body can contain settings_override and mappings_override which are standard setting and mapping objects which will be merged with values from source index.

@parkertimmins parkertimmins added auto-backport Automatically create backport pull requests when merged v8.18.0 labels Dec 23, 2024
@parkertimmins parkertimmins marked this pull request as ready for review January 7, 2025 21:07
@elasticsearchmachine elasticsearchmachine added the needs:triage Requires assignment of a team area label label Jan 7, 2025
@parkertimmins parkertimmins added :Data Management/Data streams Data streams and their lifecycles and removed needs:triage Requires assignment of a team area label labels Jan 7, 2025
@elasticsearchmachine elasticsearchmachine added the Team:Data Management Meta label for data/management team label Jan 7, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-data-management (Team:Data Management)

@elasticsearchmachine
Copy link
Collaborator

Hi @parkertimmins, I've created a changelog YAML for you.

Copy link
Contributor

@lukewhiting lukewhiting left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good so far :-)

@parkertimmins parkertimmins requested a review from masseyke January 8, 2025 14:53
Copy link
Member

@masseyke masseyke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@parkertimmins parkertimmins merged commit b34e278 into elastic:main Jan 8, 2025
16 checks passed
@parkertimmins parkertimmins deleted the create-index-from-source-rest-api branch January 8, 2025 16:57
@elasticsearchmachine
Copy link
Collaborator

💚 Backport successful

Status Branch Result
8.x

parkertimmins added a commit to parkertimmins/elasticsearch that referenced this pull request Jan 8, 2025
Add rest endpoint which creates a new index using the settings and mappings from an existing source index. Setting and mapping overrides can be added to the request which will override settings and mappings from the source index.

Example: `PUT /_create_from/{source}/{dest}`
Content is optional but can include a `settings_override` and `mappings_override` which will be combined with the settings and mappings from the source index to create the destination index.
elasticsearchmachine pushed a commit that referenced this pull request Jan 8, 2025
Add rest endpoint which creates a new index using the settings and mappings from an existing source index. Setting and mapping overrides can be added to the request which will override settings and mappings from the source index.

Example: `PUT /_create_from/{source}/{dest}`
Content is optional but can include a `settings_override` and `mappings_override` which will be combined with the settings and mappings from the source index to create the destination index.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Automatically create backport pull requests when merged :Data Management/Data streams Data streams and their lifecycles >enhancement Team:Data Management Meta label for data/management team v8.18.0 v9.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants