Native tuple sketch functions (tuple_*, Spark 4.2): audit the crate against Java and implement

Aperta
#7,401 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 2 giorni

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
12/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
java, rust, scala, spark

Direzione di ricerca

This is a multi-part audit and implementation across the Rust tuple feature of the datasketches crate and Comet's Spark expression support, so it is not a starting point. Begin with the Spark 4.2 tuple function definitions and the existing theta sketch expressions in the Comet source, then compare the crate's summary types and union/intersection policies against DataSketches-Java 6.2.0 fixtures. Done means each tuple_* function runs natively with a Spark fallback before 4.2, backed by committed fixtures and tests.

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

Descrizione

area:aggregation area:expressions enhancement

What is the problem the feature request solves?

Part of #7397.

Spark 4.2 adds Tuple sketch functions: tuple_sketch_agg, tuple_union_agg, tuple_intersection_agg, the tuple_difference / tuple_union / tuple_intersection scalars, and tuple_sketch_estimate, tuple_sketch_summary and tuple_sketch_theta, each in integer and double summary variants. None of them run natively in Comet. The crate's tuple feature arrived in datasketches 0.4.0.

Describe the potential solution

  1. Score the family with suggest-native-expression first. This is the lowest priority of the four, because it only exists in the newest Spark version Comet supports.
  2. Do the theta work first, since a tuple sketch is a theta sketch with a summary attached and shares its hashing and set-operation behavior.
  3. Audit the crate's tuple feature against DataSketches-Java 6.2.0 using committed fixtures. The summary types and the policies that combine summaries on union and intersection need to match Spark's exactly, and the serialized summary format has to be readable in both directions.
  4. Implement, test and document as for the other families, with a fallback on Spark versions before 4.2.
Lingua principale
Scala
Stelle
1.3k
Fork
414
Merge medio
3g 5h
PR unite (30g)
210

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di apache/datafusion-comet

Tutte le issue di apache/datafusion-comet

Issue simili

Altre issue su Scala

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.