VictoriaMetrics/lib/streamaggr
Aliaksandr Valialkin 887555669e
Revert "lib/streamaggr: discard samples with timestamps outside of aggregation interval (#4199)"
This reverts commit 9e99f2f5b3.

Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4068

Reason for revert: this breaks valid use cases:

- If timestamps aren't specified in the incoming samples on purpose. For example, if stream aggregation is used
  as StatsD replacement. StatsD protocol has no timestamp concept for incoming samples.
  See https://github.com/b/statsd_spec

- If all the samples must be aggregated, even if they contain stale timestamps.
  for example, if the stream aggregation produces some counter of some events,
  it may be better to count all the events even if they were delayed before
  being ingested into VictoriaMetrics.

Is is also unclear how to determine whether the sample becomes stale.
For example, if the aggregation interval equals to 1h, and the previous
aggregation cycle just finished 10 minutes ago, what to do with the newly
incoming sample with the timestamp 30 minutes older than the current time?
The answer highly depends on the context, so it is unsafe to uncoditionally
use a single logic for dropping the old samples here.
2023-05-08 16:52:27 -07:00
..
avg.go
count_samples.go
count_series.go
histogram_bucket.go lib/streamaggr: remove unused fields 2023-01-04 13:33:46 -08:00
increase.go lib/streamaggr: remove unused fields 2023-01-04 13:33:46 -08:00
last.go
max.go
min.go
quantiles.go
stddev.go
stdvar.go
streamaggr_test.go Revert "lib/streamaggr: discard samples with timestamps outside of aggregation interval (#4199)" 2023-05-08 16:52:27 -07:00
streamaggr_timing_test.go lib/streamaggr: add ability to de-duplicate input samples before aggregation 2023-01-25 09:14:49 -08:00
streamaggr.go Revert "lib/streamaggr: discard samples with timestamps outside of aggregation interval (#4199)" 2023-05-08 16:52:27 -07:00
sum_samples.go
total.go