]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
mgr/dashboard: fix memory leak in prometheus service
authorNizamudeen A <nia@redhat.com>
Fri, 8 Aug 2025 06:42:20 +0000 (12:12 +0530)
committerNizamudeen A <nia@redhat.com>
Tue, 19 Aug 2025 05:45:14 +0000 (11:15 +0530)
commit829627c2e43aea23551f381b0bb070d680fef03b
treebb86359f72a123c721a1e617349e45d68251e568
parent45b7da1854912a288e36cd7a8f07182fe169811c
mgr/dashboard: fix memory leak in prometheus service

Prometheus API calls in the Cluster Utilization call is subscribed in
the for loop multiple times but this is not properly unsubscribed. As we
stay in the dashboard page for longer time, it produces a significant
memory leak which eventually lags the UI. Attempting to fix it by
properly handling the subscription

Fixes: https://tracker.ceph.com/issues/72511
Signed-off-by: Nizamudeen A <nia@redhat.com>
(cherry picked from commit 26765720b972453bc69f23cd5644366bba998391)
src/pybind/mgr/dashboard/frontend/src/app/shared/api/prometheus.service.ts