apache / apache/datafusion

Allow user defined ExecutionPlans to benefit from pushdown behavior

Aperta
#8,096 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub
enhancement
Lingua principale
Rust
Stelle
9.3k
Fork
2.4k
Merge medio
3g 11h
PR unite (30g)
360

Descrizione

### Is your feature request related to a problem or challenge?

https://github.com/apache/arrow-datafusion/pull/8073 adds support for projection pushdown in the physical optimizer.

However, its implementation directly checks for and special cases the built in ExecutionPlan nodes in DataFusion (which other optimizer passes do as well)

For example
```rust
} else if let Some(output_req) = input.downcast_ref::() {
try_swapping_with_output_req(projection, output_req)?
} else if input.is::() {
try_swapping_with_coalesce_partitions(projection)?
} else if let Some(filter) = input.downcast_ref::() {
try_swapping_with_filter(projection, filter)?
} else if let Some(repartition) = input.downcast_ref::() {
try_swapping_with_repartition(projection, repartition)?
} else if let Some(sort) = input.downcast_ref::() {
try_swapping_with_sort(projection, sort)?
```

### Describe the solution you'd like

It would be nice if there was an abstraction somehow where ProjectionPushdown could be used by extension / user defined `ExecutionPlan` nodes

### Describe alternatives you've considered

There is a really nice discussion between @crepererum and @ozankabak here https://github.com/apache/arrow-datafusion/pull/8073#discussion_r1386515290 that provides insight and various options.

### Additional context

_No response_

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Inizia con la PR 8073 e la sua implementazione del projection-pushdown nell’ottimizzatore fisico, in particolare con i controlli integrati di ExecutionPlan mostrati qui. Esamina la discussione collegata sulle opzioni di astrazione proposte e determina come dovrebbero partecipare i nodi di ExecutionPlan definiti dall’utente; il lavoro è completo quando i nodi di estensione possono beneficiare di ProjectionPushdown senza casi speciali per i nodi integrati.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
rust
Ambito
backend, backend-api-design
Tipo di issue
Funzionalità
Difficoltà
5/5
Tempo stimato
Più di una settimana
Stato di attività
Ferma
Chiarezza
Da chiarire
Idoneità per principianti
25/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.