Commit graph

5920 commits

Author SHA1 Message Date
Aliaksandr Valialkin
73d56fd5a4
deployment: update Go builder from Go1.21.3 to Go1.21.4
See https://github.com/golang/go/issues?q=milestone%3AGo1.21.4+label%3ACherryPickApproved
2023-11-13 18:31:33 +01:00
Aliaksandr Valialkin
44db8c9f46
lib/regexutil: properly handle alternate regexps surrounded by .+ or .*
Previously the following regexps were improperly handled:

  .+foo|bar.+
  .*foo|bar.*

This could lead to unexpected regexp match results.

See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5297

Thanks to @Haleygo for the initial attempt to fix the issue at https://github.com/VictoriaMetrics/VictoriaMetrics/pull/5308
2023-11-13 18:29:00 +01:00
Aliaksandr Valialkin
f5ef2283c3
go.mod: increase the minimum supported Go version from Go1.19 to Go1.20 2023-11-02 21:30:46 +01:00
Aliaksandr Valialkin
511d1e5847
vendor: run make vendor-update 2023-11-02 21:18:17 +01:00
Aliaksandr Valialkin
e42af059a1
lib/persistentqueue: use the proper function call after 31945fb38d 2023-11-02 21:18:00 +01:00
Aliaksandr Valialkin
dc8bc5d6cd
go.mod: pin the latest working version of golang.org/x/exp and github.com/VictoriaMetrics/metricsql 2023-11-02 21:14:19 +01:00
Aliaksandr Valialkin
31945fb38d
lib/persistentqueue: properly re-create flock.lock file inside directory if persistent queue is broken.
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5249

Thanks to @Sniper91 for the bugreport and initial fix at https://github.com/VictoriaMetrics/VictoriaMetrics/pull/5233
2023-10-31 18:37:18 +01:00
Aliaksandr Valialkin
ed76b92c7d
lib/storage: follow-up for 29cebd82fb
Use atomic.CompareAndSwapUint32() instead of atomic.LoadUint32() followed by atomic.StoreUint32().
This makes the code more clear.

Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5159
2023-10-31 16:30:30 +01:00
Roman Khavronenko
bae069553e
lib/storage: log warning about RO mode only on state change (#5191)
Before, vmstorage would log the same message each second producing excessive
amount of logs.

See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5159

Signed-off-by: hagen1778 <roman@victoriametrics.com>
2023-10-31 16:30:24 +01:00
Aliaksandr Valialkin
3284c9af81
docs/CHANGELOG.md: cut v1.87.10 2023-10-16 22:23:01 +02:00
Aliaksandr Valialkin
e8d40d589d
deployment/docker: update Go builder from Go1.21.1 to Go1.21.3
See https://github.com/golang/go/issues?q=milestone%3AGo1.21.2+label%3ACherryPickApproved
and https://github.com/golang/go/issues?q=milestone%3AGo1.21.3+label%3ACherryPickApproved
2023-10-15 18:57:36 +02:00
Aliaksandr Valialkin
ec37347fff
docs/CHANGELOG.md: remove duplicate line after 14471496fe 2023-10-02 22:17:04 +02:00
Aliaksandr Valialkin
a70753d7f9
deployment/docker: update Alpine from 3.18.3 to 3.18.4
See https://alpinelinux.org/posts/Alpine-3.18.4-released.html
2023-10-02 22:14:38 +02:00
Dmytro Kozlov
f1fcb8f6ae
app/vmagent: fix check of the DataDog agent path requests when requests have trailing slashes (#5106)
* app/vmagent: fix check of the DataDog agent path requests when requests have trailing slashes

* app/vmagent: fix CHANGELOG.md description

* wip

* wip

---------

Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2023-10-02 21:22:27 +02:00
Aliaksandr Valialkin
14471496fe
app/vmagent: follow-up for cfef814750
- Properly handle /insert/multitenant/api/put url for opentsdb handler at vmagent
- Document that the bug has been introduced in v1.93.2 at docs/CHANGELOG.md
- Add a link to multitenant url docs in bugfix description

Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5061
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4910
2023-10-01 21:07:51 +02:00
Alexander Marshalov
f9ca2d8fb3
fixed ingestion via multitenant url for opentsdbhttp (#5061) (#5063) 2023-10-01 21:07:45 +02:00
hagen1778
e3e9b17f6e
build(deps): revert version change for codecov/codecov-action from 4 to 3
https://github.com/codecov/codecov-action/issues/1089
Signed-off-by: hagen1778 <roman@victoriametrics.com>
2023-09-19 10:36:11 +02:00
Aliaksandr Valialkin
7616152360
docs/CHANGELOG.md: clarify the description of bugfixes at f7dda12b4d and b6ad581b45
This is a follow-up for 8b01bc4a5c

Updates https://github.com/VictoriaMetrics/VictoriaMetrics/pull/4999
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/pull/5009
2023-09-19 00:49:05 +02:00
Nikolay
5b9f6604e3
docs: reflect recent changes at change logs (#5015) 2023-09-19 00:34:15 +02:00
dependabot[bot]
e1186257c7
build(deps): bump codecov/codecov-action from 3 to 4 (#5011)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 3 to 4.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v3...v4)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-19 00:31:10 +02:00
faceair
b38654e0d1
lib/storage: remove ForceMergeAllParts internal loop (#4999)
Signed-off-by: faceair <git@faceair.me>
2023-09-18 16:37:50 +02:00
Aliaksandr Valialkin
624b508c3a
docs/CHANGELOG.md: cut v1.87.9 2023-09-10 20:39:54 +02:00
Aliaksandr Valialkin
1559d00abe
docs/CHANGELOG.md: fix the release where the issue has been introduced 2023-09-09 06:14:40 +02:00
Roman Khavronenko
8a1b93a49d
vmalert: correctly add duplicated params to the query (#4955)
Fix the bug when Group's `params` fields with multiple values were
overriding each other instead of adding up.
The bug was introduced in this commit eccecdf177
 starting from v1.91.1 https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.91.1

 https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4908

Signed-off-by: hagen1778 <roman@victoriametrics.com>
(cherry picked from commit 6351d07da8)
2023-09-08 09:37:27 +02:00
Aliaksandr Valialkin
30dc75352a
app/vmselect: return 503 status code when partial responses are denied and some of vmstorage nodes are temporarily unavailable
This should help detecting this case and automatic retrying the query at healthy cluster replica
in another availability zone.

This commit is needed as a preparation for automatic query retry at another backend at vmauth on 5xx errors
as described at https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4792#issuecomment-1674338561
2023-09-07 16:18:02 +02:00
Aliaksandr Valialkin
086843ec42
.github/workflows: remove nightly build, since it isnt used, while wastes compute resources (CPU and storage space) 2023-09-07 11:42:13 +02:00
Aliaksandr Valialkin
4f5e76bc4c
all: update Go builder from Go1.21.0 to Go1.21.1
See https://github.com/golang/go/issues?q=milestone%3AGo1.21.1+label%3ACherryPickApproved
2023-09-07 11:40:55 +02:00
Aliaksandr Valialkin
6c3f235c4c
docs/CHANGELOG.md: clarify the scope of recent bugfixes 2023-09-07 11:28:42 +02:00
Aliaksandr Valialkin
04afae2aa8
deployment/docker: properly build armv5 production builds for GOARCH=arm
Pass GOARM=5 when building GOARCH=arm production builds, since the default value for this env var
has been changed to GOARM=6 since Go1.21.0.

See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4965
and https://github.com/golang/go/issues/62475
2023-09-07 11:28:36 +02:00
Aliaksandr Valialkin
5f8de2945b
docs/CHANGELOG.md: document the bugfix at 7db72dd7e6
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4947
2023-09-06 12:13:25 +02:00
Nikolay
23f0cc4a9b
lib/vmselectapi: do not send empty label names for labelNames request (#4936)
* lib/vmselectapi: do not send empty label names for labelNames request
it breaks cluster communication, since vmselect incorrectly reads request buffer, leaving unread data on it
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4932

* typo fix

* wip

---------

Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2023-09-01 23:29:37 +02:00
Aliaksandr Valialkin
d487ff4ec5
docs/CHANGELOG.md: move the bugfix description for 1f66d5624d to proper place 2023-09-01 18:06:23 +02:00
Nikolay
1f66d5624d
app/vminsert: properly close vmstorage connection (#4935)
* app/vminsert: properly close vmstorage connection
previously vmstorage may stuck in broken state until vminsert restarts
since vmstorage was marked as read-only and connection was broken to it.
checkReadonly function never marked connection as broken
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4870

* wip

---------

Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2023-09-01 18:04:59 +02:00
Aliaksandr Valialkin
17febd84ac
docs/CHANGELOG.md: cut v1.87.8 2023-09-01 12:07:26 +02:00
Aliaksandr Valialkin
03728301e9
vendor: return back the working github.com/VictoriaMetrics/metricsql release after 4a338d32ce 2023-09-01 11:28:54 +02:00
Aliaksandr Valialkin
e2f6e351b3
lib/proxy: consistently use gopkg.in/yaml.v2 across all the code 2023-09-01 11:26:19 +02:00
Aliaksandr Valialkin
4a338d32ce
vendor: run make vendor-update 2023-09-01 11:26:09 +02:00
Aliaksandr Valialkin
5be882cba1
Makefile: cleanup bin/ directory at the beginning of make publish-release command
This is needed in order to prevent from non-build artifacts to be uploaded to Github release page
2023-09-01 11:24:18 +02:00
Nikolay
8b636350f2
app/vminsert: fixes readonly check (#4892)
* app/vminsert: fixes readonly check
previously vminsert doesn't check readOnly state for vmstorage, since check was never performed for nil buffer
In this case every 30 second storage node loss readonly state and received some data.
It caused re-routing and possible slow down for ingestion
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4870

* wip

---------

Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2023-08-30 16:28:08 +02:00
Aliaksandr Valialkin
9d2fbc99ff
lib/auth: add NewTokenPossibleMultitenant() for parsing auth token, which can be multitenant
Disallow parsing multitenant token at auth.NewToken().

Use auth.NewTokenPossibleMultitenant() at vminsert only. All the other callers should call auth.NewToken(),
since they do not support multitenant token.

This is a follow-up for f0c06b428e

Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4910
2023-08-30 15:25:45 +02:00
Zakhar Bessarab
df856aec6f
app/vmselect: fix panic when using /select/multitenant endpoint (#4912)
app/vmselect: fix panic when using `/select/multitenant` endpoint

Such requests must be rejected as not found since vmselect does not support multitenant endpoint.

See: https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4910

Signed-off-by: Zakhar Bessarab <z.bessarab@victoriametrics.com>
2023-08-30 15:25:36 +02:00
Nikolay
d3ebce2c2f
deployment/docker: disable provenance in buildx (#4911)
* deployment/docker: disable provenance in buildx
it must fix an issue with multi-platform manifest generation
at buildx >= 0.10 backward compatibility was broken and generated image cannot be used with docker systems that doesn't support oci.
disabling attestat temporary fixes it.
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4907
https://docs.docker.com/build/attestations/slsa-provenance/

* Update docs/CHANGELOG.md

---------

Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2023-08-30 15:22:52 +02:00
Dmytro Kozlov
a3df6e8a36
lib/protoparser: handle unexpected EOF error when parsing lines in prometheus exposition format (#4851)
Previously only io.EOF was handled, and io.ErrUnexpectedEOF was ignored, but it may happen if the client interrupts the connection.

https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4817
2023-08-28 09:40:18 +02:00
Aliaksandr Valialkin
f7f77307c6
lib/envflag: do not allow unsupported form for boolean command-line flags in the form -boolFlag value
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4845
2023-08-17 14:16:53 +02:00
Aliaksandr Valialkin
b2854d145d
lib/promrelabel: properly replace : char with _ in metric names when -usePromCompatibleNaming command-line flag is set
This addresses https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3113#issuecomment-1275077071 comment from @johnseekins
2023-08-17 13:54:50 +02:00
Roman Khavronenko
08737f11e3
vmbackup: correctly check if specified -dst belongs to specified -storageDataPath (#4841)
See this issue https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4837

Signed-off-by: hagen1778 <roman@victoriametrics.com>
2023-08-17 13:54:09 +02:00
Aliaksandr Valialkin
ab077ab41f
deployment/docker/Makefile: do not overwrite latest tag when pushing Docker images for LTS release
The `latest` tag is reserved for the latest release
2023-08-12 14:38:54 -07:00
Aliaksandr Valialkin
2c5b260b42
docs/CHANGELOG.md: cut v1.87.7 2023-08-12 13:52:12 -07:00
Nikolay
9c0119a194
lib/promscrape: adds validation for proxy_url scheme (#4823)
* lib/promscrape: adds validation for proxy_url scheme
adds tests
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4811

* Update lib/proxy/proxy.go

* Update lib/proxy/proxy.go

---------

Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2023-08-12 13:50:27 -07:00
Aliaksandr Valialkin
9c3f87fac2
lib/promscrape: use local scrape timestamp for scraped metrics unless honor_timestamps: true is set explicitly
This fixes the case with gaps for metrics collected from cadvisor,
which exports invalid timestamps, which break staleness detection at VictoriaMetrics side.

See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4697 ,
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4697#issuecomment-1654614799
and https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4697#issuecomment-1656540535

Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1773
2023-08-12 13:47:51 -07:00