Microsoft.ApplicationInsights.Metrics.Extensibility.MetricSeriesAggregatorBase<TBufferedValue>
The abstract base contain functionaity shared by most aggregators.
Gets the data series aggregated by this aggregator.
protected MetricSeriesAggregatorBase(Func<MetricValuesBufferBase<TBufferedValue>> metricValuesBufferFactory, IMetricSeriesConfiguration configuration, MetricSeries dataSeries, MetricAggregationCycleKind aggregationCycleKind)
Initializes an aggregator instance.
protected void AddInfo_Timing_Dimensions_Context(MetricAggregate aggregate, DateTimeOffset periodEnd)
Populate common fields of just-constructed metric aggregate.
Finishes the aggregation cycle.
Concrete aggregator imlemenations override this to convert the metric value passed to the
public TrackValue(..) method to the typed used by the internal buffer.
Concrete aggregator imlemenations override this to convert the metric value passed to the
public TrackValue(..) method to the typed used by the internal buffer.
Concrete aggregator imlemenations override this to actually create an aggregate form the tracked matric values.
Get an aggregate of the values tracked so far without completing the ongoing aggregation cycle.
May not be thread-safe.
Clear the state of this aggregator to allow it to be reused for a new aggregation cycle.
Clear the state of this aggregator to allow it to be reused for a new aggregation cycle.
Concrete aggregator imlemenations override this to actually reset the aggregator.
Track a metric va,ue for inclusion into the current cycle.
Track a metric va,ue for inclusion into the current cycle.
Clear the state of this aggregator to allow it to be reused for a new aggregation cycle.
protected abstract object UpdateAggregate_Stage1(MetricValuesBufferBase<TBufferedValue> buffer, int minFlushIndex, int maxFlushIndex)
Aggregators implement updating aggregate state from buffer by implemenmting this method (UpdateAggregate_Stage1)
and its sibling method UpdateAggregate_Stage2. Stage 1 is the part of the update that needs to happen while holding
a lock on the metric values buffer (e.g. extracting a summary from the buffer). Stage 2 is the part of the update
that does not need such a lock.
Aggregators implement updating aggregate state from buffer by implemenmting this method (UpdateAggregate_Stage2)
and its sibling method UpdateAggregate_Stage1. Stage 1 is the part of the update that needs to happen while holding
a lock on the metric values buffer (e.g. extracting a summary from the buffer). Stage 2 is the part of the update
that does not need such a lock.