Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
119 commits
Select commit Hold shift + click to select a range
0032ce0
Render background in images to play nicely with dark mode
pr00se Feb 27, 2023
1cc28ce
chore: Fix documentation on signal to shut down instance
darxriggs Mar 18, 2023
b73040c
Fix changelog
Mar 22, 2023
8d88408
Merge pull request #12178 from roidelapluie/fixcl
Mar 23, 2023
0c75f76
fix: RLIM_INFINITY type is uint64 on loong64
znley Apr 6, 2023
79db04e
Adjust samplesPerChunk from 120 to 220
leizor Mar 3, 2023
c770ba8
Add comment linking to PR
leizor Mar 3, 2023
73ff91d
Test fixes
leizor Mar 3, 2023
d5b33e1
yamllint: don’t check keys and add file extension to config file
mmorel-35 Apr 8, 2023
0de12cb
Merge branch 'prometheus:main' into patch-1
mmorel-35 Apr 13, 2023
0529934
Add storage.tsdb.samples-per-chunk flag
leizor Apr 12, 2023
c3e6b85
Reverse test changes
leizor Apr 13, 2023
4d21ac2
Implement bucket limit for native histograms
zenador Apr 21, 2023
d3ad158
Update docs and comments
zenador Apr 21, 2023
071426f
Add unit test for bucket limit appender
krajorama Apr 21, 2023
2ad39ba
Treat bucket limit like sample limit and make it fail the whole scrap…
zenador Apr 21, 2023
dfabc69
Add tests according to code review
zenador Apr 24, 2023
276ca6a
fix some comments
cuishuang Apr 25, 2023
c06c02b
Fix recommended protoc version
tpaschalis Apr 25, 2023
417e847
Update prompb/README.md
tpaschalis Apr 25, 2023
38de61b
Propose Jesus Vazquez as 2.45 release shepherd
jesusvazquez Apr 25, 2023
0bf707e
Merge pull request #12293 from jesusvazquez/jvp/propose-jesus-vazquez…
jesusvazquez Apr 25, 2023
93f6475
Remove extra line
tpaschalis Apr 26, 2023
55626c6
Fix final newline
tpaschalis Apr 26, 2023
8a34c43
Update prompb/README.md
tpaschalis Apr 26, 2023
d4bf477
Merge pull request #12292 from tpaschalis/fix-recommended-protoc
Apr 26, 2023
28f5502
scrape: fix two loop variable scoping bugs in test
rsc Apr 26, 2023
3c3ea24
Merge pull request #12290 from cuishuang/main
Apr 27, 2023
24d7e5b
Merge pull request #12296 from rsc/loopvar
Apr 27, 2023
0d049fe
Fix encoding samples in ChunkSeries (#12185)
fpetkovski Apr 28, 2023
0ab9553
tsdb: drop deleted series from the WAL sooner (#12297)
bboreham May 1, 2023
1068be1
build(deps): bump bufbuild/buf-setup-action from 1.16.0 to 1.17.0
dependabot[bot] May 1, 2023
1cbe1d8
build(deps): bump github.com/digitalocean/godo from 1.98.0 to 1.99.0
dependabot[bot] May 1, 2023
6dfcd00
build(deps): bump github.com/hetznercloud/hcloud-go
dependabot[bot] May 1, 2023
8deface
build(deps): bump github.com/prometheus/client_golang
dependabot[bot] May 2, 2023
6985dcb
Optimize and test MemoizedSeriesIterator
leizor Apr 10, 2023
7bbf24b
Make MemoizedSeriesIterator not implement chunkenc.Iterator
leizor Apr 30, 2023
7c2de14
Merge pull request #12243 from leizor/leizor/prometheus/issues/11274
beorn7 May 3, 2023
e9b2d87
Revert change to model/textparse/protobufparse_test.go
krajorama May 4, 2023
19a4f31
Refactor testutil/protobuf.go into scrape package
krajorama May 4, 2023
40240c9
Update according to code review
zenador May 4, 2023
e278195
Cherry-pick bugfix #12322 and create v2.43.1 (#12324)
bboreham May 4, 2023
f5fcaa3
Fix setting reset header to gauge histogram in seriesToChunkEncoder (…
krajorama May 5, 2023
b1b8fd7
docs: state that remote write is stable
bboreham May 9, 2023
a96350f
Remove codesome and add jesusvazquez in CODEOWNERS for tsdb
codesome May 9, 2023
3c48026
Merge pull request #12345 from codesome/codeowners
codesome May 9, 2023
37fe9b8
Merge pull request #12055 from leizor/leizor/prometheus/issues/12009
beorn7 May 10, 2023
bd98fc8
Merge pull request #12254 from zenador/histogram-bucket-limit
beorn7 May 10, 2023
9e4e2a4
wlog: use filepath for getting checkpoint number
rfratto May 10, 2023
734baa3
Merge pull request #12344 from bboreham/rw-stable
bboreham May 10, 2023
c0f1abb
MatchNotRegexp optimization
alanprot May 10, 2023
2f35619
discovery/kubernetes: attach node labels when the endpoints TargetRef…
mickael-carl May 3, 2023
fa4f4e4
Merge pull request #12349 from rfratto/fix-wlog-path
bboreham May 11, 2023
1f1dac2
Merge pull request #12351 from alanprot/optimization/MatchNotRegexp
jesusvazquez May 11, 2023
5c5fa5c
Merge pull request #12338 from mickael-carl/mcarl/attach-node-labels
brancz May 11, 2023
9e50034
textparse/scrape: Add option to scrape both classic and native histog…
beorn7 May 10, 2023
b727e69
Merge pull request #12350 from prometheus/beorn7/histogram
beorn7 May 13, 2023
c661872
Fix HistogramAppender.Appendable array out of bound error
krajorama May 11, 2023
4c898fc
Update getting_started.md
AkshaySiwal May 15, 2023
c3f267d
Alerts: more efficient generation of target labels
bboreham Mar 22, 2023
3711339
Alerts: more efficient relabel on Send
bboreham Mar 22, 2023
0d2108a
[tsdb] re-implement WAL watcher to read via a "notification" channel …
cstyan May 15, 2023
a073e04
Merge pull request #12366 from prometheus/release-2.44
bboreham May 16, 2023
30e263c
Merge pull request #12357 from krajorama/fix-histogram-appendable-emp…
beorn7 May 16, 2023
191bf90
Handle more arithmetic operators for native histograms (#12262)
zenador May 16, 2023
41b3db1
Merge pull request #12367 from AkshaySiwal/main
May 16, 2023
1991bfb
Merge remote-tracking branch 'origin/release-2.43'
May 16, 2023
0dc31ad
Add support for consul path_prefix
May 16, 2023
65c321a
Merge pull request #12310 from prometheus/dependabot/go_modules/githu…
May 16, 2023
5eb8826
Merge pull request #12311 from prometheus/dependabot/go_modules/githu…
May 16, 2023
807c1fa
Merge pull request #12315 from prometheus/dependabot/go_modules/docum…
May 16, 2023
f26760c
build(deps): bump github.com/hetznercloud/hcloud-go
dependabot[bot] May 16, 2023
2657e3a
Merge pull request #12307 from prometheus/dependabot/github_actions/b…
May 16, 2023
9613d66
Merge pull request #12369 from roidelapluie/reb243
May 17, 2023
c66fdc1
Merge pull request #12373 from prometheus/dependabot/go_modules/githu…
May 17, 2023
80b7f73
Copy tombstone intervals to avoid race (#12245)
damnever May 17, 2023
e53478a
Merge pull request #12372 from roidelapluie/consul_path_prefix
May 18, 2023
f731a90
Fix LabelValueStats in posting stats (#12342)
codebasky May 19, 2023
92d6980
Fix populateWithDelChunkSeriesIterator and gauge histograms (#12330)
krajorama May 19, 2023
c8e7f95
ci(lint): enable predeclared linter
mmorel-35 May 21, 2023
8c5d4b4
Opmize MatchNotEqual (#12377)
alanprot May 21, 2023
905a0bd
Added 'limit' query parameter support to /api/v1/status/tsdb endpoint…
codebasky May 22, 2023
37e5249
Use DefaultSamplesPerChunk in tsdb (#12387)
zenador May 24, 2023
89af351
Remove samplesPerChunk from memSeries (#12390)
leizor May 25, 2023
cb045c0
Fix wording from "jitterSeed" -> "offsetSeed" for server-wide scrape …
juliusv May 25, 2023
ce236c6
Mark 2.45 as LTS
May 25, 2023
a308ea7
Update functions.md
marcoderama May 26, 2023
da88a98
Merge pull request #12399 from marcoderama/patch-2
May 28, 2023
6f97641
Merge pull request #12380 from mmorel-35/patch-2
May 28, 2023
4c27fa0
Update OpenTelemetry dependencies
May 28, 2023
7f29458
Merge pull request #12231 from Loongson-Cloud-Community/main
May 28, 2023
7a31662
Merge pull request #12023 from pr00se/update_images
May 28, 2023
ea36af6
Merge pull request #12393 from roidelapluie/lts-245
May 28, 2023
bbed8f8
Merge pull request #12401 from roidelapluie/update-otel
May 28, 2023
6e7ac76
fix problematic link (#12405)
cuishuang May 29, 2023
48ded7a
Merge pull request #12235 from mmorel-35/patch-1
May 29, 2023
a0e1525
Merge pull request #12171 from bboreham/notifier-builder
May 29, 2023
044e004
Update exporter-toolkit
SuperQ May 30, 2023
f7846a7
Merge pull request #12408 from prometheus/superq/exporter-toolkit
bwplotka May 30, 2023
a16b876
Add limits to global config (#12126)
vesari May 30, 2023
73078bf
Opmizing Group Regex (#12375)
alanprot May 30, 2023
1fd48bc
Merge pull request #12151 from darxriggs/fix-getting-started-shutdown
May 30, 2023
dfae954
Improving Performance on the API Gzip Handler (#12363)
alanprot May 30, 2023
a8772a4
Feat: Get block by id directly on promtool analyze & get latest block…
nidhey27 Jun 1, 2023
b1675e2
Add Azure AD package for remote write (#11944)
rakshith210 Jun 1, 2023
bfa466d
Create release candidate 2.45.0-rc.0 (#12435)
jesusvazquez Jun 7, 2023
edfc97a
Bump UI version (#12440)
jesusvazquez Jun 7, 2023
0de8555
Add support for inline TLS certificates
May 30, 2023
652fb03
Merge pull request #12412 from roidelapluie/inlinetls
Jun 17, 2023
d19fa62
Revert "Improving Performance on the API Gzip Handler (#12363)"
Jun 20, 2023
d5fb601
Merge pull request #12476 from roidelapluie/rev12363
Jun 20, 2023
c858049
Create 2.45.0-rc.1 (#12478)
jesusvazquez Jun 20, 2023
be0b82c
Fix PR typo in 2.45.0-rc.1 CHANGELOG (#12479)
jesusvazquez Jun 20, 2023
8ef767e
Release 2.45.0 (#12486)
jesusvazquez Jun 23, 2023
2edd2d7
Merge tag 'refs/tags/v2.45.0'
github-actions[bot] Jun 27, 2023
d5eb0f4
[bot] vendor: revendor
github-actions[bot] Jun 27, 2023
59b0610
[bot] assets: generate
github-actions[bot] Jun 27, 2023
22fa14f
[bot] update rh-manifest.txt
github-actions[bot] Jun 27, 2023
8db7e26
[create-pull-request] automated change
github-actions[bot] Jun 27, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
/web/ui/module @juliusv @nexucis
/storage/remote @csmarchbanks @cstyan @bwplotka @tomwilkie
/discovery/kubernetes @brancz
/tsdb @codesome
/tsdb @jesusvazquez
/promql @roidelapluie
/cmd/promtool @dgl
2 changes: 1 addition & 1 deletion .github/workflows/buf-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: bufbuild/buf-setup-action@v1.16.0
- uses: bufbuild/buf-setup-action@v1.17.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
- uses: bufbuild/buf-lint-action@v1
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/buf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: bufbuild/buf-setup-action@v1.16.0
- uses: bufbuild/buf-setup-action@v1.17.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
- uses: bufbuild/buf-lint-action@v1
Expand Down
3 changes: 2 additions & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ linters:
- gocritic
- gofumpt
- goimports
- revive
- misspell
- predeclared
- revive
- unconvert
- unused

Expand Down
3 changes: 1 addition & 2 deletions .yamllint → .yamllint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,4 @@ rules:
config/testdata/section_key_dup.bad.yml
line-length: disable
truthy:
ignore: |
.github/workflows/*.yml
check-keys: false
30 changes: 29 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,29 @@
# Changelog


## 2.45.0 / 2023-06-23

This release is a LTS (Long-Term Support) release of Prometheus and will
receive security, documentation and bugfix patches for at least 12 months.
Please read more about our LTS release cycle at
<https://prometheus.io/docs/introduction/release-cycle/>.

* [FEATURE] API: New limit parameter to limit the number of items returned by `/api/v1/status/tsdb` endpoint. #12336
* [FEATURE] Config: Add limits to global config. #12126
* [FEATURE] Consul SD: Added support for `path_prefix`. #12372
* [FEATURE] Native histograms: Add option to scrape both classic and native histograms. #12350
* [FEATURE] Native histograms: Added support for two more arithmetic operators `avg_over_time` and `sum_over_time`. #12262
* [FEATURE] Promtool: When providing the block id, only one block will be loaded and analyzed. #12031
* [FEATURE] Remote-write: New Azure ad configuration to support remote writing directly to Azure Monitor workspace. #11944
* [FEATURE] TSDB: Samples per chunk are now configurable with flag `storage.tsdb.samples-per-chunk`. By default set to its former value 120. #12055
* [ENHANCEMENT] Native histograms: bucket size can now be limited to avoid scrape fails. #12254
* [ENHANCEMENT] TSDB: Dropped series are now deleted from the WAL sooner. #12297
* [BUGFIX] Native histograms: ChunkSeries iterator now checks if a new sample can be appended to the open chunk. #12185
* [BUGFIX] Native histograms: Fix Histogram Appender `Appendable()` segfault. #12357
* [BUGFIX] Native histograms: Fix setting reset header to gauge histograms in seriesToChunkEncoder. #12329
* [BUGFIX] TSDB: Tombstone intervals are not modified after Get() call. #12245
* [BUGFIX] TSDB: Use path/filepath to set the WAL directory. #12349

## 2.44.0 / 2023-05-13

This version is built with Go tag `stringlabels`, to use the smaller data
Expand All @@ -20,6 +44,10 @@ details about this code change see #10991.
* [BUGFIX] TSDB: Block compaction failed when shutting down. #12179
* [BUGFIX] TSDB: Out-of-order chunks could be ignored if the write-behind log was deleted. #12127

## 2.43.1 / 2023-05-03

* [BUGFIX] Labels: `Set()` after `Del()` would be ignored, which broke some relabeling rules. #12322

## 2.43.0 / 2023-03-21

We are working on some performance improvements in Prometheus, which are only
Expand All @@ -33,7 +61,7 @@ the gains on their production architecture. We are providing release artefacts
improvements for testing. #10991

* [FEATURE] Promtool: Add HTTP client configuration to query commands. #11487
* [FEATURE] Scrape: Add `include_scrape_configs` to include scrape configs from different files. #12019
* [FEATURE] Scrape: Add `scrape_config_files` to include scrape configs from different files. #12019
* [FEATURE] HTTP client: Add `no_proxy` to exclude URLs from proxied requests. #12098
* [FEATURE] HTTP client: Add `proxy_from_enviroment` to read proxies from env variables. #12098
* [ENHANCEMENT] API: Add support for setting lookback delta per query via the API. #12088
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ The PromQL parser grammar is located in `promql/parser/generated_parser.y` and i
The parser is built using [goyacc](https://pkg.go.dev/golang.org/x/tools/cmd/goyacc)

If doing some sort of debugging, then it is possible to add some verbose output. After generating the parser, then you
can modify the the `./promql/parser/generated_parser.y.go` manually.
can modify the `./promql/parser/generated_parser.y.go` manually.

```golang
// As of writing this was somewhere around line 600.
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ The features that distinguish Prometheus from other metrics and monitoring syste

## Architecture overview

![Architecture overview](https://cdn.jsdelivr.net/gh/prometheus/prometheus@c34257d069c630685da35bcef084632ffd5d6209/documentation/images/architecture.svg)
![Architecture overview](documentation/images/architecture.svg)

## Install

Expand Down
3 changes: 2 additions & 1 deletion RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,8 @@ Release cadence of first pre-releases being cut is 6 weeks.
| v2.42 | 2023-01-25 | Kemal Akkoyun (GitHub: @kakkoyun) |
| v2.43 | 2023-03-08 | Julien Pivotto (GitHub: @roidelapluie) |
| v2.44 | 2023-04-19 | Bryan Boreham (GitHub: @bboreham) |
| v2.45 | 2023-05-31 | **searching for volunteer** |
| v2.45 LTS | 2023-05-31 | Jesus Vazquez (Github: @jesusvazquez) |
| v2.46 | 2023-07-12 | **searching for volunteer** |

If you are interested in volunteering please create a pull request against the [prometheus/prometheus](https://github.com/prometheus/prometheus) repository and propose yourself for the release series of your choice.

Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.44.0
2.45.0
10 changes: 8 additions & 2 deletions cmd/prometheus/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -337,6 +337,9 @@ func main() {
serverOnlyFlag(a, "storage.tsdb.head-chunks-write-queue-size", "Size of the queue through which head chunks are written to the disk to be m-mapped, 0 disables the queue completely. Experimental.").
Default("0").IntVar(&cfg.tsdb.HeadChunksWriteQueueSize)

serverOnlyFlag(a, "storage.tsdb.samples-per-chunk", "Target number of samples per chunk.").
Default("120").Hidden().IntVar(&cfg.tsdb.SamplesPerChunk)

agentOnlyFlag(a, "storage.agent.path", "Base path for metrics storage.").
Default("data-agent/").StringVar(&cfg.agentStoragePath)

Expand Down Expand Up @@ -1050,6 +1053,7 @@ func main() {

startTimeMargin := int64(2 * time.Duration(cfg.tsdb.MinBlockDuration).Seconds() * 1000)
localStorage.Set(db, startTimeMargin)
db.SetWriteNotified(remoteStorage)
close(dbOpen)
<-cancel
return nil
Expand Down Expand Up @@ -1482,11 +1486,11 @@ func (s *readyStorage) Snapshot(dir string, withHead bool) error {
}

// Stats implements the api_v1.TSDBAdminStats interface.
func (s *readyStorage) Stats(statsByLabelName string) (*tsdb.Stats, error) {
func (s *readyStorage) Stats(statsByLabelName string, limit int) (*tsdb.Stats, error) {
if x := s.get(); x != nil {
switch db := x.(type) {
case *tsdb.DB:
return db.Head().Stats(statsByLabelName), nil
return db.Head().Stats(statsByLabelName, limit), nil
case *agent.DB:
return nil, agent.ErrUnsupported
default:
Expand Down Expand Up @@ -1543,6 +1547,7 @@ type tsdbOptions struct {
NoLockfile bool
WALCompression bool
HeadChunksWriteQueueSize int
SamplesPerChunk int
StripeSize int
MinBlockDuration model.Duration
MaxBlockDuration model.Duration
Expand All @@ -1563,6 +1568,7 @@ func (opts tsdbOptions) ToTSDBOptions() tsdb.Options {
AllowOverlappingCompaction: true,
WALCompression: opts.WALCompression,
HeadChunksWriteQueueSize: opts.HeadChunksWriteQueueSize,
SamplesPerChunk: opts.SamplesPerChunk,
StripeSize: opts.StripeSize,
MinBlockDuration: int64(time.Duration(opts.MinBlockDuration) / time.Millisecond),
MaxBlockDuration: int64(time.Duration(opts.MaxBlockDuration) / time.Millisecond),
Expand Down
28 changes: 11 additions & 17 deletions cmd/promtool/tsdb.go
Original file line number Diff line number Diff line change
Expand Up @@ -398,26 +398,20 @@ func openBlock(path, blockID string) (*tsdb.DBReadOnly, tsdb.BlockReader, error)
if err != nil {
return nil, nil, err
}
blocks, err := db.Blocks()
if err != nil {
return nil, nil, err
}
var block tsdb.BlockReader
switch {
case blockID != "":
for _, b := range blocks {
if b.Meta().ULID.String() == blockID {
block = b
break
}

if blockID == "" {
blockID, err = db.LastBlockID()
if err != nil {
return nil, nil, err
}
case len(blocks) > 0:
block = blocks[len(blocks)-1]
}
if block == nil {
return nil, nil, fmt.Errorf("block %s not found", blockID)

b, err := db.Block(blockID)
if err != nil {
return nil, nil, err
}
return db, block, nil

return db, b, nil
}

func analyzeBlock(path, blockID string, limit int, runExtended bool) error {
Expand Down
Loading