mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-09-10 02:25:56 +00:00
dd5df4285c
When the same physical Ceph cluster is reported by both the Proxmox API poller and a Pulse host-agent (same FSID), v5 stored it under two pool-ID namespaces and ran alert evaluation on the raw, un-deduplicated list, producing duplicate/flapping Ceph pool alerts and a per-pool override that appeared to revert between identities. v6 closes this without the v5 'agent:'-prefix patch: both ingest paths reconcile by FSID before alert evaluation. State.UpsertCephCluster (host-agent) and State.UpdateCephClustersForInstance (Proxmox) both funnel through upsertCephClusterInSlice, which collapses same-FSID clusters into a single reconciled entry, and both call sites run checkCephPoolStorage on the STORED cluster. The per-pool override resolves across source aliases via storageThresholdLookupIDs/cephPoolStorageSourceAliasID, and clearStorageAliasAlerts removes any alias-keyed alert. This adds a regression test asserting the observable outcome for the exact dual-source scenario (host-agent + Proxmox API, same FSID, one pool at ~61% with a 50% per-pool override): exactly one active Ceph pool usage alert, override honored, no second/flapping alert across either ingest order or repeated interleaved cycles. No behavior change.