suntala
532904a1d6
Document changes to sort by label
...
Co-authored-by: Aleks Fazlieva <britishrum@users.noreply.github.com>
Signed-off-by: suntala <arati.rana@grafana.com>
3 months ago
suntala
fd2f44af7f
Fall back to comparing by label set when sorting by label desc
...
Co-authored-by: Aleks Fazlieva <britishrum@users.noreply.github.com>
Signed-off-by: suntala <arati.rana@grafana.com>
3 months ago
suntala
94ad489328
Fall back to comparing by label set when sorting by label
...
Co-authored-by: Aleks Fazlieva <britishrum@users.noreply.github.com>
Signed-off-by: suntala <arati.rana@grafana.com>
3 months ago
Arve Knudsen
5fd66ba855
Merge pull request #14510 from aknuds1/arve/add-normalize-name-tests
...
otlptranslator: Add tests for BuildCompliantName
3 months ago
machine424
82f38d3e9a
fix(tsdb/db_test.go): close the corrupted chunk after creating it to satisfy Windows FS
...
Signed-off-by: machine424 <ayoubmrini424@gmail.com>
4 months ago
Bryan Boreham
5354e87a70
Merge pull request #14644 from prometheus/prep-2.54.0
...
Cut release 2.54.0
4 months ago
Bryan Boreham
8978f3ef71
Cut release 2.54.0
...
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
4 months ago
Julien
616038f2b6
Merge pull request #14553 from prometheus/dependabot/go_modules/github.com/aws/aws-sdk-go-1.55.5
...
build(deps): bump github.com/aws/aws-sdk-go from 1.54.19 to 1.55.5
4 months ago
Julien
7b0f6f1aed
Merge pull request #14573 from prometheus/dependabot/github_actions/scripts/actions/setup-go-5.0.2
...
build(deps): bump actions/setup-go from 5.0.1 to 5.0.2 in /scripts
4 months ago
Julien
c210917b91
Merge pull request #14571 from prometheus/dependabot/github_actions/actions/upload-artifact-4.3.4
...
build(deps): bump actions/upload-artifact from 4.3.3 to 4.3.4
4 months ago
Julien
4387de8189
Merge pull request #14568 from prometheus/dependabot/github_actions/bufbuild/buf-setup-action-1.35.1
...
build(deps): bump bufbuild/buf-setup-action from 1.34.0 to 1.35.1
4 months ago
Charles Korn
f992f81bd0
Merge branch 'main' into sum-and-avg-over-mixed-custom-exponential-histograms
...
Signed-off-by: Charles Korn <charleskorn@users.noreply.github.com>
4 months ago
Charles Korn
5cfdde327c
Address PR feedback: add extra test case
...
Signed-off-by: Charles Korn <charles.korn@grafana.com>
4 months ago
Charles Korn
82bb35fabb
Address PR feedback: fix typo and rename variable
...
Signed-off-by: Charles Korn <charles.korn@grafana.com>
4 months ago
George Krajcsovits
cf62fb5c44
Merge pull request #14629 from krajorama/fix-to-encoded-chunks
...
Fix ToEncodedChunks minT for recoded chunks
4 months ago
György Krajcsovits
1ea3781699
Fix ToEncodedChunks minT for recoded chunks
...
Discovered while working on #14546 OOO native histograms.
Not triggered on main before #14546 as the code path is unused.
There was a bug where the min time of a chunk was adjusted even
if it was only recoded and not completely new.
Signed-off-by: György Krajcsovits <gyorgy.krajcsovits@grafana.com>
4 months ago
Björn Rabenstein
b5cdb4e479
Merge pull request #14628 from prometheus/beorn7/doc
...
docs: Be more explicit about `promql-experimental-functions`
4 months ago
Julien
5857888926
Merge pull request #14570 from prometheus/dependabot/github_actions/golangci/golangci-lint-action-6.1.0
...
build(deps): bump golangci/golangci-lint-action from 6.0.1 to 6.1.0
4 months ago
Julien
339889f60f
Merge pull request #14567 from prometheus/dependabot/github_actions/ossf/scorecard-action-2.4.0
...
build(deps): bump ossf/scorecard-action from 2.3.3 to 2.4.0
4 months ago
Julien
d7e4ba6cf1
Merge pull request #14566 from prometheus/dependabot/github_actions/actions/setup-go-5.0.2
...
build(deps): bump actions/setup-go from 5.0.1 to 5.0.2
4 months ago
beorn7
2360ce8d2b
docs: Be more explicit about `promql-experimental-functions`
...
We have not mentioned that experimental PromQL functions might get
removed entirely, although that's one of the most important properties
of functions declared experimental.
Signed-off-by: beorn7 <beorn@grafana.com>
4 months ago
Björn Rabenstein
41f8a0223c
Merge pull request #14609 from charleskorn/rate-over-mixed-custom-exponential-histograms
...
promql: fix "cannot reduce resolution to custom buckets schema" panic in `rate` over native histograms with mix of custom and exponential buckets
4 months ago
Manik Rana
02c465bf58
textparse: Implement `CreatedTimestamp()` in `openmetricsparse.go` ( #14356 )
...
* feat: initial implement of createedTimestamp() with tests
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* feat: return ct after finding it
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: remove unneeded test
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: add comments
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* feat: multiple changes
- implement changes from pair programming session
- use newParse.val()
- advance parser p if ct is found
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: check if err from p.Next()
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* feat: advance parser and parse histograms + summary
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: restore previous tests
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: retore failing tests
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: remove unneeded comments
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: return nil when mtype doesn't match
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: update go fmt version
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: cleanup
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: comments
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* feat: document deepcopyparser
Co-authored-by: Arthur Silva Sens <arthursens2005@gmail.com>
Signed-off-by: Manik Rana <Manikrana54@gmail.com>
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: lint
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: cover edgecase of `gauge_created` in CreatedTimestamp()
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* refac: readability updates
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* refac: dedeuplicate labeldiff checks
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* tests: add tests for new label functions
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* feat: document CreatedTimestamp func
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* refac: optimize `CreatedTimestamp()`
- Use refactored CreatedTimestamp function with bug fixes
- Remove unused code in labels.go
- Improve code documentation
Signed-off-by: Manik Rana <manikrana54@gmail.com>
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: add tests and lint fixes
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: remove mName
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: lint
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: comments
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* tests: add tests for CT parse failures and deepCopy
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* refac: edit expectCT struct
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: lint
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: add new label in deepCopy
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: use p.builder in deepCopy
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: add NewMetricsParserWithOpts
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: lint
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: comments
Co-authored-by: Arthur Silva Sens <arthursens2005@gmail.com>
Signed-off-by: Manik Rana <Manikrana54@gmail.com>
* chore: comments
Co-authored-by: Arthur Silva Sens <arthursens2005@gmail.com>
Signed-off-by: Manik Rana <Manikrana54@gmail.com>
* chore: rename var
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: add condition for OM fuzzing
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: build tags
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* refac: default skipCT to false
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* refac: rename skipCT to skipCTSeries
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: formatting
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: comments and readability updates
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: comments
Co-authored-by: Bartlomiej Plotka <bwplotka@gmail.com>
Signed-off-by: Manik Rana <Manikrana54@gmail.com>
* refac: remove NewOpenMetricsParserWithOpts
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: lint
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* refac: extract skipCTSeries logic from parseMetricSuffix
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* refac: inline create a NewOpenMetricsParser
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: comments
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: comments
Co-authored-by: Bartlomiej Plotka <bwplotka@gmail.com>
Signed-off-by: Manik Rana <Manikrana54@gmail.com>
* refac: improve error handling
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: return error instead of nil
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* fix: remove skipCT check from tBraceOpen
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* Pair programming with Manik, Arthur and Daniel.
Signed-off-by: bwplotka <bwplotka@gmail.com>
* chore: comments and use helper funcs
Signed-off-by: Manik Rana <manikrana54@gmail.com>
* chore: lint
Signed-off-by: Manik Rana <manikrana54@gmail.com>
---------
Signed-off-by: Manik Rana <manikrana54@gmail.com>
Signed-off-by: Manik Rana <Manikrana54@gmail.com>
Signed-off-by: bwplotka <bwplotka@gmail.com>
Co-authored-by: Arthur Silva Sens <arthursens2005@gmail.com>
Co-authored-by: Bartlomiej Plotka <bwplotka@gmail.com>
4 months ago
Ben Ye
b7a58dcf3d
Add hidden flag to disable overlapping compaction ( #14581 )
...
TSDB: add hidden flag to disable overlapping compaction
Signed-off-by: Ben Ye <benye@amazon.com>
---------
Signed-off-by: Ben Ye <benye@amazon.com>
4 months ago
George Krajcsovits
1d7fe4be5c
Update promql/engine.go
...
Signed-off-by: George Krajcsovits <krajorama@users.noreply.github.com>
4 months ago
György Krajcsovits
1fb0ff7e45
Add unit test
...
Signed-off-by: György Krajcsovits <gyorgy.krajcsovits@grafana.com>
4 months ago
György Krajcsovits
909785b97f
Fix histogram pool poisoning bu chunkenc.Iterator
...
chunkenc.Iterator.AtFloatHistogram may do a shallow copy if
it receives nil as input pointer. This can in turn share the
span slice with multiple histograms in the matrixSelectorHPool,
leading to unexpected errors.
Signed-off-by: György Krajcsovits <gyorgy.krajcsovits@grafana.com>
4 months ago
Filip Petkovski
8f9751b00d
Use CopyTo when resetting histogram in stats iterator
...
The histogram stats iterator does not fully clear the histogram object
and is not resilient to new fields being added to the histogram type.
To resolve the issue, the commit uses the CopyTo methods which should
be future proof to new fields being added.
Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>
4 months ago
Filip Petkovski
02d9d874a2
Add more test cases
...
Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>
4 months ago
Filip Petkovski
6100e756a8
Ignore stale histograms for counter reset detection
...
The histogram stats decoder keeps track of the last seen histogram sample
in order to properly detect counter resets. We are seeing an issue where
a histogram with UnknownResetHint gets treated as a counter reset when it follows
a stale histogram sample.
I believe that this is incorrect since stale samples should be completely ignored
in PromQL. As a result, they should not be stored in the histogram stats iterator
and the counter reset detection needs to be done against the last non-stale sample.
Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>
4 months ago
Charles Korn
f91009aa2e
promql: clarify error message when panic occurs during query evaluation
...
Signed-off-by: Charles Korn <charles.korn@grafana.com>
4 months ago
Björn Rabenstein
27579c9148
Merge pull request #14605 from krajorama/fix-staleness-pool-corrupt
...
Fix histogram pool poisoning bug chunkenc.Iterator
4 months ago
George Krajcsovits
17b0b788da
Update promql/engine.go
...
Signed-off-by: George Krajcsovits <krajorama@users.noreply.github.com>
4 months ago
Arthur Silva Sens
f74d448c69
Merge pull request #14516 from freak12techno/use-humanize-duration-from-common
...
chore: use HumanizeDuration and ConvertToFloat from prometheus/common
4 months ago
George Krajcsovits
3a673cd0bc
Merge pull request #14598 from krajorama/fix-compaction-panic
...
Fix: panic: runtime error: index out of range [4] with length 4
4 months ago
machine424
92873d3009
feat: allow to delay head compaction start time helping Prometheus instances to
...
avoid simultaneous compactions and reduce stress on shared resources.
This is enabled via `--enable-feature=delayed-compaction`.
Signed-off-by: machine424 <ayoubmrini424@gmail.com>
4 months ago
Oleg Zaytsev
0833d2a230
Fix appendable: check whether last val was a histogram ( #14613 )
...
* Fix appendable: check whether last val was a histogram
When appending a float, we were checking whether lastValue was equal to
current value, but we didn't check whether last value was a float value.
Signed-off-by: Oleg Zaytsev <mail@olegzaytsev.com>
4 months ago
Charles Korn
0f4bc87b4f
Make linter happy
...
Signed-off-by: Charles Korn <charles.korn@grafana.com>
4 months ago
Charles Korn
f07b3ae67b
Fix issue where `avg` over mixed exponential and custom buckets, or incompatible custom buckets, produces incorrect results or panics
...
Signed-off-by: Charles Korn <charles.korn@grafana.com>
4 months ago
Charles Korn
5ee94f49a2
Fix issue where `sum` over mixed exponential and custom buckets, or incompatible custom buckets, produces incorrect results
...
Signed-off-by: Charles Korn <charles.korn@grafana.com>
4 months ago
Charles Korn
424cefcf5e
Fix "cannot reduce resolution to custom buckets schema" panic in `rate` over native histograms with mix of custom and exponential buckets
...
Signed-off-by: Charles Korn <charles.korn@grafana.com>
4 months ago
Charles Korn
f6e4b775e2
Check for errors first
...
Signed-off-by: Charles Korn <charles.korn@grafana.com>
4 months ago
György Krajcsovits
b91acc61b0
Add unit test
...
Signed-off-by: György Krajcsovits <gyorgy.krajcsovits@grafana.com>
4 months ago
Björn Rabenstein
ee5bba07c0
Merge pull request #14413 from prometheus/beorn7/promql
...
promql: more Kahan summation (avg) and less incremental mean calculation (avg, avg_over_time)
4 months ago
Björn Rabenstein
71ba554293
Merge pull request #14482 from ywwg/owilliams/group-quote
...
promql: support quoting in grouping label lists
4 months ago
György Krajcsovits
37c8c9257b
Fix histogram pool poisoning bu chunkenc.Iterator
...
chunkenc.Iterator.AtFloatHistogram may do a shallow copy if
it receives nil as input pointer. This can in turn share the
span slice with multiple histograms in the matrixSelectorHPool,
leading to unexpected errors.
Signed-off-by: György Krajcsovits <gyorgy.krajcsovits@grafana.com>
4 months ago
dependabot[bot]
626f2f3571
build(deps): bump github.com/docker/docker
...
Bumps [github.com/docker/docker](https://github.com/docker/docker ) from 27.0.3+incompatible to 27.1.1+incompatible.
- [Release notes](https://github.com/docker/docker/releases )
- [Commits](https://github.com/docker/docker/compare/v27.0.3...v27.1.1 )
---
updated-dependencies:
- dependency-name: github.com/docker/docker
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
4 months ago
György Krajcsovits
98ecdf3589
Fix corrupting spans via iterator sharing
...
Iterator may share spans without copy, so we always have to make a copy
before modification - copy-on-write.
Signed-off-by: György Krajcsovits <gyorgy.krajcsovits@grafana.com>
4 months ago
dependabot[bot]
6900bf48d0
build(deps): bump github.com/aws/aws-sdk-go from 1.54.19 to 1.55.5
...
Bumps [github.com/aws/aws-sdk-go](https://github.com/aws/aws-sdk-go ) from 1.54.19 to 1.55.5.
- [Release notes](https://github.com/aws/aws-sdk-go/releases )
- [Commits](https://github.com/aws/aws-sdk-go/compare/v1.54.19...v1.55.5 )
---
updated-dependencies:
- dependency-name: github.com/aws/aws-sdk-go
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
4 months ago
Julien
4412b844d4
Merge pull request #14554 from prometheus/dependabot/go_modules/github.com/ionos-cloud/sdk-go/v6-6.2.0
...
build(deps): bump github.com/ionos-cloud/sdk-go/v6 from 6.1.11 to 6.2.0
4 months ago