Merge ~vtapia/maas:lp1927941 into maas:master
Proposed by
Victor Tapia
Status: | Merged |
---|---|
Approved by: | Alberto Donato |
Approved revision: | 14b3bd07af70f85328fdf587d14dea640a49a64f |
Merge reported by: | MAAS Lander |
Merged at revision: | not available |
Proposed branch: | ~vtapia/maas:lp1927941 |
Merge into: | maas:master |
Diff against target: |
36 lines (+12/-7) 1 file modified
src/maasserver/prometheus/stats.py (+12/-7) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
MAAS Lander | Needs Fixing | ||
Alberto Donato | Approve | ||
Review via email: mp+403523@code.staging.launchpad.net |
Commit message
Reuse metric structures for Prometheus
Description of the change
After enabling Prometheus metrics, regiond was creating a new set of metrics + CollectorRegistry with every query. Those structures were never released, turning into a memory leak. This patch reuses the same metric structures which keep updating with every query.
To post a comment you must log in.
There was an error fetching revisions from git servers. Please try again in a few minutes. If the problem persists, contact Launchpad support.
UNIT TESTS
-b lp1927941 lp:~vtapia/maas/+git/maas into -b master lp:~maas-committers/maas
STATUS: SUCCESS 0beebebe2d0245f 85c0987dd9
COMMIT: 0036ade43349553