Yury Molodov
514e3660e2
fix: prevent graph hiding without data ( #2456 )
...
* fix: prevent graph hiding without data
* fix: add yaxis labels default
* app/vmselect: `make vmui-update`
* docs/CHANGELOG.md: document the change
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-04-16 17:15:31 +03:00
Aliaksandr Valialkin
ef66b048c9
app/vmui: further improvements for number display on graphs
...
This is a follow-up for c4d2cd8336
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2409
2022-04-12 16:01:27 +03:00
Aliaksandr Valialkin
7f83dc06c4
app/vmselect: make vmui-update
2022-04-12 14:35:19 +03:00
Aliaksandr Valialkin
61c7f6beae
app/vmselect/promql: allow calling InitRollupResultCache+StopRollupResultCache multiple times during tests
...
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2406
2022-04-11 12:34:43 +03:00
Aliaksandr Valialkin
19ecc4b2c3
app/vmselect: make vmui-update
2022-04-01 12:55:21 +03:00
Yury Molodov
f166f80f15
vmui: grid support for predefined panels ( #2386 )
...
* update packages
* feat: add setting width for predefined panels
* docs: update doc by predefined dashboards
* app/vmselect: `make vmui-update`
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-04-01 12:48:17 +03:00
Yury Molodov
c8d29ed78e
vmui: predefined panels ( #2243 )
...
* feat: add basic components for predefined dashboards
* fix: change display alert
* feat: add autosize and unit for axes
* feat: add component for CircularProgress
* feat: change layout for predefined dashboards
* feat: add override step for predefined panels
* feat: add override step for predefined panels
* feat: change yaxis limits for predefined panels
* fix: rename flag for hide legend
* feat: add formatted panel description
* feat: add README.md for dashboard setup
* feat: validate dashboard settings
* feat: add unit for y-ticks
* fix: correct display error for dashboards
* fix: disable auto refresh after route change
* update package-lock.json
* fix: add basename for BrowserRouter
* fix: add dynamic basename for routing
* update packages
* feat: add a pre-defined dashboard "per-job resource usage"
* feat: display unit in the hover-tooltip
* fix: change routing and home layout
* fix: change axis width calc
* updated packages
* app/vmselect: `make vmui-update`
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-03-26 13:03:11 +02:00
Aliaksandr Valialkin
6e364e19ef
app/vmselect: add fine-grained limits for the number of returned/scanned time series for various APIs
2022-03-26 11:29:49 +02:00
Aliaksandr Valialkin
e78f3ac8ac
app/vmselect/bufferedwriter: suppress trivial network errors, which can be generated by remote side
...
These errors include `broken pipe` and `reset by peer`.
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2334
2022-03-18 19:28:02 +02:00
Aliaksandr Valialkin
5d9b9b88b9
app/vmselect/vmui: make vmui-update
2022-03-18 13:18:26 +02:00
Yury Molodov
227d5182af
vmui: update packages ( #2264 )
...
* update package.json
* update package-lock.json
* app/vmselect: `make vmui-update`
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-03-03 18:49:13 +02:00
Aliaksandr Valialkin
0d47c23a03
app/vmselect/promql: reduce the maximum number of label values, which can be propagated from one side of the binary operation to another side of the binary operation from 10K to 1K
...
There are user reports that 10K unique values in a single label filter may lead to performance and memory usage issues
2022-02-24 04:05:18 +02:00
Aliaksandr Valialkin
62b46007c5
lib/workingsetcache: reduce the default cache rotation period from hour to 20 minutes
...
This should reduce memory usage under high time series churn rate
2022-02-23 13:41:45 +02:00
Aliaksandr Valialkin
205d34eae6
app/vmselect: make vmui-update
2022-02-22 21:02:37 +02:00
Yury Molodov
5808774e06
vmui: change logic autocomplete ( #2196 )
...
* fix: change autocomplete display logic
* fix: change z-index for labels of input fields
* fix: change autocomplete display logic
* wip
* wip
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-02-21 15:43:55 +02:00
Aliaksandr Valialkin
1d7c877b7b
app/vmui: small fixes
...
* Remove unneeded dependency on `numeral` package
* Properly parse numbers obtained from /api/v1/query_range according to
https://prometheus.io/docs/prometheus/latest/querying/api/#expression-query-result-formats
* Optimize updating processing the received data from /api/v1/query_range
* Make smoother zoom on `ctrl+scroll`
* Reduce the number of points received from /api/v1/query_range by 2x in order to reduce load on backend
2022-02-14 16:25:46 +02:00
Aliaksandr Valialkin
b1f94f7f0e
app/vmselect/promql: return at most one time series from absent_over_time()
in the same way as Prometheus does
...
See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2130
2022-02-12 15:45:09 +02:00
Roman Khavronenko
e3adcbec6e
lib/promscrape: support prometheus-like duration in scrape configs ( #2169 )
...
* lib/promscrape: support prometheus-like duration in scrape configs
The change allows to specify duration values like `1d`, `1w`
for fields `scrape_interval`, `scrape_timeout`, etc.
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/817#issuecomment-1033384766
Signed-off-by: hagen1778 <roman@victoriametrics.com>
* lib/blockcache: make linter happy
Signed-off-by: hagen1778 <roman@victoriametrics.com>
* lib/promscrape: support prometheus-like duration in scrape configs
* add support for extra fields `scrape_align_interval` and `scrape_offset`;
* support Prometheus duration parsing for `__scrape_interval__`
and `__scrape_duration__` labels;
Signed-off-by: hagen1778 <roman@victoriametrics.com>
* wip
* wip
* docs/CHANGELOG.md: document the feature
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-02-11 16:17:00 +02:00
Aliaksandr Valialkin
af77f449da
app/vmselect/vmui: make vmui-update
2022-02-08 17:26:50 +02:00
Aliaksandr Valialkin
96b7de6736
app/vmselect/promql: clarify comments on why the right side of if
and and
operators are executed at first
2022-02-03 00:26:14 +02:00
Aliaksandr Valialkin
4b850c2a59
app/vmselect/promql: do not push down filters, which enumerate more than 10k unique values
...
Such filters may slow down time series search, so just skip them.
This is a follow-up for e7f1ceeb84
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1827
2022-02-02 23:40:02 +02:00
Aliaksandr Valialkin
2016a2c899
app/vmselect/promql: properly handle foo or bar
queries
...
Such queries may miss `bar` results after the commit e7f1ceeb84
because common label filters from `foo` could be mistakenly applied to `bar`.
2022-02-01 17:40:51 +02:00
Aliaksandr Valialkin
4bdd10ab90
lib/bytesutil: split Resize* funcs to MayOverallocate and NoOverallocate for more fine-grained control over memory allocations
...
Follow-up for f4989edd96
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2007
2022-02-01 00:18:42 +02:00
Aliaksandr Valialkin
a8d22e1223
app/vmselect/promql: check for binary operation in case-insensitive manner when deciding which side of the operation to perform the first
...
PromQL and MetricsQL operators are case-insensitive
2022-01-31 22:06:15 +02:00
Aliaksandr Valialkin
e7f1ceeb84
app/vmselect/promql: optimize queries, which join on _info
metrics.
...
Automatically add common filters from one side of binary operation
to the other side before sending the query to storage subsystem.
See https://grafana.com/blog/2021/08/04/how-to-use-promql-joins-for-more-effective-queries-of-prometheus-metrics-at-scale/
and https://www.robustperception.io/exposing-the-software-version-to-prometheus
2022-01-31 19:32:36 +02:00
Aliaksandr Valialkin
7edf8be3bc
app/vmselect/vmui: make vmui-update
2022-01-31 12:36:59 +02:00
Aliaksandr Valialkin
74a2297dcc
app/vmselect/vmui: make vmui-update
after e3995572bb
2022-01-25 17:51:46 +02:00
Aliaksandr Valialkin
f4989edd96
lib/bytesutil: split Resize() into ResizeNoCopy() and ResizeWithCopy() functions
...
Previously bytesutil.Resize() was copying the original byte slice contents to a newly allocated slice.
This wasted CPU cycles and memory bandwidth in some places, where the original slice contents wasn't needed
after slize resizing. Switch such places to bytesutil.ResizeNoCopy().
Rename the original bytesutil.Resize() function to bytesutil.ResizeWithCopy() for the sake of improved readability.
Additionally, allocate new slice with `make()` instead of `append()`. This guarantees that the capacity of the allocated slice
exactly matches the requested size. The `append()` could return a slice with bigger capacity as an optimization for further `append()` calls.
This could result in excess memory usage when the returned byte slice was cached (for instance, in lib/blockcache).
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2007
2022-01-25 15:24:44 +02:00
Aliaksandr Valialkin
285bb2bbec
app/vmselect/vmui: make vmui-update
2022-01-24 12:19:49 +02:00
Yury Molodov
ad5059f2d3
vmui: fixed display type switching ( #2088 )
...
* fix: correct switch display type
* docs/CHANGELOG.md: document the bugfix
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-01-21 16:56:22 +02:00
Yury Molodov
adbb821eac
vmui: fix time range selector ( #2085 )
...
* fix: add date validate for time range
* app/vmselect/vmui: `make vmui-update`
* docs/CHANGELOG.md: document the bugfix
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-01-21 12:02:38 +02:00
Aliaksandr Valialkin
d79a915583
app/vmui: fix last 6 months
time range picker
...
Previously it was incorrectly selecting 6 minutes instead of 6 months.
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1960
2022-01-18 23:28:10 +02:00
Aliaksandr Valialkin
672fcba223
app/vmui: properly calculate graph range for y axis
...
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2037
2022-01-18 22:22:24 +02:00
Aliaksandr Valialkin
5a77c86e97
app/vmui: reduce the refresh interval during graph scrolling/zooming from 1 second to 300 milliseconds
...
One second feels too laggy, so let's reduce the refresh interval to 300 milliseconds.
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2064
2022-01-18 21:48:12 +02:00
Yury Molodov
8bdc45ba00
fix: remove buffer period ( #2078 )
...
* fix: remove buffer period
* app/vmselect/vmui: `make vmui-update`
* docs/CHANGELOG.md: document the implemented feature
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2064
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-01-18 21:42:56 +02:00
Yury Molodov
70737ea4ac
vmui: correct url encoding ( #2067 )
...
* fix: correct encode multi-line queries
* fix: change autocomplete for correct arrows work
* app/vmselect/vmui: `make vmui-update`
* docs/CHANGELOG.md: document the bugfix for https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2039
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-01-18 21:31:46 +02:00
Yury Molodov
8e3f9c1fbb
vmui: correct calc axes limits ( #2058 )
...
* fix: correct calc axes limits
* app/vmselect/vmui: `make vmui-update`
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-01-18 15:43:41 +02:00
Yury Molodov
fcd33fc409
vmui: change layout ( #2054 )
...
* fix: change query reset
* feat: replace @codemirror to text field
* feat: switch to Preact from React
* fix: optimize mui imports
* feat: move time selector to Header
* checkout
* fix: remove unused vars
* update package-lock.json
* fix: correct styles
* app/vmselect/vmui: `make vmui-update`
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-01-18 12:44:22 +02:00
Aliaksandr Valialkin
dc7b63a793
app/vmselect/promql: properly keep metric names when optimized path is used for aggregate function calculations
...
For example, `sum(rate(...) keep_metric_names) by (__name__)` didn't leave the original metric name because of this issue.
This is a follup-up for 1bdc71d917
Udates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/949
2022-01-17 15:30:30 +02:00
Aliaksandr Valialkin
1bdc71d917
app/vmselect/promql: implement keep_metric_names
modifier for transform and rollup functions
...
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/949
2022-01-14 04:14:59 +02:00
Aliaksandr Valialkin
f41846d002
app/vmselect/promql: add stale_samples_over_time()
function
2022-01-14 01:48:04 +02:00
Aliaksandr Valialkin
c883c15878
app/vmselect/promql: add support for @
modifier
...
Add support for `@` modifier in MetricsQL according to https://prometheus.io/docs/prometheus/latest/querying/basics/#modifier
Extend the support with the following features:
* Allow using `@` modifier everywhere in the query. For example, `sum(foo) @ end()`
* Allow using arbitrary expression as `@` modifier. For example, `foo @ (end() - 1h)`
returns `foo` value at `end - 1 hour` timestamp on the selected time range `[start ... end]`
Updates https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1348
2022-01-13 22:12:06 +02:00
Aliaksandr Valialkin
9469696e46
app/vmselect/promql: fix limit_offset() test
...
The test has been broken in addae7fc6a
2022-01-13 16:59:28 +02:00
Yury Molodov
7d5ed49d23
vmui: switching to Preact ( #2053 )
...
* feat: replace @codemirror to text field
* feat: switch to Preact from React
* fix: optimize mui imports
* fix: remove unused vars
* update package-lock.json
* app/vmselect/vmui: `make vmui-update`
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2022-01-11 10:32:17 +02:00
Aliaksandr Valialkin
ceade70d4e
app/vmselect/vmui: run make vmui-update
after 89ff7b2465
2022-01-03 21:03:37 +02:00
Yury Molodov
681a800086
vmui: legend fixes ( #1995 )
...
* feat: add a reset query by clicking the logo
* feat: add sequence number for query fields
* feat: invert behavior on the graph's legend
* app/vmselect/vmui: `make vmui-update`
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2021-12-23 12:14:16 +02:00
Roman Khavronenko
543bd0ea0c
vmselect: update /query_exemplars placeholder ( #2000 )
...
Grafana expects `data` in response to be a slice and logs an err
if it is not:
```
err="[]v1.ExemplarQueryResult: decode slice: expect [ or n, but found , error found in #0 byte of ...||..., bigger context ...||..."
```
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1999
Signed-off-by: hagen1778 <roman@victoriametrics.com>
2021-12-23 11:53:50 +02:00
Yury Molodov
4b40acd964
vmui: add custom start range ( #1989 )
...
* feat: add custom start range
* app/vmselect/vmui: `make vmui-update`
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2021-12-21 20:19:33 +02:00
Yury Molodov
718c352946
vmui: graph fixes ( #1982 )
...
* fix: remove disabling custom step when zooming
* feat: add a dynamic calc of the width of the graph
* fix: add validate y-axis limits
* fix: correct axis limits for value 0
* fix: change logic create time series
* fix: change types for tooltip
* fix: correct points on the line
* fix: change the logic for set graph width
* fix: stop checking the period when auto-refresh is enabled
* app/vmselect/vmui: `make vmui-update`
Co-authored-by: Aliaksandr Valialkin <valyala@victoriametrics.com>
2021-12-20 17:37:02 +02:00
Aliaksandr Valialkin
6d77cc9b08
app/vmselect/vmui: make vmui-update
2021-12-20 13:51:02 +02:00