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 an integration test for several Kibana instances performing migration in parallel #97975

Closed
mshustov opened this issue Apr 22, 2021 · 4 comments
Labels
project:ResilientSavedObjectMigrations Reduce Kibana upgrade failures by making saved object migrations more resilient Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc triage_needed

Comments

@mshustov
Copy link
Contributor

Migrations v2 have been designed to support resilient migrations in the event of several Kibana instances running migrations in parallel. Considering that it's one of the main features of the new algorithm, it must be covered by an integration test. Right now, the only way to test it is to use a script created by @Bamieh #84141 (comment).
It cannot be used for automated testing on CI.

It would be great if an automated test covers the case when different Kibana instances have different sets of enabled plugins to prove this edge case doesn't break migrations.

@mshustov mshustov added Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc project:ResilientSavedObjectMigrations Reduce Kibana upgrade failures by making saved object migrations more resilient labels Apr 22, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-core (Team:Core)

@joshdover
Copy link
Contributor

Meeting notes:

@afharo
Copy link
Member

afharo commented May 4, 2021

Likely a pretty good amount of effort to implement this

Should we consider this a Meta issue and break it down into smaller pieces?

@joshdover
Copy link
Contributor

  • Scope:
    • Add a test to try to catch race conditions between multiple nodes
    • Add a test to start nodes with different plugins enabled
    • Add a test to start two ES nodes in the same cluster, with a Kibana node configured to each one
    • Use the jest_integration suite to run multiple Roots against a single (real) ES cluster
    • Try to find a manual change to the migration algo that can be made to emulate a race condition to verify the test will catch race condition
    • Generate 1000-ish SOs and use a batchSize of 100 to emulate a slow enough migration process to try to create a race condition

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
project:ResilientSavedObjectMigrations Reduce Kibana upgrade failures by making saved object migrations more resilient Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc triage_needed
Projects
None yet
Development

No branches or pull requests

4 participants