Skip to content

Use latch to speedup multi feature migration test (#84007)#84069

Merged
elasticsearchmachine merged 1 commit intoelastic:8.1from
rjernst:feature_migration_it_8.1
Feb 17, 2022
Merged

Use latch to speedup multi feature migration test (#84007)#84069
elasticsearchmachine merged 1 commit intoelastic:8.1from
rjernst:feature_migration_it_8.1

Conversation

@rjernst
Copy link
Copy Markdown
Member

@rjernst rjernst commented Feb 16, 2022

The multi feature migration test works by having two system index
features that are to be upgraded. The reindexing of the system indices
of those features is done in sequence by the system index migrator, and
the test has an assertBusy that waits for all the migrations to
complete. Unfortunately assertBusy backs off exponentially, so it isn't
great for quickly resuming the test once the underlying assertion
becomes true, since the condition might change shortly after an
iteration, and then have to wait for a long backoff.

This commit adds a latch which will count down all the executions of the
test plugins, so that the assert busy will not be run until after all
the indexes have migrated.

closes #83953

The multi feature migration test works by having two system index
features that are to be upgraded. The reindexing of the system indices
of those features is done in sequence by the system index migrator, and
the test has an assertBusy that waits for all the migrations to
complete. Unfortunately assertBusy backs off exponentially, so it isn't
great for quickly resuming the test once the underlying assertion
becomes true, since the condition might change shortly after an
iteration, and then have to wait for a long backoff.

This commit adds a latch which will count down all the executions of the
test plugins, so that the assert busy will not be run until after all
the indexes have migrated.

closes elastic#83953
@rjernst rjernst added backport auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) labels Feb 16, 2022
@elasticsearchmachine elasticsearchmachine merged commit ba853a4 into elastic:8.1 Feb 17, 2022
@rjernst rjernst deleted the feature_migration_it_8.1 branch February 17, 2022 00:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) backport v8.1.1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants