Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Expression script engine cleanups around _value usage (elastic#99706)
We have found some inconsistencies as part of elastic#99667, around the current usages of ReplaceableConstDoubleValueSource in ExpressionsScriptEngine. It looks like _value is exposed to the bindings of score scripts, but setValue is never called hence it will always be 0. That can be replaced with a constant double values source, but the next question is whether it even needs to be added to the bindings then. Another cleanup discussed in elastic#99667 is throwing UnsupportedOperationException from ReplaceableConstDoubleValueSource#explain as it should never be called. Implementing the method means we need to test it which makes little sense if the method is never called in production code.
- Loading branch information