Class StringFirstFoldingAggregatorFactory
java.lang.Object
org.apache.druid.query.aggregation.AggregatorFactory
org.apache.druid.query.aggregation.firstlast.first.StringFirstAggregatorFactory
org.apache.druid.query.aggregation.firstlast.first.StringFirstFoldingAggregatorFactory
- All Implemented Interfaces:
Cacheable
For backwards compatibility; equivalent to a regular StringFirstAggregatorFactory.
-
Field Summary
Fields inherited from class org.apache.druid.query.aggregation.firstlast.first.StringFirstAggregatorFactory
DEFAULT_MAX_STRING_SIZE, maxStringBytes, NIL_VECTOR_AGGREGATOR, TIME_COMPARATOR, TYPE, VALUE_COMPARATOR -
Constructor Summary
ConstructorsConstructorDescriptionStringFirstFoldingAggregatorFactory(String name, String fieldName, Integer maxStringBytes) -
Method Summary
Modifier and TypeMethodDescriptionUsed in cases where we want to change the output name of the aggregator to something else.Methods inherited from class org.apache.druid.query.aggregation.firstlast.first.StringFirstAggregatorFactory
canVectorize, combine, deserialize, equals, factorize, factorizeBuffered, factorizeVector, finalizeComputation, getCacheKey, getCombiningFactory, getComparator, getFieldName, getIntermediateType, getMaxIntermediateSize, getMaxStringBytes, getName, getResultType, getTimeColumn, hashCode, makeAggregateCombiner, requiredFields, toStringMethods inherited from class org.apache.druid.query.aggregation.AggregatorFactory
factorizeWithSize, getComplexTypeName, getFinalizedType, getMaxIntermediateSizeWithNulls, getMergingFactory, getRequiredColumns, getType, guessAggregatorHeapFootprint, makeNullableAggregateCombiner, mergeAggregators, optimizeForSegment, substituteCombiningFactory
-
Constructor Details
-
StringFirstFoldingAggregatorFactory
-
-
Method Details
-
withName
Description copied from class:AggregatorFactoryUsed in cases where we want to change the output name of the aggregator to something else. For eg: if we have a query `select a, sum(b) as total group by a from table` the aggregator returned from the native group by query is "a0" set in. We can use withName("total") to set the output name of the aggregator to "total".invalid reference
org.apache.druid.sql.calcite.rel.DruidQuery#computeAggregationsAs all implementations of this interface method may not exist, callers of this method are advised to handle such a case.
- Overrides:
withNamein classStringFirstAggregatorFactory- Parameters:
newName- newName of the output for aggregator factory- Returns:
- AggregatorFactory with the output name set as the input param.
-