Open nik9000 opened 5 months ago
Pinging @elastic/es-analytical-engine (Team:Analytics)
There's a bug with optimization rules looping. Good find @dgieselaar !
POST _query
{
"query": """
ROW id = [ "a", "b" ]
| LOOKUP joins ON id
| MV_EXPAND id
""",
"tables": {
"joins": {
"id": {
"keyword": [ "a", "b"]
},
"join": {
"keyword": [ "c", "d" ]
}
}
}
}
This results in
Rule execution limit [100] reached
Description
Because LOOKUP is super experimental we're going to merge without doing a few things. These are all things we're ok doing after merging, but want to do before too long
TODO next:
Join.references()
by either moving the join condition and match fields out of theJoinConfig
intoJoin
, or by overridingJoin.references()
directly. https://github.com/elastic/elasticsearch/pull/109989Move mapTable to LocalRelation to the PreAnalyzer phase (https://github.com/elastic/elasticsearch/pull/107987/files#r1587059151) https://github.com/elastic/elasticsearch/issues/109541 https://github.com/elastic/elasticsearch/pull/110097Turns out it's not worth it at the moment. That change would have made more trouble than improvements.TODO soon:
TODO before we drop experimental:
tables
parameter https://github.com/elastic/elasticsearch/pull/109489TODO eventually:
LogicalPlanOptimizer.PruneColumns
and other optimizer rules that are applied to Eval/Grok/Dissect/Enrich but not yet Lookup