Pass aggregator suppliers as aggregator factory constructor arguments #58136
Labels
:Analytics/Aggregations
Aggregations
>refactoring
Team:Analytics
Meta label for analytical engine team (ESQL/Aggs/Geo)
Currently, during aggregator construction, we look up the supplier from the ValuesSourceRegistry twice. Once in
ValuesSourceAggregationBuilder#doBuild
and then again in the specific factory'sdoCreateInternal
method. Instead, we could just pass the instance we already have from VSAB and streamlinedoCreateInternal
. While we're touching that, we can get rid of the type checking around the suppliers. It was handy when we were writing the registry to see if we wired something up wrong, but now it's just so much boiler plate. Could be replaced with an assert or even just a bare cast.The text was updated successfully, but these errors were encountered: