Merge pull request #1136 from chakflying/fix/prometheus-on-delete

Fix: Remove prometheus metrics on delete [Test needed]
This commit is contained in:
Louis Lam 2022-03-27 11:05:50 +08:00 committed by GitHub
commit be88351eb3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 19 additions and 0 deletions

View file

@ -579,6 +579,9 @@ exports.entryPage = "dashboard";
throw new Error("Permission denied.");
}
// Reset Prometheus labels
monitorList[monitor.id]?.prometheus()?.remove();
bean.name = monitor.name;
bean.type = monitor.type;
bean.url = monitor.url;