Skip to content

Commit

Permalink
docs(aggregators.final): Clarify output strategy
Browse files Browse the repository at this point in the history
  • Loading branch information
powersj committed Apr 17, 2024
1 parent c443b76 commit 1e441e0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 13 deletions.
13 changes: 5 additions & 8 deletions plugins/aggregators/final/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,18 +27,18 @@ See the [CONFIGURATION.md][CONFIGURATION.md] for more details.
[[aggregators.final]]
## The period on which to flush & clear the aggregator.
period = "30s"

## If true, the original metric will be dropped by the
## aggregator and will not get sent to the output plugins.
# drop_original = false

## The time that a series is not updated until considering it final.
## The time that a series is not updated until considering it final. Ignored
## when output_strategy is "periodic".
# series_timeout = "5m"

## Output strategy, supported values:
## timeout -- output a metric if no new input arrived for `series_timeout`;
## useful for filling gaps in input data
## periodic -- output the last received metric every `period`; useful to
## downsample the input data
## timeout -- output a metric if no new input arrived for `series_timeout`
## periodic -- output the last received metric every `period`
# output_strategy = "timeout"
```

Expand All @@ -50,13 +50,10 @@ will not guarantee a regular output of a `final` metric e.g. if the
series-timeout is a multiple of the gathering interval for an input. In this
case metric sporadically arrive in the timeout phase of the period and emitting
the `final` metric is suppressed.
This can be helpful to fill in gaps in the data if no input arrived in time.

Contrary to this, `output_strategy = "periodic"` will always output a `final`
metric at the end of the period irrespectively of when the last metric arrived,
the `series_timeout` is ignored.
This is helpful if you for example want to downsample input data arriving at a
high rate and require a periodic output of the `final` metric.

## Metrics

Expand Down
10 changes: 5 additions & 5 deletions plugins/aggregators/final/sample.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@
[[aggregators.final]]
## The period on which to flush & clear the aggregator.
period = "30s"

## If true, the original metric will be dropped by the
## aggregator and will not get sent to the output plugins.
# drop_original = false

## The time that a series is not updated until considering it final.
## The time that a series is not updated until considering it final. Ignored
## when output_strategy is "periodic".
# series_timeout = "5m"

## Output strategy, supported values:
## timeout -- output a metric if no new input arrived for `series_timeout`;
## useful for filling gaps in input data
## periodic -- output the last received metric every `period`; useful to
## downsample the input data
## timeout -- output a metric if no new input arrived for `series_timeout`
## periodic -- output the last received metric every `period`
# output_strategy = "timeout"

0 comments on commit 1e441e0

Please sign in to comment.