Commit graph

75 commits

Author SHA1 Message Date
Aliaksandr Valialkin
09c388a8e4
lib/promscrape: use the standard net/http.Client instead of fasthttp.Client for scraping targets in non-streaming mode
While fasthttp.Client uses less CPU and RAM when scraping targets with small responses (up to 10K metrics),
it doesn't work well when scraping targets with big responses such as kube-state-metrics.
In this case it could use big amounts of additional memory comparing to net/http.Client,
since fasthttp.Client reads the full response in memory and then tries re-using the large buffer
for further scrapes.

Additionally, fasthttp.Client-based scraping had various issues with proxying, redirects
and scrape timeouts like the following ones:

- https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1945
- https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5425
- https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2794
- https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1017

This should help reducing memory usage for the case when target returns big response
and this response is scraped by fasthttp.Client at first before switching to stream parsing mode
for subsequent scrapes. Now the switch to stream parsing mode is performed on the first scrape
after reading the response body in memory and noticing that its size exceeds the value passed
to -promscrape.minResponseSizeForStreamParse command-line flag.
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/5567

Overrides https://github.com/VictoriaMetrics/VictoriaMetrics/pull/4931
2024-01-30 18:39:55 +02:00
Aliaksandr Valialkin
32bee8b40f
vendor: run make vendor-update 2023-11-13 18:54:33 +01:00
Aliaksandr Valialkin
fb1fcbefda
vendor: run make vendor-update 2023-10-16 14:33:16 +02:00
Aliaksandr Valialkin
5cbb330555
vendor: run make vendor-update 2023-09-07 12:35:42 +02:00
Aliaksandr Valialkin
6092b98849
vendor: run make vendor-update 2023-08-11 08:38:36 -07:00
Aliaksandr Valialkin
e2a2d64053
vendor: run make vendor-update 2023-07-07 00:05:50 -07:00
Aliaksandr Valialkin
1fa5223237
vendor: make vendor-update 2023-05-09 23:16:43 -07:00
Aliaksandr Valialkin
4077b0fcb1
vendor: make vendor-update 2023-04-10 10:21:39 -07:00
Aliaksandr Valialkin
9cd0a2e875
vendor: make vendor-update 2023-03-12 03:14:09 -07:00
Aliaksandr Valialkin
94334ed0bb
vendor: make vendor-update 2023-02-18 15:37:05 -08:00
Aliaksandr Valialkin
a68bb879d4
vendor: make vendor-update 2023-02-09 14:48:38 -08:00
Aliaksandr Valialkin
3d2cae9d75
vendor: make vendor-update 2023-01-09 21:34:44 -08:00
Aliaksandr Valialkin
b472fbc737
vendor: make vendor-update 2022-12-10 21:47:18 -08:00
Aliaksandr Valialkin
b6ffdde969
vendor: make vendor-update 2022-12-05 23:28:23 -08:00
Aliaksandr Valialkin
372b449f94
vendor: make vendor-update 2022-11-10 13:47:30 +02:00
Aliaksandr Valialkin
ac09a85a8b
vendor: make vendor-update 2022-10-07 01:04:37 +03:00
Aliaksandr Valialkin
b57ca71eb2
vendor: make vendor-update 2022-10-01 17:19:01 +03:00
Aliaksandr Valialkin
1271010727
vendor: make vendor-update 2022-09-21 12:03:10 +03:00
Dmytro Kozlov
ed842e7d3a
app/{vmctl,vmalert}: update progress bar library (make vendor-update) (#3138)
* app/{vmctl,vmalert}: update progress bar library (make vendor-update)

* app/{vmctl,vmalert}: make vendor-update
2022-09-21 11:11:40 +03:00
Aliaksandr Valialkin
fea576e061
vendor: make vendor-update 2022-09-13 16:45:00 +03:00
Aliaksandr Valialkin
7ffd3ae1ff
vendor: make vendor-update 2022-09-08 18:57:19 +03:00
Aliaksandr Valialkin
40c2fae617
vendor: make vendor-update 2022-08-15 00:54:50 +03:00
Aliaksandr Valialkin
6b49958e04
vendor: make vendor-update 2022-08-07 22:38:32 +03:00
Aliaksandr Valialkin
27c4c5a530
vendor: make vendor-update 2022-07-25 10:54:54 +03:00
Aliaksandr Valialkin
032d4fdf7d
vendor: make vendor-update 2022-06-20 14:31:57 +03:00
Aliaksandr Valialkin
38342f959a
vendor: make vendor-update 2022-06-06 13:25:11 +03:00
Aliaksandr Valialkin
5924511960
vendor: make vendor-update 2022-05-25 21:52:54 +03:00
Aliaksandr Valialkin
e0bd035467
vendor: make vendor-update 2022-05-20 14:48:23 +03:00
Aliaksandr Valialkin
155cd5d6e1
vendor: make vendor-update 2022-04-26 15:27:40 +03:00
Aliaksandr Valialkin
2c7f7799eb
vendor: make vendor-update 2022-04-21 16:01:19 +03:00
Aliaksandr Valialkin
7a622a71ea
vendor: make vendor-update 2022-04-19 11:43:02 +03:00
Aliaksandr Valialkin
b9e133678f
vendor: make vendor-update 2022-04-12 12:56:50 +03:00
Aliaksandr Valialkin
a8337c7170
vendor: make vendor-update 2022-04-04 13:08:07 +03:00
Aliaksandr Valialkin
e2eaf2a681
vendor: make vendor-update 2022-03-03 18:15:12 +02:00
Aliaksandr Valialkin
dfbd4ca2ab
vendor: make vendor-update 2021-12-20 12:12:14 +02:00
Aliaksandr Valialkin
aa61a74c31
vendor: make vendor-update 2021-12-12 18:10:34 +02:00
Aliaksandr Valialkin
246417601c
vendor: make vendor-update 2021-12-02 12:38:38 +02:00
Aliaksandr Valialkin
3d20d229d0
vendor: make vendor-update 2021-11-29 12:36:56 +02:00
Aliaksandr Valialkin
ee64a88ba3
vendor: make vendor-update 2021-11-17 13:40:36 +02:00
Aliaksandr Valialkin
c6fa2eaa3b
vendor: make vendor-update 2021-11-14 14:05:11 +02:00
Aliaksandr Valialkin
d59acb06c1
vendor: make vendor-update 2021-11-08 12:41:20 +02:00
Aliaksandr Valialkin
54f3f08874
vendor: make vendor-update 2021-11-01 16:08:01 +02:00
Aliaksandr Valialkin
064abfba8c
vendor: make vendor-update 2021-10-22 19:28:27 +03:00
Aliaksandr Valialkin
c92746bb01
vendor: make vendor-update 2021-10-18 15:23:46 +03:00
Aliaksandr Valialkin
20fa4b01cb
vendor: make vendor-update 2021-10-08 16:06:31 +03:00
Aliaksandr Valialkin
bb45d747ad
vendor: make vendor-update 2021-10-05 10:31:30 +03:00
Aliaksandr Valialkin
f434fcbbd7
vendor: make vendor-update 2021-09-30 17:54:45 +03:00
Aliaksandr Valialkin
469820873f
vendor: make vendor-update 2021-09-27 18:01:46 +03:00
Aliaksandr Valialkin
3b9fd99735 vendor: make vendor-update 2021-09-20 14:44:49 +03:00
Aliaksandr Valialkin
7d910c6a51 vendor: make vendor-update 2021-09-15 18:24:08 +03:00