Commit graph

4703 commits

Author SHA1 Message Date
Aliaksandr Valialkin
840f4e3383
lib/promscrape/discovery: missing changes after b4ad3a3b4c 2023-01-27 15:10:44 -08:00
Aliaksandr Valialkin
6681a64080
docs/CHANGELOG.md: make the description for the bugfix from 465a285324 more reader-friendly 2023-01-27 15:07:15 -08:00
Nikolay
59a570f5b9
lib/storage: properly release parts inMerge lock (#3711)
if storage doesn't have enough disk space, finalDedupWatcher holds inMerge lock for all parts and never release it until storage restart
2023-01-27 15:07:14 -08:00
Roman Khavronenko
b36cc8c7e9
discover/ec2: follow-up after e2b4ab8384 (#3703)
Signed-off-by: hagen1778 <roman@victoriametrics.com>

Signed-off-by: hagen1778 <roman@victoriametrics.com>
2023-01-27 15:02:54 -08:00
Roman Khavronenko
8020461821
discover/ec2: bump API version (#3702)
Switch to the actual API version `2016-11-15`,
since the old version doesn't provide access to all
the fields which implementation expects.
For example, old API missing `zone_id` field
in `DescribeAvailabilityZonesResponse` response.

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

Signed-off-by: hagen1778 <roman@victoriametrics.com>

Signed-off-by: hagen1778 <roman@victoriametrics.com>
2023-01-27 15:02:52 -08:00
Aliaksandr Valialkin
80974621b5
lib/promscrape: follow-up for 8537533beb
- Add a comment describing the purpose of the `role` field inside `apiConfig` struct
- Revert changes at lib/promscrape/discovery/dockerswarm/dockerswarm.go ,
  since they reduce code readability. E.g. the reader needs to look up the named string constants
  in order to get their values.
2023-01-27 14:56:38 -08:00
Zakhar Bessarab
0b2f6d0d89
lib/promscrape/discovery/dockerswarm: fix discovery filters being applied to all objects (#3632)
* lib/promscrape/discovery/dockerswarm: fix discovery filters being applied to all objects

Signed-off-by: Zakhar Bessarab <z.bessarab@victoriametrics.com>

* Update docs/CHANGELOG.md

Signed-off-by: Zakhar Bessarab <z.bessarab@victoriametrics.com>
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2023-01-27 14:56:37 -08:00
Aliaksandr Valialkin
fc28543e30
docs/CHANGELOG.md: update the description of the change at 20f28eb9d6 2023-01-27 14:52:53 -08:00
Nikolay
f3ae7328a4
/lib/promscrape: use correct err logger for scrape unmarshalling (#3645)
/lib/promscrape: use correct err logger for scrape unmarshalling
It correctly suppresses scrape errors and adds correct context for err msg
2023-01-27 14:52:51 -08:00
Aliaksandr Valialkin
9e686ce316
vendor: update github.com/VictoriaMetrics/metricsql from v0.51.1 to v0.51.2
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3664
2023-01-27 14:33:07 -08:00
Aliaksandr Valialkin
0463b130eb
docs/CHANGELOG.md: add a note that the 1.79.7 is LTS release 2023-01-10 21:19:58 -08:00
Aliaksandr Valialkin
e83f94e15a
docs/CHANGELOG.md: cut v1.79.7 2023-01-10 20:06:34 -08:00
Aliaksandr Valialkin
b4022c7648
deployment/docker: update Go builder from v1.19.4 to v1.19.5
See https://github.com/golang/go/issues?q=milestone%3AGo1.19.5+label%3ACherryPickApproved
2023-01-10 20:04:52 -08:00
Aliaksandr Valialkin
52b380e0bf
deployment/docker: update Alpine base image from v3.17.0 to v3.17.1
See https://alpinelinux.org/posts/Alpine-3.17.1-released.html
2023-01-10 20:03:52 -08:00
Aliaksandr Valialkin
34780981ff
vendor: make vendor-update 2023-01-10 19:57:44 -08:00
Luke Palmer
2ec4dc709b
Lint and errcheck using golangci-lint (#3558) 2023-01-10 19:54:01 -08:00
Aliaksandr Valialkin
6a8042d89d
vendor: update github.com/valyala/fastjson/fastfloat from v1.6.3 to v1.6.4
This should properly parse floating-point numbers with missing integer or fractional parts.
For example, 123. or .123

Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3544
2023-01-10 19:48:33 -08:00
Aliaksandr Valialkin
97bbb07e87
vendor: update github.com/VictoriaMetrics/metricsql from v0.50.0 to v0.51.0
Updates https://github.com/VictoriaMetrics/metricsql/pull/7
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3589
2023-01-10 19:46:16 -08:00
Zakhar Bessarab
5af891ed92
lib/promscrape/discovery/dockerswarm: fix query encoding of filters (#3586)
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2023-01-10 19:41:18 -08:00
Aliaksandr Valialkin
a211067f06
lib/flagutil/bytes.go: properly handle values bigger than 2GiB on 32-bit architectures
This fixes handling of values bigger than 2GiB for the following command-line flags:

- -storage.minFreeDiskSpaceBytes
- -remoteWrite.maxDiskUsagePerURL
2023-01-10 19:36:23 -08:00
Aliaksandr Valialkin
f137825078
Makefile: update golangci-lint version from v1.46.2 to v1.50.1 2022-12-20 13:12:05 -08:00
Aliaksandr Valialkin
fe1406c839
docs/CHANGELOG.md: consistently use YYYY-MM-DD format for release dates
The previously used DD-MM-YYYY format could be confused with the MM-DD-YYYY format.
The YYYY-MM-DD format reduces this confusion.
2022-12-20 12:51:01 -08:00
Aliaksandr Valialkin
c448652bab
docs/CHANGELOG.md: document the change at 547f07463b29c09c62c9af35eac9cee6764b3286
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2612
2022-12-20 12:46:22 -08:00
Aliaksandr Valialkin
f4fcf3b572
lib/protoparser/datadog: do not re-use previously parsed field values if they are missing in the currently parsed message
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3432
2022-12-20 12:41:19 -08:00
Aliaksandr Valialkin
d7d34515c5
deployment/docker: do not publish lts releases with the latest tag at DockerHub
This should prevent from overwriting the real `latest` images published
from the latest releases of VictoriaMetrics
2022-12-20 12:34:03 -08:00
Aliaksandr Valialkin
715444c034
docs/CHANGELOG.md: add a note to v1.79.6 that the v1.79.x is a line of LTS releases 2022-12-11 01:50:23 -08:00
Aliaksandr Valialkin
df9f71a7a5
docs/CHANGELOG.md: cut v1.79.6 2022-12-11 00:34:25 -08:00
Aliaksandr Valialkin
35d7f321a5
vendor: make vendor-update 2022-12-11 00:27:33 -08:00
Aliaksandr Valialkin
a88bcdee24
all: update Go builder from v1.19.3 to v1.19.4
See https://github.com/golang/go/issues?q=milestone%3AGo1.19.4+label%3ACherryPickApproved
2022-12-11 00:23:32 -08:00
Aliaksandr Valialkin
f287388ff3
docs/CHANGELOG.md: document the bugfix at 05b42601c3
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3247
2022-12-10 21:34:45 -08:00
Zakhar Bessarab
e0ba243a22
lib/promscrape/discovery/azure: remove API server from URL returned by azure (#3403)
* lib/promscrape/discovery/azure: remove API server from URL returned by azure

* lib/promscrape/discovery/azure: validate nextLink contains same URL as apiServer
2022-12-10 21:34:43 -08:00
Aliaksandr Valialkin
597901086f
docs/CHANGELOG.md: consistently add - prefix in front of command-line flags
This is a follow-up for bcba5d2a78
2022-12-10 21:27:03 -08:00
Roman Khavronenko
b1c6117a51
vmalert: fix replay step param (#3428)
The recent change in modifying default value
of `datasource.queryStep` flag resulted in situation
where replay mode was always running queries with
step=`datasource.queryStep`. When it should always
use rule's evaluation interval.

The fix is related not to replay mode only, but
for all Range requests. Now step param is set
individually for each mode.

Signed-off-by: hagen1778 <roman@victoriametrics.com>

Signed-off-by: hagen1778 <roman@victoriametrics.com>
2022-12-10 21:27:01 -08:00
Roman Khavronenko
8df45575b5
vmalert: correctly return error for RW failures (#3452)
* vmalert: correctly return error for RW failures

By mistake, in 0989649ad0 the error
for remote write failures weren't return to user.
This change fixes it.

Signed-off-by: hagen1778 <roman@victoriametrics.com>
2022-12-10 21:22:33 -08:00
Aliaksandr Valialkin
aa31cc85f5
app/vmselect/promql: properly return an empty result from limit_offset() if offset exceeds the number of inner time series
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3312
2022-12-10 21:17:54 -08:00
Aliaksandr Valialkin
4df78e8814
lib/promscrape/discovery/gce: do not pass filter arg when discovering zones
The filter arg isn't supported by zones API in GCE.

See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3202
2022-12-10 21:14:42 -08:00
Aliaksandr Valialkin
45c2651678
docs/CHANGELOG.md: added missing note about LTS release for v1.79.5 2022-11-11 02:07:06 +02:00
Aliaksandr Valialkin
33c6471c18
go.mod: increase the minimum supported Go version from 1.17 to 1.19 2022-11-10 14:03:36 +02:00
Aliaksandr Valialkin
873acec0db
vendor: make vendor-update 2022-11-10 13:56:04 +02:00
Aliaksandr Valialkin
8f2b8ce786
docs/CHANGELOG.md: cut v1.79.5 2022-11-10 13:56:02 +02:00
Dmytro Kozlov
9c8e4bd989
vmui: fix vmui vulnerability (#3336)
* vmui: fix vmui vulnerability

* vmui: code cleanup
2022-11-10 13:35:35 +02:00
dependabot[bot]
f4bf0c49ec
build(deps): bump loader-utils in /app/vmui/packages/vmui (#3328)
Bumps [loader-utils](https://github.com/webpack/loader-utils) from 2.0.2 to 2.0.3.
- [Release notes](https://github.com/webpack/loader-utils/releases)
- [Changelog](https://github.com/webpack/loader-utils/blob/v2.0.3/CHANGELOG.md)
- [Commits](https://github.com/webpack/loader-utils/compare/v2.0.2...v2.0.3)

---
updated-dependencies:
- dependency-name: loader-utils
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-09 16:50:28 +02:00
Aliaksandr Valialkin
9b5cc24c91
lib/protoparser/opentsdb: follow-up after 04b0e4e7bf
- Simplify the parser code to be less error prone
- Document the change
- Add a test for OpenTSDB put line with trailing whitespace without tags

Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3290
2022-11-09 16:46:03 +02:00
Roman Khavronenko
4b0e361f1e
protoparser/opentsdb: allow lines without tags (#3303)
According to http://opentsdb.net/docs/build/html/api_telnet/put.html
"At least one tag pair must be present".
However, in VictoriaMetrics datamodel tags aren't required.
This could be confusing for users. Allowing accept lines without
tags seems to do no harm.

https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3290
Signed-off-by: hagen1778 <roman@victoriametrics.com>

Signed-off-by: hagen1778 <roman@victoriametrics.com>
2022-11-09 16:46:01 +02:00
Aliaksandr Valialkin
fe6868cb8e
lib/storage: follow-up for 790768f20b
- Document the bugfix at docs/CHANGELOG.md
- Simplify the bugfix a bit
2022-11-07 14:52:37 +02:00
Aliaksandr Valialkin
4eec43bf26
app/vmselect/promql: follow-up for 930f1ee153
Document the change at docs/CHANGELOG.md
Apply it to histogram_quantile() in the same way as to histogram_share()

Updates https://github.com/VictoriaMetrics/VictoriaMetrics/pull/3225
2022-11-07 14:46:00 +02:00
Siqi Liu
b8284e7ccb
BUGFIX: properly calculate histogram_quantile with the same value and different string le (#3225)
Co-authored-by: 647(siki.liu) <siki.liu@huolala.cn>
2022-11-07 14:45:58 +02:00
Aliaksandr Valialkin
df8ec22662
app/vmalert/templates: properly escape all the special chars in quotesEscape function
Previously the `quotesEscape` function was escaping only double quotes.
This wasn't enough, since the input string could contain other special chars,
which must be escaped when put inside JSON string. For example, carriage return and line feed chars (\n\r),
backslash char, etc. This led to the following issues, which were improperly fixed:

- https://github.com/VictoriaMetrics/VictoriaMetrics/issues/890 - this issue
  was "fixed" by introducing the `crlfEscape` function, which led to unnecessary
  complications in user templates, while not fixing various corner cases
  such as backslash chars in the input string.
  See 1de15ad490

- https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3139 - this issue
  was "fixed" by urlencoding the whole string passed to -external.alert.source
  command-line flag. This led to invalid urls, which couldn't be parsed by Grafana.
  See 00c838353d
  and 4bd0244599

This commit properly encodes the input string passed to `quotesEscape`, so it can be safely embedded inside JSON strings.

This commit deprecates crlfEscape template function and adds the following new template functions:

- strvalue and stripDomain - these functions are supported by Prometheus, so they were added
  for compatibility purposes.
- jsonEscape and htmlEscape for converting the input string to valid quoted JSON string
  and for html-escaping the input string, so it could be safely embedded as a plaintext
  into html.

This commit also documents all supported template functions at https://docs.victoriametrics.com/vmalert.html#template-functions
The deprecated crlfEscape function isn't documented on purpose, since its usefulness is negative in general case.
2022-11-07 14:41:44 +02:00
Roman Khavronenko
7bc80b73d3
vmalert: lower severity level for RW retries (#3237)
The message about dropped data still remains at `error` level.
The change supposed to make log message more clear about how
serious it is.

Signed-off-by: hagen1778 <roman@victoriametrics.com>

Signed-off-by: hagen1778 <roman@victoriametrics.com>
2022-11-07 14:33:44 +02:00
Aliaksandr Valialkin
0d6e30f3dc
app/vmselect/promql: expose missing metric vm_cache_size_max_bytes{type="promql/rollupResult"} 2022-11-07 14:29:45 +02:00