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

Be stricter about parsing boolean values in mappings. #16146

Conversation

Projects
None yet
2 participants
@jpountz
Copy link
Contributor

commented Jan 21, 2016

Parsing is currently very lenient, which has the bad side-effect that if you
have a typo and pass eg. store: fasle this will actually be interpreted as
store: true. Since mappings can't be changed after the fact, it is quite bad
if it happens on an index that already contains data.

Note that this does not cover all settings that accept a boolean, but since the
PR was quite hard to build and already covers some main settings like store
or doc_values this would already be a good incremental improvement.

Be stricter about parsing boolean values in mappings.
Parsing is currently very lenient, which has the bad side-effect that if you
have a typo and pass eg. `store: fasle` this will actually be interpreted as
`store: true`. Since mappings can't be changed after the fact, it is quite bad
if it happens on an index that already contains data.

Note that this does not cover all settings that accept a boolean, but since the
PR was quite hard to build and already covers some main settirgs like `store`
or `doc_values` this would already be a good incremental improvement.
@rjernst

This comment has been minimized.

Copy link
Member

commented Jan 21, 2016

LGTM

@jpountz

This comment has been minimized.

Copy link
Contributor Author

commented Jan 27, 2016

Fixed via 35709f6

@jpountz jpountz closed this Jan 27, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.