-
Notifications
You must be signed in to change notification settings - Fork 25k
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
Add scripts to keyword field mapper #71555
Add scripts to keyword field mapper #71555
Conversation
Pinging @elastic/es-search (Team:Search) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
super(name); | ||
this.indexAnalyzers = indexAnalyzers; | ||
this.scriptCompiler = scriptCompiler; | ||
this.script.precludesParameters(nullValue); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how about ignore_above and normalizer? Should they be supported when a script is set?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I've included those - they're both things that are applied after a value has been read, as opposed to null_value
which is applied instead of a value.
} | ||
|
||
public Builder(String name) { | ||
this(name, null); | ||
this(name, null, null); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ehm, I think you'll have to use ScriptCompiler.NONE here
This commit adds script and on_script_error parameters to keyword field mappers, allowing you to define index-time scripts for keyword fields.
This commit adds
script
andon_script_error
parameters tokeyword field mappers, allowing you to define index-time scripts
for keyword fields.