diff --git a/app/vmselect/promql/eval.go b/app/vmselect/promql/eval.go index 008822137..ccaeff2d7 100644 --- a/app/vmselect/promql/eval.go +++ b/app/vmselect/promql/eval.go @@ -910,9 +910,11 @@ func mulNoOverflow(a, b int64) int64 { } func dropStaleNaNs(funcName string, values []float64, timestamps []int64) ([]float64, []int64) { - if *noStaleMarkers || funcName == "default_rollup" { + if *noStaleMarkers || funcName == "default_rollup" || funcName == "stale_samples_over_time" { // Do not drop Prometheus staleness marks (aka stale NaNs) for default_rollup() function, // since it uses them for Prometheus-style staleness detection. + // Do not drop staleness marks for stale_samples_over_time() function, since it needs + // to calculate the number of staleness markers. return values, timestamps } // Remove Prometheus staleness marks, so non-default rollup functions don't hit NaN values. diff --git a/app/vmselect/promql/rollup.go b/app/vmselect/promql/rollup.go index 477d091ab..cb982c26b 100644 --- a/app/vmselect/promql/rollup.go +++ b/app/vmselect/promql/rollup.go @@ -19,69 +19,70 @@ var minStalenessInterval = flag.Duration("search.minStalenessInterval", 0, "The "See also '-search.maxStalenessInterval'") var rollupFuncs = map[string]newRollupFunc{ - "absent_over_time": newRollupFuncOneArg(rollupAbsent), - "aggr_over_time": newRollupFuncTwoArgs(rollupFake), - "ascent_over_time": newRollupFuncOneArg(rollupAscentOverTime), - "avg_over_time": newRollupFuncOneArg(rollupAvg), - "changes": newRollupFuncOneArg(rollupChanges), - "changes_prometheus": newRollupFuncOneArg(rollupChangesPrometheus), - "count_eq_over_time": newRollupCountEQ, - "count_gt_over_time": newRollupCountGT, - "count_le_over_time": newRollupCountLE, - "count_ne_over_time": newRollupCountNE, - "count_over_time": newRollupFuncOneArg(rollupCount), - "decreases_over_time": newRollupFuncOneArg(rollupDecreases), - "default_rollup": newRollupFuncOneArg(rollupDefault), // default rollup func - "delta": newRollupFuncOneArg(rollupDelta), - "delta_prometheus": newRollupFuncOneArg(rollupDeltaPrometheus), - "deriv": newRollupFuncOneArg(rollupDerivSlow), - "deriv_fast": newRollupFuncOneArg(rollupDerivFast), - "descent_over_time": newRollupFuncOneArg(rollupDescentOverTime), - "distinct_over_time": newRollupFuncOneArg(rollupDistinct), - "duration_over_time": newRollupDurationOverTime, - "first_over_time": newRollupFuncOneArg(rollupFirst), - "geomean_over_time": newRollupFuncOneArg(rollupGeomean), - "histogram_over_time": newRollupFuncOneArg(rollupHistogram), - "hoeffding_bound_lower": newRollupHoeffdingBoundLower, - "hoeffding_bound_upper": newRollupHoeffdingBoundUpper, - "holt_winters": newRollupHoltWinters, - "idelta": newRollupFuncOneArg(rollupIdelta), - "ideriv": newRollupFuncOneArg(rollupIderiv), - "increase": newRollupFuncOneArg(rollupDelta), // + rollupFuncsRemoveCounterResets - "increase_prometheus": newRollupFuncOneArg(rollupDeltaPrometheus), // + rollupFuncsRemoveCounterResets - "increase_pure": newRollupFuncOneArg(rollupIncreasePure), // + rollupFuncsRemoveCounterResets - "increases_over_time": newRollupFuncOneArg(rollupIncreases), - "integrate": newRollupFuncOneArg(rollupIntegrate), - "irate": newRollupFuncOneArg(rollupIderiv), // + rollupFuncsRemoveCounterResets - "lag": newRollupFuncOneArg(rollupLag), - "last_over_time": newRollupFuncOneArg(rollupLast), - "lifetime": newRollupFuncOneArg(rollupLifetime), - "max_over_time": newRollupFuncOneArg(rollupMax), - "min_over_time": newRollupFuncOneArg(rollupMin), - "mode_over_time": newRollupFuncOneArg(rollupModeOverTime), - "predict_linear": newRollupPredictLinear, - "present_over_time": newRollupFuncOneArg(rollupPresent), - "quantile_over_time": newRollupQuantile, - "quantiles_over_time": newRollupQuantiles, - "range_over_time": newRollupFuncOneArg(rollupRange), - "rate": newRollupFuncOneArg(rollupDerivFast), // + rollupFuncsRemoveCounterResets - "rate_over_sum": newRollupFuncOneArg(rollupRateOverSum), - "resets": newRollupFuncOneArg(rollupResets), - "rollup": newRollupFuncOneArg(rollupFake), - "rollup_candlestick": newRollupFuncOneArg(rollupFake), - "rollup_delta": newRollupFuncOneArg(rollupFake), - "rollup_deriv": newRollupFuncOneArg(rollupFake), - "rollup_increase": newRollupFuncOneArg(rollupFake), // + rollupFuncsRemoveCounterResets - "rollup_rate": newRollupFuncOneArg(rollupFake), // + rollupFuncsRemoveCounterResets - "rollup_scrape_interval": newRollupFuncOneArg(rollupFake), - "scrape_interval": newRollupFuncOneArg(rollupScrapeInterval), - "share_gt_over_time": newRollupShareGT, - "share_le_over_time": newRollupShareLE, - "stddev_over_time": newRollupFuncOneArg(rollupStddev), - "stdvar_over_time": newRollupFuncOneArg(rollupStdvar), - "sum_over_time": newRollupFuncOneArg(rollupSum), - "sum2_over_time": newRollupFuncOneArg(rollupSum2), - "tfirst_over_time": newRollupFuncOneArg(rollupTfirst), + "absent_over_time": newRollupFuncOneArg(rollupAbsent), + "aggr_over_time": newRollupFuncTwoArgs(rollupFake), + "ascent_over_time": newRollupFuncOneArg(rollupAscentOverTime), + "avg_over_time": newRollupFuncOneArg(rollupAvg), + "changes": newRollupFuncOneArg(rollupChanges), + "changes_prometheus": newRollupFuncOneArg(rollupChangesPrometheus), + "count_eq_over_time": newRollupCountEQ, + "count_gt_over_time": newRollupCountGT, + "count_le_over_time": newRollupCountLE, + "count_ne_over_time": newRollupCountNE, + "count_over_time": newRollupFuncOneArg(rollupCount), + "decreases_over_time": newRollupFuncOneArg(rollupDecreases), + "default_rollup": newRollupFuncOneArg(rollupDefault), // default rollup func + "delta": newRollupFuncOneArg(rollupDelta), + "delta_prometheus": newRollupFuncOneArg(rollupDeltaPrometheus), + "deriv": newRollupFuncOneArg(rollupDerivSlow), + "deriv_fast": newRollupFuncOneArg(rollupDerivFast), + "descent_over_time": newRollupFuncOneArg(rollupDescentOverTime), + "distinct_over_time": newRollupFuncOneArg(rollupDistinct), + "duration_over_time": newRollupDurationOverTime, + "first_over_time": newRollupFuncOneArg(rollupFirst), + "geomean_over_time": newRollupFuncOneArg(rollupGeomean), + "histogram_over_time": newRollupFuncOneArg(rollupHistogram), + "hoeffding_bound_lower": newRollupHoeffdingBoundLower, + "hoeffding_bound_upper": newRollupHoeffdingBoundUpper, + "holt_winters": newRollupHoltWinters, + "idelta": newRollupFuncOneArg(rollupIdelta), + "ideriv": newRollupFuncOneArg(rollupIderiv), + "increase": newRollupFuncOneArg(rollupDelta), // + rollupFuncsRemoveCounterResets + "increase_prometheus": newRollupFuncOneArg(rollupDeltaPrometheus), // + rollupFuncsRemoveCounterResets + "increase_pure": newRollupFuncOneArg(rollupIncreasePure), // + rollupFuncsRemoveCounterResets + "increases_over_time": newRollupFuncOneArg(rollupIncreases), + "integrate": newRollupFuncOneArg(rollupIntegrate), + "irate": newRollupFuncOneArg(rollupIderiv), // + rollupFuncsRemoveCounterResets + "lag": newRollupFuncOneArg(rollupLag), + "last_over_time": newRollupFuncOneArg(rollupLast), + "lifetime": newRollupFuncOneArg(rollupLifetime), + "max_over_time": newRollupFuncOneArg(rollupMax), + "min_over_time": newRollupFuncOneArg(rollupMin), + "mode_over_time": newRollupFuncOneArg(rollupModeOverTime), + "predict_linear": newRollupPredictLinear, + "present_over_time": newRollupFuncOneArg(rollupPresent), + "quantile_over_time": newRollupQuantile, + "quantiles_over_time": newRollupQuantiles, + "range_over_time": newRollupFuncOneArg(rollupRange), + "rate": newRollupFuncOneArg(rollupDerivFast), // + rollupFuncsRemoveCounterResets + "rate_over_sum": newRollupFuncOneArg(rollupRateOverSum), + "resets": newRollupFuncOneArg(rollupResets), + "rollup": newRollupFuncOneArg(rollupFake), + "rollup_candlestick": newRollupFuncOneArg(rollupFake), + "rollup_delta": newRollupFuncOneArg(rollupFake), + "rollup_deriv": newRollupFuncOneArg(rollupFake), + "rollup_increase": newRollupFuncOneArg(rollupFake), // + rollupFuncsRemoveCounterResets + "rollup_rate": newRollupFuncOneArg(rollupFake), // + rollupFuncsRemoveCounterResets + "rollup_scrape_interval": newRollupFuncOneArg(rollupFake), + "scrape_interval": newRollupFuncOneArg(rollupScrapeInterval), + "share_gt_over_time": newRollupShareGT, + "share_le_over_time": newRollupShareLE, + "stale_samples_over_time": newRollupFuncOneArg(rollupStaleSamples), + "stddev_over_time": newRollupFuncOneArg(rollupStddev), + "stdvar_over_time": newRollupFuncOneArg(rollupStdvar), + "sum_over_time": newRollupFuncOneArg(rollupSum), + "sum2_over_time": newRollupFuncOneArg(rollupSum2), + "tfirst_over_time": newRollupFuncOneArg(rollupTfirst), // `timestamp` function must return timestamp for the last datapoint on the current window // in order to properly handle offset and timestamps unaligned to the current step. // See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/415 for details. @@ -95,50 +96,51 @@ var rollupFuncs = map[string]newRollupFunc{ // rollupAggrFuncs are functions that can be passed to `aggr_over_time()` var rollupAggrFuncs = map[string]rollupFunc{ - "absent_over_time": rollupAbsent, - "ascent_over_time": rollupAscentOverTime, - "avg_over_time": rollupAvg, - "changes": rollupChanges, - "count_over_time": rollupCount, - "decreases_over_time": rollupDecreases, - "default_rollup": rollupDefault, - "delta": rollupDelta, - "deriv": rollupDerivSlow, - "deriv_fast": rollupDerivFast, - "descent_over_time": rollupDescentOverTime, - "distinct_over_time": rollupDistinct, - "first_over_time": rollupFirst, - "geomean_over_time": rollupGeomean, - "idelta": rollupIdelta, - "ideriv": rollupIderiv, - "increase": rollupDelta, - "increase_pure": rollupIncreasePure, - "increases_over_time": rollupIncreases, - "integrate": rollupIntegrate, - "irate": rollupIderiv, - "lag": rollupLag, - "last_over_time": rollupLast, - "lifetime": rollupLifetime, - "max_over_time": rollupMax, - "min_over_time": rollupMin, - "mode_over_time": rollupModeOverTime, - "present_over_time": rollupPresent, - "range_over_time": rollupRange, - "rate": rollupDerivFast, - "rate_over_sum": rollupRateOverSum, - "resets": rollupResets, - "scrape_interval": rollupScrapeInterval, - "stddev_over_time": rollupStddev, - "stdvar_over_time": rollupStdvar, - "sum_over_time": rollupSum, - "sum2_over_time": rollupSum2, - "tfirst_over_time": rollupTfirst, - "timestamp": rollupTlast, - "timestamp_with_name": rollupTlast, - "tlast_over_time": rollupTlast, - "tmax_over_time": rollupTmax, - "tmin_over_time": rollupTmin, - "zscore_over_time": rollupZScoreOverTime, + "absent_over_time": rollupAbsent, + "ascent_over_time": rollupAscentOverTime, + "avg_over_time": rollupAvg, + "changes": rollupChanges, + "count_over_time": rollupCount, + "decreases_over_time": rollupDecreases, + "default_rollup": rollupDefault, + "delta": rollupDelta, + "deriv": rollupDerivSlow, + "deriv_fast": rollupDerivFast, + "descent_over_time": rollupDescentOverTime, + "distinct_over_time": rollupDistinct, + "first_over_time": rollupFirst, + "geomean_over_time": rollupGeomean, + "idelta": rollupIdelta, + "ideriv": rollupIderiv, + "increase": rollupDelta, + "increase_pure": rollupIncreasePure, + "increases_over_time": rollupIncreases, + "integrate": rollupIntegrate, + "irate": rollupIderiv, + "lag": rollupLag, + "last_over_time": rollupLast, + "lifetime": rollupLifetime, + "max_over_time": rollupMax, + "min_over_time": rollupMin, + "mode_over_time": rollupModeOverTime, + "present_over_time": rollupPresent, + "range_over_time": rollupRange, + "rate": rollupDerivFast, + "rate_over_sum": rollupRateOverSum, + "resets": rollupResets, + "scrape_interval": rollupScrapeInterval, + "stale_samples_over_time": rollupStaleSamples, + "stddev_over_time": rollupStddev, + "stdvar_over_time": rollupStdvar, + "sum_over_time": rollupSum, + "sum2_over_time": rollupSum2, + "tfirst_over_time": rollupTfirst, + "timestamp": rollupTlast, + "timestamp_with_name": rollupTlast, + "tlast_over_time": rollupTlast, + "tmax_over_time": rollupTmax, + "tmin_over_time": rollupTmin, + "zscore_over_time": rollupZScoreOverTime, } // VictoriaMetrics can increase lookbehind window in square brackets for these functions @@ -1373,6 +1375,20 @@ func rollupCount(rfa *rollupFuncArg) float64 { return float64(len(values)) } +func rollupStaleSamples(rfa *rollupFuncArg) float64 { + values := rfa.values + if len(values) == 0 { + return nan + } + n := 0 + for _, v := range rfa.values { + if decimal.IsStaleNaN(v) { + n++ + } + } + return float64(n) +} + func rollupStddev(rfa *rollupFuncArg) float64 { stdvar := rollupStdvar(rfa) return math.Sqrt(stdvar) diff --git a/app/vmselect/promql/rollup_test.go b/app/vmselect/promql/rollup_test.go index ae0f2d9ab..c3a5708da 100644 --- a/app/vmselect/promql/rollup_test.go +++ b/app/vmselect/promql/rollup_test.go @@ -513,6 +513,7 @@ func TestRollupNewRollupFuncSuccess(t *testing.T) { f("sum2_over_time", 37951) f("geomean_over_time", 39.33466603189148) f("count_over_time", 12) + f("stale_samples_over_time", 0) f("stddev_over_time", 30.752935722554287) f("stdvar_over_time", 945.7430555555555) f("first_over_time", 123) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index f0d772cd5..b4a7ca7c5 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -28,6 +28,7 @@ sort: 15 * FEATURE: [vmalert](https://docs.victoriametrics.com/vmalert.html): expose `vmalert_remotewrite_total` metric at `/metrics` page. This makes possible calculating SLOs for error rate during writing recording rules and alert state to `-remoteWrite.url` with the query `vmalert_remotewrite_errors_total / vmalert_remotewrite_total`. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2040). Thanks to @afoninsky . * FEATURE: [vmalert](https://docs.victoriametrics.com/vmalert.html): add `stripPort` template function in the same way as [Prometheus does](https://github.com/prometheus/prometheus/pull/10002). * FEATURE: [vmalert](https://docs.victoriametrics.com/vmalert.html): add `parseDuration` template function in the same way as [Prometheus does](https://github.com/prometheus/prometheus/pull/8817). +* FEATURE: [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html): add `stale_samples_over_time(m[d])` function for calculating the number of [staleness marks](https://docs.victoriametrics.com/vmagent.html#prometheus-staleness-markers) for time series `m` over the duration `d`. This function may be useful for detecting flapping metrics at scrape targets, which periodically disappear and then appear again. * BUGFIX: [vmagent](https://docs.victoriametrics.com/vmagent.html): make sure that `vmagent` replicas scrape the same targets at different time offsets when [replication is enabled in vmagent clustering mode](https://docs.victoriametrics.com/vmagent.html#scraping-big-number-of-targets). This guarantees that the [deduplication](https://docs.victoriametrics.com/#deduplication) consistently leaves samples from the same `vmagent` replica. * BUGFIX: return the proper response stub from `/api/v1/query_exemplars` handler, which is needed for Grafana v8+. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1999). diff --git a/docs/MetricsQL.md b/docs/MetricsQL.md index 903fd962c..a000f4e6d 100644 --- a/docs/MetricsQL.md +++ b/docs/MetricsQL.md @@ -311,6 +311,10 @@ See also [implicit query conversions](#implicit-query-conversions). `share_le_over_time(series_selector[d], le)` returns share (in the range `[0...1]`) of raw samples on the given lookbehind window `d`, which are smaller or equal to `le`. It is calculated independently per each time series returned from the given [series_selector](https://prometheus.io/docs/prometheus/latest/querying/basics/#time-series-selectors). Metric names are stripped from the resulting rollups. Useful for calculating SLI and SLO. Example: `share_le_over_time(memory_usage_bytes[24h], 100*1024*1024)` returns the share of time series values for the last 24 hours when memory usage was below or equal to 100MB. See also [share_gt_over_time](#share_gt_over_time). +#### stale_samples_over_time + +`stale_samples_over_time(series_selector[d])` calculates the number of [staleness markers](https://docs.victoriametrics.com/vmagent.html#prometheus-staleness-markers) on the given lookbehind window `d` per each time series matching the given [series_selector](https://prometheus.io/docs/prometheus/latest/querying/basics/#time-series-selectors). Metric names are stripped from the resulting rollups. + #### stddev_over_time `stddev_over_time(series_selector[d])` calculates standard deviation over raw samples on the given lookbehind window `d` per each time series returned from the given [series_selector](https://prometheus.io/docs/prometheus/latest/querying/basics/#time-series-selectors). Metric names are stripped from the resulting rollups. This function is supported by PromQL. See also [stdvar_over_time](#stdvar_over_time). diff --git a/go.mod b/go.mod index 1ca7f6a4d..b6738d207 100644 --- a/go.mod +++ b/go.mod @@ -10,7 +10,7 @@ require ( // like https://github.com/valyala/fasthttp/commit/996610f021ff45fdc98c2ce7884d5fa4e7f9199b github.com/VictoriaMetrics/fasthttp v1.1.0 github.com/VictoriaMetrics/metrics v1.18.1 - github.com/VictoriaMetrics/metricsql v0.35.0 + github.com/VictoriaMetrics/metricsql v0.36.1 github.com/aws/aws-sdk-go v1.42.31 github.com/cespare/xxhash/v2 v2.1.2 github.com/cheggaaa/pb/v3 v3.0.8 diff --git a/go.sum b/go.sum index 044e373ae..0becfd362 100644 --- a/go.sum +++ b/go.sum @@ -112,11 +112,10 @@ github.com/VictoriaMetrics/fastcache v1.8.0 h1:ybZqS7kRy8YVzYsI09GLzQhs7iqS6cOEH github.com/VictoriaMetrics/fastcache v1.8.0/go.mod h1:n7Sl+ioh/HlWeYHLSIBIE8TcZFHg/+xgvomWSS5xuEE= github.com/VictoriaMetrics/fasthttp v1.1.0 h1:3crd4YWHsMwu60GUXRH6OstowiFvqrwS4a/ueoLdLL0= github.com/VictoriaMetrics/fasthttp v1.1.0/go.mod h1:/7DMcogqd+aaD3G3Hg5kFgoFwlR2uydjiWvoLp5ZTqQ= -github.com/VictoriaMetrics/metrics v1.12.2/go.mod h1:Z1tSfPfngDn12bTfZSCqArT3OPY3u88J12hSoOhuiRE= github.com/VictoriaMetrics/metrics v1.18.1 h1:OZ0+kTTto8oPfHnVAnTOoyl0XlRhRkoQrD2n2cOuRw0= github.com/VictoriaMetrics/metrics v1.18.1/go.mod h1:ArjwVz7WpgpegX/JpB0zpNF2h2232kErkEnzH1sxMmA= -github.com/VictoriaMetrics/metricsql v0.35.0 h1:jK/+UhPb5o2OESZcqifp9hl0rURPgCwY6coy8OlbIss= -github.com/VictoriaMetrics/metricsql v0.35.0/go.mod h1:ylO7YITho/Iw6P71oEaGyHbO94bGoGtzWfLGqFhMIg8= +github.com/VictoriaMetrics/metricsql v0.36.1 h1:pT1OAt7AFiNEj8rmXCqtggkA7XGQJNi4vafaw7JcVD4= +github.com/VictoriaMetrics/metricsql v0.36.1/go.mod h1:6pP1ZeLVJHqJrHlF6Ij3gmpQIznSsgktEcZgsAWYel0= github.com/VividCortex/ewma v1.1.1/go.mod h1:2Tkkvm3sRDVXaiyucHiACn4cqf7DpdyLvmxzcbUokwA= github.com/VividCortex/ewma v1.2.0 h1:f58SaIzcDXrSy3kWaHNvuJgJ3Nmz59Zji6XoJR/q1ow= github.com/VividCortex/ewma v1.2.0/go.mod h1:nz4BbCtbLyFDeC9SUHbtcT5644juEuWfUAUnGx7j5l4= @@ -963,7 +962,6 @@ github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyC github.com/valyala/fasthttp v1.30.0/go.mod h1:2rsYD01CKFrjjsvFxx75KlEUNpWNBY9JWD3K/7o2Cus= github.com/valyala/fastjson v1.6.3 h1:tAKFnnwmeMGPbwJ7IwxcTPCNr3uIzoIj3/Fh90ra4xc= github.com/valyala/fastjson v1.6.3/go.mod h1:CLCAqky6SMuOcxStkYQvblddUtoRxhYMGLrsQns1aXY= -github.com/valyala/fastrand v1.0.0/go.mod h1:HWqCzkrkg6QXT8V2EXWvXCoow7vLwOFN002oeRzjapQ= github.com/valyala/fastrand v1.1.0 h1:f+5HkLW4rsgzdNoleUOB69hyT9IlD2ZQh9GyDMfb5G8= github.com/valyala/fastrand v1.1.0/go.mod h1:HWqCzkrkg6QXT8V2EXWvXCoow7vLwOFN002oeRzjapQ= github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= @@ -971,7 +969,6 @@ github.com/valyala/fasttemplate v1.2.1 h1:TVEnxayobAdVkhQfrfes2IzOB6o+z4roRkPF52 github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= github.com/valyala/gozstd v1.15.1 h1:hpmJYWOpNs0rjDOMdbwWZplfNlfh1tOy0v7XiR9+iGQ= github.com/valyala/gozstd v1.15.1/go.mod h1:y5Ew47GLlP37EkTB+B4s7r6A5rdaeB7ftbl9zoYiIPQ= -github.com/valyala/histogram v1.1.2/go.mod h1:CZAr6gK9dbD7hYx2s8WSPh0p5x5wETjC+2b3PJVtEdg= github.com/valyala/histogram v1.2.0 h1:wyYGAZZt3CpwUiIb9AU/Zbllg1llXyrtApRS815OLoQ= github.com/valyala/histogram v1.2.0/go.mod h1:Hb4kBwb4UxsaNbbbh+RRz8ZR6pdodR57tzWUS3BUzXY= github.com/valyala/quicktemplate v1.7.0 h1:LUPTJmlVcb46OOUY3IeD9DojFpAVbsG+5WFTcjMJzCM= diff --git a/vendor/github.com/VictoriaMetrics/metricsql/rollup.go b/vendor/github.com/VictoriaMetrics/metricsql/rollup.go index 9782d4c80..c121f9dc5 100644 --- a/vendor/github.com/VictoriaMetrics/metricsql/rollup.go +++ b/vendor/github.com/VictoriaMetrics/metricsql/rollup.go @@ -5,69 +5,70 @@ import ( ) var rollupFuncs = map[string]bool{ - "absent_over_time": true, - "aggr_over_time": true, - "ascent_over_time": true, - "avg_over_time": true, - "changes": true, - "changes_prometheus": true, - "count_eq_over_time": true, - "count_gt_over_time": true, - "count_le_over_time": true, - "count_ne_over_time": true, - "count_over_time": true, - "decreases_over_time": true, - "default_rollup": true, - "delta": true, - "delta_prometheus": true, - "deriv": true, - "deriv_fast": true, - "descent_over_time": true, - "distinct_over_time": true, - "duration_over_time": true, - "first_over_time": true, - "geomean_over_time": true, - "histogram_over_time": true, - "hoeffding_bound_lower": true, - "hoeffding_bound_upper": true, - "holt_winters": true, - "idelta": true, - "ideriv": true, - "increase": true, - "increase_prometheus": true, - "increase_pure": true, - "increases_over_time": true, - "integrate": true, - "irate": true, - "lag": true, - "last_over_time": true, - "lifetime": true, - "max_over_time": true, - "min_over_time": true, - "mode_over_time": true, - "predict_linear": true, - "present_over_time": true, - "quantile_over_time": true, - "quantiles_over_time": true, - "range_over_time": true, - "rate": true, - "rate_over_sum": true, - "resets": true, - "rollup": true, - "rollup_candlestick": true, - "rollup_delta": true, - "rollup_deriv": true, - "rollup_increase": true, - "rollup_rate": true, - "rollup_scrape_interval": true, - "scrape_interval": true, - "share_gt_over_time": true, - "share_le_over_time": true, - "stddev_over_time": true, - "stdvar_over_time": true, - "sum_over_time": true, - "sum2_over_time": true, - "tfirst_over_time": true, + "absent_over_time": true, + "aggr_over_time": true, + "ascent_over_time": true, + "avg_over_time": true, + "changes": true, + "changes_prometheus": true, + "count_eq_over_time": true, + "count_gt_over_time": true, + "count_le_over_time": true, + "count_ne_over_time": true, + "count_over_time": true, + "decreases_over_time": true, + "default_rollup": true, + "delta": true, + "delta_prometheus": true, + "deriv": true, + "deriv_fast": true, + "descent_over_time": true, + "distinct_over_time": true, + "duration_over_time": true, + "first_over_time": true, + "geomean_over_time": true, + "histogram_over_time": true, + "hoeffding_bound_lower": true, + "hoeffding_bound_upper": true, + "holt_winters": true, + "idelta": true, + "ideriv": true, + "increase": true, + "increase_prometheus": true, + "increase_pure": true, + "increases_over_time": true, + "integrate": true, + "irate": true, + "lag": true, + "last_over_time": true, + "lifetime": true, + "max_over_time": true, + "min_over_time": true, + "mode_over_time": true, + "predict_linear": true, + "present_over_time": true, + "quantile_over_time": true, + "quantiles_over_time": true, + "range_over_time": true, + "rate": true, + "rate_over_sum": true, + "resets": true, + "rollup": true, + "rollup_candlestick": true, + "rollup_delta": true, + "rollup_deriv": true, + "rollup_increase": true, + "rollup_rate": true, + "rollup_scrape_interval": true, + "scrape_interval": true, + "share_gt_over_time": true, + "share_le_over_time": true, + "stale_samples_over_time": true, + "stddev_over_time": true, + "stdvar_over_time": true, + "sum_over_time": true, + "sum2_over_time": true, + "tfirst_over_time": true, // `timestamp` function must return timestamp for the last datapoint on the current window // in order to properly handle offset and timestamps unaligned to the current step. // See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/415 for details. diff --git a/vendor/modules.txt b/vendor/modules.txt index 034ed1118..8510f5c2f 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -26,7 +26,7 @@ github.com/VictoriaMetrics/fasthttp/stackless # github.com/VictoriaMetrics/metrics v1.18.1 ## explicit; go 1.12 github.com/VictoriaMetrics/metrics -# github.com/VictoriaMetrics/metricsql v0.35.0 +# github.com/VictoriaMetrics/metricsql v0.36.1 ## explicit; go 1.13 github.com/VictoriaMetrics/metricsql github.com/VictoriaMetrics/metricsql/binaryop