Pulse/internal/models
rcourtman e2a036ce2e fix(unifiedresources): carry real poll timestamps for storage and docker container sightings
resourceFromStorage and resourceFromDockerContainer stamped LastSeen with
time.Now() at conversion because their source models carried no poll
timestamp. The registry rebuilds from the retained state snapshot every
cycle, so those resources re-reported a fresh sighting each rebuild even
after their upstream source (PVE instance, docker host agent) stopped
delivering, and their per-source SourceStatus could never go stale via
markStaleLocked. 53faa4e46 fixed this fabrication at the ingest layer but
left these two adapter-level stamps.

- models.Storage gains LastSeen (omitzero), stamped where entries are
  built: the PVE storage poll (poll start time, including synthesized
  cluster-shared entries; preserved entries for unpolled nodes keep their
  old stamp), the PBS datastore conversion (PBS instance sighting), Ceph
  pool projection (cluster LastUpdated), and the mock generator (offline
  mock nodes get a backdated stamp so the stale path renders).
- resourceFromStorage passes storage.LastSeen through; zero stays zero
  ("never seen") instead of becoming conversion time.
- resourceFromDockerContainer uses host.LastSeen: containers are delivered
  wholesale with each host report, so the host report timestamp is the
  container sighting. This matches every other docker sub-resource adapter
  (services, tasks, volumes, networks, images already use host.LastSeen).
- ingestStorage routes PBS-poller datastore entries (instance "pbs-<name>",
  type pbs) to SourcePBS, parented to the PBS instance. Keying them
  SourceProxmox would judge their freshness against the 60s Proxmox stale
  threshold while PBS polls every 60s by default, flapping healthy
  datastores stale between polls; SourcePBS carries the cadence-matched
  120s threshold. PVE-reported pbs-typed storage.cfg backends stay
  SourceProxmox. Side effect: syncUnifiedStorageMetrics no longer skips
  PBS datastore storage, so those entries gain usage history.
- storageFromReadStateView round-trips LastSeen so the legacy storage API
  reports the honest sighting; mock refresh re-stamps available storage on
  each simulated poll.

The parent host/node staleness was already honest, so platform pages
reflected outages at the parent level; this makes the per-resource source
freshness honest too.
2026-06-11 10:57:22 +01:00
..
account_roles.go fix(hosted): enforce tenant org membership during handoff 2026-03-26 23:14:54 +00:00
ceph_cluster_identity.go Reconcile Ceph pool alert identity 2026-05-28 14:42:43 +01:00
ceph_pool_storage_test.go Reconcile Ceph pool alert identity 2026-05-28 14:42:43 +01:00
concurrency_test.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
converters.go Prepare v6.0.0 release candidate 2026-06-04 14:07:14 +01:00
converters_additional_test.go Prepare v6.0.0 release candidate 2026-06-04 14:07:14 +01:00
converters_test.go Keep live resource metrics fresh 2026-06-01 08:59:56 +01:00
deepcopy.go Remove 198 unreachable Go functions 2026-06-03 12:29:37 +01:00
deepcopy_test.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
disk_summary.go Restore linked host-agent disk inventory for guest VMs 2026-04-22 09:22:46 +01:00
disk_summary_test.go Restore linked host-agent disk inventory for guest VMs 2026-04-22 09:22:46 +01:00
metrics_types.go Route physical disk drawer IO through canonical history 2026-04-01 23:33:43 +01:00
metrics_types_test.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
models.go fix(unifiedresources): carry real poll timestamps for storage and docker container sightings 2026-06-11 10:57:22 +01:00
models_frontend.go Prepare v6.0.0 release candidate 2026-06-04 14:07:14 +01:00
models_frontend_test.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
models_helpers_test.go Fix PBS backup identity matching 2026-06-03 11:43:20 +01:00
node_aliases_test.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
organization.go Fail closed on ambiguous email principal resolution 2026-05-05 09:26:10 +01:00
organization_additional_test.go Fail closed on ambiguous email principal resolution 2026-05-05 09:26:10 +01:00
profile_validation.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
profile_validation_additional_test.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
profile_validation_test.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
profiles.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
snapshot_provider.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
state_additional_test.go Reconcile Ceph pool alert identity 2026-05-28 14:42:43 +01:00
state_docker_test.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
state_host_test.go Fix PBS backup identity matching 2026-06-03 11:43:20 +01:00
state_snapshot.go Prepare v6.0.0 release candidate 2026-06-04 14:07:14 +01:00
state_snapshot_additional_test.go Stabilize RC release backend race proofs 2026-04-11 23:18:44 +01:00
state_snapshot_concurrency_test.go feat: Pulse v6 release 2026-03-18 16:06:30 +00:00
state_snapshot_frontend_test.go Prepare v6.0.0 release candidate 2026-06-04 14:07:14 +01:00
state_snapshot_merge_test.go Merge linked host disks into guest overviews 2026-04-30 14:37:43 +01:00