Skip to content

Add sanity check to ReindexDatastreamIndexAction #120231

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

Merged

Conversation

parkertimmins
Copy link
Contributor

As a final sanity check after reindexing, check that the number of docs in the source index equals the number of docs in the dest index. Only run this if assertions are enabled since it requires a refresh and two search actions.

@parkertimmins parkertimmins added >enhancement :Data Management/Data streams Data streams and their lifecycles auto-backport Automatically create backport pull requests when merged v9.0.0 v8.18.0 labels Jan 15, 2025
@elasticsearchmachine
Copy link
Collaborator

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

@parkertimmins parkertimmins marked this pull request as ready for review January 15, 2025 21:00
@elasticsearchmachine elasticsearchmachine added the Team:Data Management Meta label for data/management team label Jan 15, 2025
@elasticsearchmachine
Copy link
Collaborator

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

@parkertimmins parkertimmins merged commit 5f9fefc into elastic:main Jan 16, 2025
16 checks passed
@elasticsearchmachine
Copy link
Collaborator

💚 Backport successful

Status Branch Result
8.x

parkertimmins added a commit to parkertimmins/elasticsearch that referenced this pull request Jan 16, 2025
Add an assert that checks that source and destination index have the same doc count. This requires a refresh of the dest index and a search request against both the source and dest index, so will only be run if asserts are enabled.
elasticsearchmachine pushed a commit that referenced this pull request Jan 16, 2025
…0295)

* Add sanity check to ReindexDatastreamIndexAction (#120231)

Add an assert that checks that source and destination index have the same doc count. This requires a refresh of the dest index and a search request against both the source and dest index, so will only be run if asserts are enabled.

* Compilation error due to lucene totalHits change
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