vmui: fix freeze when query regular with heatmap query (#4093)

* fix: fix freeze when query regular with heatmap query

* vmui/docs: fix freeze when query regular with heatmap query
This commit is contained in:
Yury Molodov 2023-04-21 10:59:09 +02:00 committed by GitHub
parent 3140aa34de
commit 05ab34f2c8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 3 deletions

View File

@ -44,7 +44,14 @@ const CustomPanel: FC = () => {
const { queryOptions } = useFetchQueryOptions();
const {
isLoading, liveData, graphData, error, queryErrors, warning, traces, isHistogram
isLoading,
liveData,
graphData,
error,
queryErrors,
warning,
traces,
isHistogram
} = useFetchQuery({
visible: true,
customStep,
@ -97,7 +104,7 @@ const CustomPanel: FC = () => {
useEffect(() => {
graphDispatch({ type: "SET_IS_HISTOGRAM", payload: isHistogram });
}, [isHistogram]);
}, [graphData]);
return (
<div

View File

@ -137,7 +137,7 @@ export const convertPrometheusToVictoriaMetrics = (buckets: MetricResult[]): Met
};
const getUpperBound = (bucket: MetricResult) => {
const values = (bucket.metric.vmrange || bucket.metric.le).split("...");
const values = (bucket.metric.vmrange || bucket.metric.le || "").split("...");
return promValueToNumber(values[values.length - 1]);
};

View File

@ -28,6 +28,7 @@ The following tip changes can be tested by building VictoriaMetrics components f
* BUGFIX: [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html): fix a panic when the duration in the query contains uppercase `M` suffix. Such a suffix isn't allowed to use in durations, since it clashes with `a million` suffix, e.g. it isn't clear whether `rate(metric[5M])` means rate over 5 minutes, 5 months or 5 million seconds. See [this](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3589) and [this](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4120) issues.
* BUGFIX: [vmalert](https://docs.victoriametrics.com/vmalert.html): retry failed read request on the closed connection one more time. This improves rules execution reliability when connection between vmalert and datasource closes unexpectedly.
* BUGFIX: [vmui](https://docs.victoriametrics.com/#vmui): fix the display of the tenant selector. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4160).
* BUGFIX: [vmui](https://docs.victoriametrics.com/#vmui): fix issue where vmui would freeze when adding a query that returned regular rows alongside a heatmap query.
## [v1.90.0](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.90.0)