Standardize runtime field emit methods#61752
Standardize runtime field emit methods#61752nik9000 merged 1 commit intoelastic:feature/runtime_fieldsfrom
Conversation
This standardizes that name for all of the "emit value" methods used by runtime field scripts to `emitValue`. To make dates possible this adds a a `toEpochMilli` method to convert from `TemporalAccessor` into millis since epoch.
|
Pinging @elastic/es-search (:Search/Search) |
javanna
left a comment
There was a problem hiding this comment.
LGTM, only one question: with this every context supports one return type, and some types require conversions through specific function calls to adapt values to the required return type? I guess with this I am double checking that emitValue always and only accept one argument type per context.
All correct. Painless itself doesn't have support for arguments with different types so we just pick a "native" type for each. |
This standardizes that name for all of the "emit value" methods used by
runtime field scripts to
emitValue. To make dates possible this adds aa
toEpochMillimethod to convert fromTemporalAccessorinto millissince epoch.