You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am going to close this issue since the ScriptFieldsPhase is a FetchSubPhase. It means push down a script field would have less performance improvement. Instead, it requires additional script compiling.
I will pick this up because we found OpenSearch DerivedFieldScript could address the concern of not evaluating project expressions on whole data rows. With whole project script pushdown, it will also unblock sort expression pushdown.
A concern to implement project pushdown with either ScriptFields or DerivedFieldScript. They don't support sorting according to the official document.
ScriptField is kind of postprocessing based on input fields after each shard search phase, which means it doesn't support filtering.
DerivedFieldScript is a runtime field that is generated at search phase. Although it can support filtering, scoring and sorting is not supported yet.
See my justification in #4288 (comment). Even though we can pushdown project in distributed search, we don't have strong case to show better performance improvement.
Activity
LantaoJin commentedon Jul 28, 2025
I am going to close this issue since the
ScriptFieldsPhaseis aFetchSubPhase. It means push down a script field would have less performance improvement. Instead, it requires additional script compiling.2 remaining items
gaobinlong commentedon Aug 1, 2025
Yes, by checking the code, ScriptFieldsPhase executes on each shard, FetchSearchPhase executes on coordinator node.
songkant-aws commentedon Aug 28, 2025
I will pick this up because we found OpenSearch DerivedFieldScript could address the concern of not evaluating project expressions on whole data rows. With whole project script pushdown, it will also unblock sort expression pushdown.
songkant-aws commentedon Sep 4, 2025
A concern to implement project pushdown with either ScriptFields or DerivedFieldScript. They don't support sorting according to the official document.
ScriptField is kind of postprocessing based on input fields after each shard search phase, which means it doesn't support filtering.
DerivedFieldScript is a runtime field that is generated at search phase. Although it can support filtering, scoring and sorting is not supported yet.
songkant-aws commentedon Oct 24, 2025
See my justification in #4288 (comment). Even though we can pushdown project in distributed search, we don't have strong case to show better performance improvement.