Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resharding #14053

Closed
wants to merge 7,116 commits into from
Closed

Conversation

kushalShukla-web
Copy link
Contributor

No description provided.

charleskorn and others added 30 commits March 6, 2024 14:54
Signed-off-by: Charles Korn <charles.korn@grafana.com>
When a limit is specified, the API may return arbitrary rows, so don't
check specific response values.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
This is what we use for builds, so do the main testing (with -race) under that flag.

Drop non-stringlabels tests from current Go version; previous Go version still runs them.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
…ues if it's supported by the linter

clean up common-lint target

Signed-off-by: machine424 <ayoubmrini424@gmail.com>
Signed-off-by: Arthur Silva Sens <arthur.sens@coralogix.com>
* tsdb: zero out Labels and memSeries pointers in pool

So that the garbage-collector doesn't see this memory as still in use.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>

---------

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
Signed-off-by: Björn Rabenstein <github@rabenste.in>
Co-authored-by: Björn Rabenstein <github@rabenste.in>
Signed-off-by: thirdkeyword <fliterdashen@gmail.com>
add a common-lint-fix make target to make golangci-lint fix found iss…
Commit 4199f18c3e92.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
chore(ci): Run all tests on the oldest golang version
…bels

CI: run main tests with --tags=stringlabels
It takes around 20 minutes and has never told us anything interesting.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
Bump client_golang to 1.19, common to 0.49.1
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
This is a bit tough to explain, but I'll try:

`rate` & friends have a sophisticated extrapolation algorithm.
Usually, we extrapolate the result to the total interval specified in
the range selector. However, if the first sample within the range is
too far away from the beginning of the interval, or if the last sample
within the range is too far away from the end of the interval, we
assume the series has just started half a sampling interval before the
first sample or after the last sample, respectively, and shorten the
extrapolation interval correspondingly. We calculate the sampling
interval by looking at the average time between samples within the
range, and we define "too far away" as "more than 110% of that
sampling interval".

However, if this algorithm leads to an extrapolated starting value
that is negative, we limit the start of the extrapolation interval to
the point where the extrapolated starting value is zero.

At least that was the intention.

What we actually implemented is the following: If extrapolating all
the way to the beginning of the total interval would lead to an
extrapolated negative value, we would only extrapolate to the zero
point as above, even if the algorithm above would have selected a
starting point that is just half a sampling interval before the first
sample and that starting point would not have an extrapolated negative
value. In other word: What was meant as a _limitation_ of the
extrapolation interval yielded a _longer_ extrapolation interval in
this case.

There is an exception to the case just described: If the increase of
the extrapolation interval is more than 110% of the sampling interval,
we suddenly drop back to only extrapolate to half a sampling interval.

This behavior can be nicely seen in the testcounter_zero_cutoff test,
where the rate goes up all the way to 0.7 and then jumps back to 0.6.

This commit changes the behavior to what was (presumably) intended
from the beginning: The extension of the extrapolation interval is
only limited if actually needed to prevent extrapolation to negative
values, but the "limitation" never leads to _more_ extrapolation
anymore.

The difference is subtle, and probably it never bothered anyone.
However, if you calculate a rate of a classic histograms, the old
behavior might create non-monotonic histograms as a result (because of
the jumps you can see nicely in the old version of the
testcounter_zero_cutoff test). With this fix, that doesn't happen
anymore.

Signed-off-by: beorn7 <beorn@grafana.com>
CI: split Go tests into two parts, to run in parallel
Simply make update-all-go-deps

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
Otherwise we get a compilation error.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
It triggers a failure in TestOpenstackSDInstanceRefresh.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
promql: Fix limiting of extrapolation to negative values
…tograms

Add native histograms to latency/duration metrics
Also clarify why these variables are being cleared.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
Avoids possible false sharing between loops.

Plausibly there is no problem in the current code, but it's easy enough to write it more safely.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
Previous code set it at minimum 1%, which was not intended.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
The purpose of running with a previous Go version is to spot usage of
new language features; we don't need to intensively look for bugs.

Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
[BUGFIX] Scraping: Tolerance should be max 1% of interval
bboreham and others added 29 commits April 10, 2024 11:08
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
golangci-lint: enable usestdlibvars linter
[DOCS] Fix unavailable link to Kubernetes docs
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
Thanos can create and destroy TSDBs dynamically, and once a TSDB
disappears its files are deleted. Calculating the size of the
WAL then fails with errors like:

```
msg: "Failed to calculate size of "wal" dir", "err": "lstat
/tsdbdir/wal: no such file or directory", "caller": "wlog.go:271"
```

Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
…rometheus#13916)

includes Inf and NaN as numbers to histogram

---------

Signed-off-by: Neeraj Gartia <neerajgartia211002@gmail.com>
Signed-off-by: Björn Rabenstein <github@rabenste.in>
Co-authored-by: Björn Rabenstein <github@rabenste.in>
…gram-template

histograms: support expansion of native histogram values in templating
In a previous PR, the generated parser was created using an old version of goyacc.

Also adds -l to disable line directives, which fixes debug processing and reduces diffs at the expense of making it more difficult to reason about the generated output.

Signed-off-by: Owen Williams <owen.williams@grafana.com>
List Prometheus v3 coordinators in MAINTAINERS.md
This commit adds 2 new metadata labels for the endpointslice role:
* `__meta_kubernetes_endpointslice_endpoint_node_name`
* `__meta_kubernetes_endpointslice_endpoint_zone`

The latter is only present when the `discovery.k8s.io/v1` API group is
available.

I also updated the configuration doc and added an entry for the
`__meta_kubernetes_endpointslice_endpoint_hostname` label which was
missing.

Signed-off-by: Simon Pasquier <spasquie@redhat.com>
Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
…ules/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5-5.6.0

build(deps): bump github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5 from 5.5.0 to 5.6.0
…ules/documentation/examples/remote_storage/github.com/prometheus/prometheus-0.51.1

build(deps): bump github.com/prometheus/prometheus from 0.50.1 to 0.51.1 in /documentation/examples/remote_storage
…_actions/actions/checkout-4.1.2

build(deps): bump actions/checkout from 4.1.1 to 4.1.2
…_actions/actions/cache-4.0.2

build(deps): bump actions/cache from 4.0.1 to 4.0.2
…_actions/actions/setup-node-4.0.2

build(deps): bump actions/setup-node from 4.0.1 to 4.0.2
Bumps [github.com/prometheus/common](https://github.com/prometheus/common) from 0.50.0 to 0.53.0.
- [Release notes](https://github.com/prometheus/common/releases)
- [Commits](prometheus/common@v0.50.0...v0.53.0)

---
updated-dependencies:
- dependency-name: github.com/prometheus/common
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
…ules/documentation/examples/remote_storage/github.com/prometheus/common-0.53.0

build(deps): bump github.com/prometheus/common from 0.50.0 to 0.53.0 in /documentation/examples/remote_storage
Signed-off-by: Arthur Silva Sens <arthur.sens@coralogix.com>
Since it requires go 1.22

Signed-off-by: Arthur Silva Sens <arthur.sens@coralogix.com>
Signed-off-by: Arthur Silva Sens <arthur.sens@coralogix.com>
…egister

tsdb/wlog: unregister metrics on WL close
…lices-metadata

discovery(k8s): add metadata labels to endpointslices
…_actions/bufbuild/buf-breaking-action-1.1.4

build(deps): bump bufbuild/buf-breaking-action from 1.1.2 to 1.1.4
…_actions/bufbuild/buf-lint-action-1.1.1

build(deps): bump bufbuild/buf-lint-action from 1.1.0 to 1.1.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet