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 source api block set to reindex data stream index action params #119991

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

parkertimmins
Copy link
Contributor

Add a parameter to the reindex-datastream-index action containing the set of api blocks set on the source index before the reindex operation is called. This set will be stored in the task state for the reindex-datastream task and passed into each per-index action call.

Because the task may need to retry the per-index action for a given index, and the per-index action call could modify the api blocks on the source index, the api block set before the the first call is stored in the task state. This allows the correct original api blocks from the source index to be copied to the destination index after reindexing completes.

@elasticsearchmachine elasticsearchmachine added v9.0.0 needs:triage Requires assignment of a team area label labels Jan 10, 2025
@parkertimmins parkertimmins added :Data Management/Data streams Data streams and their lifecycles auto-backport Automatically create backport pull requests when merged v8.18.0 and removed needs:triage Requires assignment of a team area label labels Jan 10, 2025
@elasticsearchmachine elasticsearchmachine added the Team:Data Management Meta label for data/management team label Jan 10, 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.

}

@Override
protected Request mutateInstance(Request instance) {
return new ReindexDataStreamIndexAction.Request(randomValueOtherThan(instance.getSourceIndex(), () -> randomAlphaOfLength(20)));
return new ReindexDataStreamIndexAction.Request(
Copy link
Member

Choose a reason for hiding this comment

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

I think you just want to change one thing at a time here, so that we know that any single change causes the objects to not be equal.

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 with the exception of the comment I put on mutateInstance in the test.

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.

3 participants