15811 Commits

Author SHA1 Message Date
dependabot[bot]
ce2e48f39e
build(deps): bump github.com/open-telemetry/opentelemetry-collector-contrib/processor/deltatocumulativeprocessor
Bumps [github.com/open-telemetry/opentelemetry-collector-contrib/processor/deltatocumulativeprocessor](https://github.com/open-telemetry/opentelemetry-collector-contrib) from 0.128.0 to 0.129.0.
- [Release notes](https://github.com/open-telemetry/opentelemetry-collector-contrib/releases)
- [Changelog](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/CHANGELOG-API.md)
- [Commits](https://github.com/open-telemetry/opentelemetry-collector-contrib/compare/v0.128.0...v0.129.0)

---
updated-dependencies:
- dependency-name: github.com/open-telemetry/opentelemetry-collector-contrib/processor/deltatocumulativeprocessor
  dependency-version: 0.129.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-07-03 08:10:56 +00:00
github-actions[bot]
3c25eb2a0d
Merge pull request #16815 from prometheus/dependabot/go_modules/github.com/oklog/run-1.2.0
build(deps): bump github.com/oklog/run from 1.1.0 to 1.2.0
2025-07-03 10:09:10 +02:00
Bryan Boreham
74aca682b7
Merge pull request #16807 from bboreham/test-sizeoflabels
[TESTS] Labels: Add a test for SizeOfLabels
2025-07-02 18:44:10 +01:00
wmTJc9IK0Q
c481aaf762
codemirror-promql: Preserve source files in npm package (#16804)
* Preserve source files in codemirror-promql package

This allows for sourcemaps to work when the package is imported via ESM-native CDNs such as esm.sh

Signed-off-by: wmTJc9IK0Q <171362836+wmTJc9IK0Q@users.noreply.github.com>

* Preserve source files in lezer-promql package

Signed-off-by: wmTJc9IK0Q <171362836+wmTJc9IK0Q@users.noreply.github.com>

---------

Signed-off-by: wmTJc9IK0Q <171362836+wmTJc9IK0Q@users.noreply.github.com>
2025-07-02 15:31:02 +02:00
Julien
f62d0e0385
Merge pull request #16777 from roidelapluie/add-step-promql
Add step(), min() and max() in promql duration expressions
2025-07-02 14:27:45 +02:00
Julien
432f130a32 PromQL: min/max/step: Address review comments
Signed-off-by: Julien <291750+roidelapluie@users.noreply.github.com>
2025-07-02 11:17:36 +02:00
Julien Pivotto
984c8de0da PromQL: Fix printing +min()
Signed-off-by: Julien Pivotto <291750+roidelapluie@users.noreply.github.com>
2025-07-02 11:17:17 +02:00
Julien Pivotto
3af0bdee68 PromQL: min/max/step: add more tests
Signed-off-by: Julien Pivotto <291750+roidelapluie@users.noreply.github.com>
2025-07-02 11:17:17 +02:00
Julien Pivotto
ee7d5158a7 Add step(), min(a,b) and max(a,b) in promql duration expressions
step() is a new keyword introduced to represent the query step width in duration expressions.

min(a,b) and max(a,b) return the min and max from two duration expressions.

Signed-off-by: Julien Pivotto <291750+roidelapluie@users.noreply.github.com>
2025-07-02 11:17:17 +02:00
Bryan Boreham
4eafbcae93 lint
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
2025-07-02 09:56:28 +01:00
Bryan Boreham
e7ac3f440d [TESTS] Labels: Add a test for SizeOfLabels
This requires a bit of repetition to cover all the different builds, but
it seems worth checking that the function does what is expected.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
2025-07-02 09:31:27 +01:00
Bryan Boreham
507227781b [REFACTOR] Labels: Extract test case data from TestLabels_String
So we can use them in other tests.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
2025-07-02 09:31:25 +01:00
Julius Volz
bfbae39931
Merge pull request #16716 from charleskorn/charleskorn/binops-docs
docs: clarify and expand binary operations documentation
2025-07-02 10:02:17 +02:00
dependabot[bot]
6bb7e088c5
build(deps): bump github.com/oklog/run from 1.1.0 to 1.2.0
Bumps [github.com/oklog/run](https://github.com/oklog/run) from 1.1.0 to 1.2.0.
- [Release notes](https://github.com/oklog/run/releases)
- [Commits](https://github.com/oklog/run/compare/v1.1.0...v1.2.0)

---
updated-dependencies:
- dependency-name: github.com/oklog/run
  dependency-version: 1.2.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-07-01 23:42:33 +00:00
Charles Korn
d19a9ab673
Remove other instances of "obvious"
Signed-off-by: Charles Korn <charles.korn@grafana.com>
2025-07-01 20:13:46 +10:00
Charles Korn
1977452331
Address PR feedback: adjust docs to match current behaviour
Signed-off-by: Charles Korn <charles.korn@grafana.com>
2025-07-01 20:10:20 +10:00
Charles Korn
665eb3d6cb
Address PR feedback: remove use of "obvious"
Signed-off-by: Charles Korn <charles.korn@grafana.com>
2025-07-01 20:08:18 +10:00
Charles Korn
70df21a680
Address PR feedback: format Inf and NaN as monospace
Signed-off-by: Charles Korn <charles.korn@grafana.com>
2025-07-01 20:07:07 +10:00
Charles Korn
9c6916f4f9
Address PR feedback: add blank lines before lists
Signed-off-by: Charles Korn <charles.korn@grafana.com>
2025-07-01 20:06:15 +10:00
Arve Knudsen
d902abc50d
config.ScrapeConfig.Validate: Fix MetricNameEscapingScheme error messages (#16801)
* config.ScrapeConfig.Validate: Fix MetricNameEscapingScheme error messages

---------

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2025-06-30 15:05:03 +00:00
Bartlomiej Plotka
2a88f562d1
Merge pull request #16800 from prometheus/merge-rel-2.53
Merge branch 'release-2.53' into main
2025-06-30 12:37:57 +01:00
bwplotka
f418ea651c Merge branch 'release-2.53' into merge-rel-2.53
Lot's of conflicts so I only ported CHANGELOG.md
2025-06-30 12:12:57 +01:00
Bartlomiej Plotka
d344ea7bf4
Merge pull request #16790 from prometheus/v2.53.4-deps
[RELASE 2.53] Prepare 2.53.5 + Bump deps
v2.53.5
2025-06-30 10:38:19 +01:00
Björn Rabenstein
c3276ea40c
Merge pull request #16789 from gopherorg/main
chore: fix some function names in comment
2025-06-27 23:17:45 +02:00
bwplotka
488a420b6e Upgrade golangci-lint due to timeouts for v1 version.
Signed-off-by: bwplotka <bwplotka@gmail.com>
2025-06-27 16:28:17 +01:00
bwplotka
ddb9f4c70a Update npm packages.
Signed-off-by: bwplotka <bwplotka@gmail.com>
2025-06-27 16:28:17 +01:00
bwplotka
fd4a786443 Prepare 2.53.5 release.
Signed-off-by: bwplotka <bwplotka@gmail.com>
2025-06-27 16:28:13 +01:00
Björn Rabenstein
9e73fb43b3
Merge pull request #16773 from prometheus/beorn7/promql
promql: Re-introduce direct mean calculation
2025-06-27 14:57:12 +02:00
beorn7
ce809e625f promql: Re-introduce direct mean calculation for better accuracy
This commit brings back direct mean calculation (for `avg` and
`avg_over_time`) but isn't an outright revert of #16569. It keeps the
improved incremental mean calculation and features generally a bit
cleaner code than before.

Also, this commit...

- ...updates the lengthy comment explaining the whole situation and
  trade-offs.

- ...divides the running sum and the Kahan compensation term
  separately (in direct mean calculation) to avoid the (unlikely)
  possibility that sum and Kahan compensation together ovorflow
  float64.

- ...uncomments the tests that should now work again on darwin/arm64.

- ...uncomments the test that should now reliably yield the
  (inaccurate) value 0 on all hardware platforms. Also, the test
  description has been updated accordingly.

- ...adds avg_over_time tests for zero and one sample in the range.

Signed-off-by: beorn7 <beorn@grafana.com>
2025-06-27 14:34:46 +02:00
beorn7
f71daa7977 promql: Remove falsified comment from test
The test in question actually worked fine even before #16569. The
finding reported in the comment has turned out to be caused by
something else.

Signed-off-by: beorn7 <beorn@grafana.com>
2025-06-27 14:34:46 +02:00
beorn7
2b3fc1f115 promql: Add test cases for direct mean calculation
These demonstrate that direct mean calculation has some merits after
all.

Signed-off-by: beorn7 <beorn@grafana.com>
2025-06-27 14:34:46 +02:00
Łukasz Mierzwa
748fe6d825
Limit concurrency of scrape pool reloads (#16783)
To avoid possible overload.

As per https://github.com/prometheus/prometheus/pull/16595#issuecomment-3005027067 this changes scrape pool manager to limit the number of scrape pools that can reload at the same time.

Signed-off-by: Lukasz Mierzwa <l.mierzwa@gmail.com>
2025-06-27 12:34:07 +01:00
bwplotka
e6e2f90402 [RELASE 2.53] Bump Go deps in prep for 2.53.4
Also updated Go version to 1.23 as some deps require it.

Signed-off-by: bwplotka <bwplotka@gmail.com>
2025-06-27 09:49:55 +01:00
gopherorg
b86d4ba312 chore: fix some function names in comment
Signed-off-by: gopherorg <gopherworld@icloud.com>
2025-06-27 15:34:53 +08:00
Jan-Otto Kröpke
df4f1df43f
Merge pull request #16787 from jkroepke/release-3.4-main 2025-06-27 05:28:42 +02:00
Jan-Otto Kröpke
5a1deb84cc
Merge branch 'release-3.4' into release-3.4-main
# Conflicts:
#	CHANGELOG.md
2025-06-26 22:54:24 +02:00
Jan-Otto Kröpke
b392caf256
Prepare release 3.4.2
Signed-off-by: Jan-Otto Kröpke <mail@jkroepke.de>
v0.304.2 v3.4.2
2025-06-26 22:48:39 +02:00
Arve Knudsen
9c791faade
OTLP receiver: Don't append _total suffix to non-monotonic OTel sums (#16776)
* OTLP receiver: Don't append _total suffix to non-monotonic OTel sums

Fix the OTLP receiver so the suffix _total isn't appended to metrics
converted from non-monotonic OTel sum metrics, if otlp.translation_strategy is
UnderscoreEscapingWithSuffixes or NoUTF8EscapingWithSuffixes.

Also add translation tests.

---------

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2025-06-25 18:18:45 +02:00
Owen Williams
aa1d46a9da
scrape: set validation and escaping defaults in default config vars (#16751)
Fixes https://github.com/prometheus/prometheus/issues/16750

Signed-off-by: Owen Williams <owen.williams@grafana.com>
2025-06-25 11:14:13 -04:00
George Krajcsovits
5b7ff92d95
fix(promql): histogram_quantile and histogram_fraction NaN observed in native histogram (#16724)
* fix(promql): histogram_quantile NaN observed in native histogram

Fixes: #16578

See the issue for detailed explanation.
When a histogram had only NaN observations and no normal observations,
we returned 0 from the quantile, which is completely wrong. If there were
normal observations but we went over them, we returned the upper bound of
the existing buckets, however that contradicts expectations on
histogram_fraction. Now we return NaN if the quantile is calculated to be
over all normal observations, falling into NaNs (in a virtual +Inf bucket).

We also return info level annotations if we see any NaN observations.
The annotation calls out if we returned NaN or even if we took the
virtual +Inf bucket into account.

Signed-off-by: György Krajcsovits <gyorgy.krajcsovits@grafana.com>

* fix(promql): histogram_fraction NaN observed in native histogram

Fixes: #16580

According to the specification we should not take NaN observations
into account when calculating the fraction. This commit fixes that
and adds an info level annotation to let the user know about this.

Signed-off-by: György Krajcsovits <gyorgy.krajcsovits@grafana.com>
2025-06-25 13:37:43 +02:00
Bartlomiej Plotka
eb44f9232d
Backward compatibility with upcoming index v3 (#16762)
Signed-off-by: Ganesh Vernekar <ganeshvern@gmail.com>
Co-authored-by: Ganesh Vernekar <ganeshvern@gmail.com>
2025-06-25 09:11:26 +01:00
Rishi Jat
31e158b749
Add documentation for custom_values usage in NHCB (#16757)
Signed-off-by: rishi-jat <rishijat098@gmail.com>
Signed-off-by: Rishi Jat <rishijat098@gmail.com>
Co-authored-by: George Krajcsovits <krajorama@users.noreply.github.com>
2025-06-24 21:52:55 +02:00
Bryan Boreham
a8e32147b3
[BUGFIX] Top-level: Update GOGC before loading TSDB (#16521)
We should use the configured value, or Prometheus' default of 75%, while
initializing and loading the WAL.

Since the Go default is 100%, most Prometheus users would experience
higher memory usage before the value is configured.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
2025-06-24 15:02:17 +01:00
Bryan Boreham
bdada2330c
Merge pull request #16765 from bboreham/update-go-deps
Release 3.5 preparation: Update go dependencies
2025-06-24 12:20:06 +01:00
Carrie Edwards
7289d41940
Add tests for relabeling of type and unit labels (#16743)
Signed-off-by: Carrie Edwards <edwrdscarrie@gmail.com>
2025-06-23 16:42:38 +01:00
Bryan Boreham
d6f9ba6310 [BUILD] Docker SD: Fix up deprecated types
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
2025-06-23 16:15:58 +01:00
Bryan Boreham
95d47c0512 [TESTS] Rules: remove brittle TestNewGroup
It broke on different implementation of 'NewNopLogger'.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
2025-06-23 15:34:03 +01:00
Bryan Boreham
b2e0d3f16c [BUILD] Wind back dependencies which require Go 1.24
We need Prometheus to build with the last 2 versions of Go.

Remove Go toolchain line - it is redundant with the `go`` line above,
and could mislead readers.

Also don't update `fsnotify` which is pinned to an older version.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
2025-06-23 15:33:12 +01:00
Bryan Boreham
3253ba6310 [BUILD] Wind back otlptranslator update which has breaking change
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
2025-06-23 14:27:37 +01:00
Bryan Boreham
b0b3676f35 [BUILD] Ran make update-go-deps
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
2025-06-23 14:19:40 +01:00