Skip to content

Conversation

@javanna
Copy link
Member

@javanna javanna commented May 4, 2021

With #72616 we have changed the way that empty mappings are created for an index. Accidentally such mappings have been created with an empty meta map instead of null, which causes test failures in tests that compare mappings and are now finding an unexpected empty meta object which was not there before.

This commit fixes the empty mapping to not hold any meta, replacing the empty map with a null argument.

With elastic#72616 we have changed the way that empty mappings are created for an index. Accidentally such mappings have been created with an empty meta map instead of null, which causes test failures in tests that compare mappings and are now finding an unexpected empty meta object which was not there before.

This commit fixes the empty mapping to not hold any meta, replacing the empty map with a null argument.
@javanna javanna added >test Issues or PRs that are addressing/adding tests :Search Foundations/Mapping Index mappings, including merging and defining field types v8.0.0 v7.14.0 labels May 4, 2021
@javanna javanna requested review from romseygeek and tlrx May 4, 2021 15:21
@elasticmachine elasticmachine added the Team:Search Meta label for search team label May 4, 2021
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search (Team:Search)

Copy link
Contributor

@romseygeek romseygeek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Maybe add a specific test to check serialization of the empty mapper?

Copy link
Member

@tlrx tlrx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@javanna
Copy link
Member Author

javanna commented May 4, 2021

@romseygeek I pushed a test, and I also fixed the empty mappipng lookup to hold null meta instead of empty map.

Copy link
Contributor

@romseygeek romseygeek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @javanna

@javanna javanna merged commit 291b0d8 into elastic:master May 4, 2021
javanna added a commit to javanna/elasticsearch that referenced this pull request May 4, 2021
With elastic#72616 we have changed the way that empty mappings are created for an index. Accidentally such mappings have been created with an empty meta map instead of null, which causes test failures in tests that compare mappings and are now finding an unexpected empty meta object which was not there before.

This commit fixes the empty mapping to not hold any meta, replacing the empty map with a null argument.
javanna added a commit that referenced this pull request May 4, 2021
With #72616 we have changed the way that empty mappings are created for an index. Accidentally such mappings have been created with an empty meta map instead of null, which causes test failures in tests that compare mappings and are now finding an unexpected empty meta object which was not there before.

This commit fixes the empty mapping to not hold any meta, replacing the empty map with a null argument.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Search Foundations/Mapping Index mappings, including merging and defining field types Team:Search Meta label for search team >test Issues or PRs that are addressing/adding tests v7.14.0 v8.0.0-alpha1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants