Skip to content

armgit / Pulse

Public Imported from GitHub
0

Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.

Keep explicit temperature clears mirrored into shadow state

pulse-triage[bot]5e9a8a6588ba
diff --git a/internal/alerts/active_cleanup.go b/internal/alerts/active_cleanup.go
index 106ade74f5..67f7ee2e44 100644
--- a/internal/alerts/active_cleanup.go
+++ b/internal/alerts/active_cleanup.go
@@ -343,7 +343,9 @@ func (m *Manager) ClearActiveAlerts() {
m.activeAlerts = make(map[string]*Alert)
m.restoredBackupNotifications = nil
m.activeAlertAlias = make(map[string]string)
- m.core.Reset()
+ for _, state := range m.mirrorStatesNoLock() {
+ state.Reset()
+ }
m.hostDiskTempPendingContexts = nil
m.intentPending = make(map[string]IntentPendingState)
m.intentRuntimeTicks = make(map[string]time.Duration)
diff --git a/internal/alerts/host_unraid_lifecycle_test.go b/internal/alerts/host_unraid_lifecycle_test.go
index c2a5d962b3..b340cb7bf1 100644
--- a/internal/alerts/host_unraid_lifecycle_test.go
+++ b/internal/alerts/host_unraid_lifecycle_test.go
@@ -1043,9 +1043,6 @@ func TestDiskTemperaturePendingContextCleanup(t *testing.T) {
for _, removal := range []bool{false, true} {
t.Run(fmt.Sprintf("removed=%v", removal), func(t *testing.T) {
m, _ := continuityManager(t, false)
- m.mu.Lock()
- m.shadow = nil
- m.mu.Unlock()
host := hostWithSMARTDiskTemp("pending-cleanup", "custom", 85)
m.CheckHost(host)
m.mu.RLock()