Skip to content

[8.0] Fix data stream alias validation. (#81040)#81135

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

[8.0] Fix data stream alias validation. (#81040)#81135
elasticsearchmachine merged 2 commits intoelastic:8.0from
martijnvg:backport/8.0/pr-81040

Conversation

@martijnvg
Copy link
Copy Markdown
Member

Backports the following commits to 8.0:

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 a774a7b into elastic:8.0 Nov 30, 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 v8.0.0-rc1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants