-
Notifications
You must be signed in to change notification settings - Fork 25.6k
SQL: Fix translation of math functions to painless #35910
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
Conversation
|
Pinging @elastic/es-search |
`SIGN` and `RADIANS` where wrongly overriding `mathFunction()`. Converted `mathFunction()` to private in `MathFunction` since it shouldn't be overriden, as it uses the assigned `MathOperation` to get the funtion name for painless scripts. Fixes: elastic#35654
astefan
left a comment
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. I like the test!
costin
left a comment
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.
left a comment.
| } | ||
|
|
||
| protected String mathFunction() { | ||
| private String mathFunction() { |
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.
Let's remove this method all together and simply use the classname inside the template.
`SIGN` and `RADIANS` where wrongly overriding `mathFunction()`. Converted `mathFunction()` to private in `MathFunction` since it shouldn't be overriden, as it uses the assigned `MathOperation` to get the funtion name for painless scripts. Fixes: #35654
|
Backported to |
`SIGN` and `RADIANS` where wrongly overriding `mathFunction()`. Converted `mathFunction()` to private in `MathFunction` since it shouldn't be overriden, as it uses the assigned `MathOperation` to get the funtion name for painless scripts. Fixes: #35654
|
Backported to |
SIGNandRADIANSwhere wrongly overridingmathFunction().Converted
mathFunction()to private inMathFunctionsince itshouldn't be overriden, as it uses the assigned
MathOperationto get the funtion name for painless scripts.
Fixes: #35654