Skip to content

[7.16] Fix data stream alias validation. (#81040)#81136

Merged
elasticsearchmachine merged 3 commits intoelastic:7.16from
martijnvg:backport/7.16/pr-81040
Nov 30, 2021
Merged

[7.16] Fix data stream alias validation. (#81040)#81136
elasticsearchmachine merged 3 commits intoelastic:7.16from
martijnvg:backport/7.16/pr-81040

Conversation

@martijnvg
Copy link
Copy Markdown
Member

Backports the following commits to 7.16:

In case of restoring a snapshot, it is possible to overwrite an existing
data stream with a data stream alias from a snapshot. This change fixes
this by improving the generic duplicate name validation.

On top of this the lack of data stream alias validation in Metadata.Builder#build()
method resulted in cases where data stream aliases could be added for existing
index aliases, data streams or indices with the same name.

Closes elastic#80972
@martijnvg martijnvg added auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) backport labels Nov 30, 2021
…ngIndicesAlias() test

and fix the test problem, which is that testRestoreDataStreamAliasWithConflictingDataStream()
test needs to remove the composable index template that it adds. The base test class
doesn't remove any composable index templates and this template interferes with the
testRestoreDataStreamAliasWithConflictingIndicesAlias() test.

Relates to elastic#81040
@elasticsearchmachine elasticsearchmachine merged commit af5fa3f into elastic:7.16 Nov 30, 2021
@danhermann danhermann added v7.16.0 and removed v7.16.1 labels Dec 3, 2021
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 v7.16.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants