Pulse/internal/truenas
rcourtman 5d4f51c027 Key TrueNAS systems by configured connection, not reported hostname
Two TrueNAS systems that report the same hostname collapsed into one
flapping resource (#1573, #1575): systemSourceID keyed the system by the
snapshot-reported hostname, every child pool/dataset/app/VM/share/disk
was scoped under it, and the client minted the system's machine key from
the DMI serial with a hostname fallback, so serial-less systems sharing
a hostname (and DR clones sharing a serial) also fully merged in the
identity matcher.

The system source ID now scopes to the connection ID the poller passes
through NewLiveProviderForConnection; the hostname arm survives only for
fixture snapshots, which carry no connection. The ingest identity drops
the machine key entirely (DR clones share DMI serials, and vendor
placeholder serials collide across unrelated machines), the client no
longer falls back to the hostname for MachineID, and ingest skips
identity-pin completion for SourceTrueNAS so a stale pre-fix pin or a
same-named agent host's pin cannot lend the system a machine key and
re-merge what connection scoping keeps apart. Agent.AgentID and the
native metric history keys follow the source ID minus its system:
prefix, so BuildMetricsTarget keeps resolving one series.

Rows minted under the retired hostname-keyed derivation re-key once via
record-declared succession: records name their old canonical IDs in
IngestRecord.SupersededCanonicalIDs and IngestRecords applies the
existing ApplyCanonicalIDSuccessions semantics (operator state and
action audits re-key, the superseded pin drops, never while the old ID
still belongs to a live resource, journal rows are never rewritten).
Alert identities and persisted metric series under old child IDs are
not re-keyed: active alerts re-arm under the new IDs and TrueNAS host
charts are backed by native read-through history.
2026-07-14 11:51:55 +01:00
..
client.go Key TrueNAS systems by configured connection, not reported hostname 2026-07-14 11:51:55 +01:00
client_helpers_test.go Harden CodeQL storage and integer boundaries 2026-07-09 17:37:08 +01:00
client_test.go Fix TrueNAS unavailable SMART disk health 2026-05-28 12:53:46 +01:00
contract_test.go Key TrueNAS systems by configured connection, not reported hostname 2026-07-14 11:51:55 +01:00
disk_health.go Fix TrueNAS unavailable SMART disk health 2026-05-28 12:53:46 +01:00
fixture_records_test.go Key TrueNAS systems by configured connection, not reported hostname 2026-07-14 11:51:55 +01:00
fixtures.go Add TrueNAS services and stabilize dev startup 2026-05-21 12:08:25 +01:00
integration_test.go feat(truenas): ingest apps as canonical workloads 2026-03-29 16:04:09 +01:00
provider.go Key TrueNAS systems by configured connection, not reported hostname 2026-07-14 11:51:55 +01:00
provider_additional_test.go Scope TrueNAS resources by appliance 2026-05-21 00:59:00 +01:00
provider_concurrency_test.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
provider_health_test.go Fix TrueNAS unavailable SMART disk health 2026-05-28 12:53:46 +01:00
provider_test.go Emit TrueNAS pool status incidents 2026-06-29 22:54:19 +01:00
types.go Fix TrueNAS unavailable SMART disk health 2026-05-28 12:53:46 +01:00