Expand description
DataFusion adapter for uni_plugin::traits::aggregate::AggregatePluginFn.
Bridges plugin-registered aggregates (AggregatePluginFn) into the
DataFusion AggregateUDFImpl surface so the Cypher planner can
invoke RETURN myAgg(x) against any registry entry, not just the
handful of built-ins hard-coded in df_planner.rs::translate_aggregates.
M9 ships this in support of uni.plugin.declareAggregate (see
uni-plugin-custom::DeclaredAggregateFn). The adapter is generic
across any AggregatePluginFn source — it does not assume the
declared shape.
§State model
Plugin aggregates’ AggSignature.state_fields declares the schema
of partial state for distributed aggregation. The M9 declared
aggregates ship with state_fields: vec![] and
supports_partial: false; the adapter respects whatever the
registry entry declares.
Structs§
- Plugin
Aggregate Udaf - DataFusion
AggregateUDFImplwrapping a plugin-registered aggregate looked up byQNamein the sharedPluginRegistry.