Class ValuesSourceAggregatorFactory
java.lang.Object
org.elasticsearch.search.aggregations.AggregatorFactory
org.elasticsearch.search.aggregations.support.ValuesSourceAggregatorFactory
- Direct Known Subclasses:
AbstractRangeAggregatorFactory
,AutoDateHistogramAggregatorFactory
,BinaryRangeAggregatorFactory
,DateHistogramAggregatorFactory
,DiversifiedAggregatorFactory
,GeoDistanceRangeAggregatorFactory
,GeoHashGridAggregatorFactory
,GeoTileGridAggregatorFactory
,HistogramAggregatorFactory
,MedianAbsoluteDeviationAggregatorFactory
,MissingAggregatorFactory
,RareTermsAggregatorFactory
,SignificantTermsAggregatorFactory
,TermsAggregatorFactory
,VariableWidthHistogramAggregatorFactory
-
Field Summary
-
Constructor Summary
ConstructorDescriptionValuesSourceAggregatorFactory
(String name, ValuesSourceConfig config, AggregationContext context, AggregatorFactory parent, AggregatorFactories.Builder subFactoriesBuilder, Map<String, Object> metadata) -
Method Summary
Modifier and TypeMethodDescriptioncreateInternal
(Aggregator parent, CardinalityUpperBound cardinality, Map<String, Object> metadata) protected abstract Aggregator
createUnmapped
(Aggregator parent, Map<String, Object> metadata) Create the Aggregator for aValuesSource
that doesn't have values.protected abstract Aggregator
doCreateInternal
(Aggregator parent, CardinalityUpperBound cardinality, Map<String, Object> metadata) Create the Aggregator for aValuesSource
that has values.Returns the aggregation subtype for nodes usage stats.Methods inherited from class org.elasticsearch.search.aggregations.AggregatorFactory
create, doValidate, getParent, name
-
Field Details
-
config
-
-
Constructor Details
-
ValuesSourceAggregatorFactory
public ValuesSourceAggregatorFactory(String name, ValuesSourceConfig config, AggregationContext context, AggregatorFactory parent, AggregatorFactories.Builder subFactoriesBuilder, Map<String, Object> metadata) throws IOException- Throws:
IOException
-
-
Method Details
-
createInternal
public Aggregator createInternal(Aggregator parent, CardinalityUpperBound cardinality, Map<String, Object> metadata) throws IOException- Specified by:
createInternal
in classAggregatorFactory
- Throws:
IOException
-
createUnmapped
protected abstract Aggregator createUnmapped(Aggregator parent, Map<String, Object> metadata) throws IOExceptionCreate the Aggregator for aValuesSource
that doesn't have values.- Throws:
IOException
-
doCreateInternal
protected abstract Aggregator doCreateInternal(Aggregator parent, CardinalityUpperBound cardinality, Map<String, Object> metadata) throws IOExceptionCreate the Aggregator for aValuesSource
that has values.- Parameters:
cardinality
- Upper bound of the number ofowningBucketOrd
s that theAggregator
created by this method will be asked to collect.- Throws:
IOException
-
getStatsSubtype
Description copied from class:AggregatorFactory
Returns the aggregation subtype for nodes usage stats.It should match the types registered by calling AggregationUsageService. In other words, it should be ValueSourcesType for the VST aggregations OTHER_SUBTYPE for all other aggregations.
- Overrides:
getStatsSubtype
in classAggregatorFactory
-