Preserve Proxmox guest state on first paint

Keep canonical REST resource projection and owner-snapshot workload mapping aligned with realtime Proxmox backup and runtime evidence. This prevents the overview from showing transient missing backups and uptime before websocket hydration.\n\nRefs #1792
This commit is contained in:
pulse-triage[bot] 2026-08-29 09:24:55 +01:00
parent ea3f6388f3
commit bf3d11729b
9 changed files with 114 additions and 15 deletions

View file

@ -1350,6 +1350,16 @@ still remove an authoritatively deleted guest. These rules preserve sort,
selection, drawer, and virtualized viewport state without adding another
resource scan, websocket subscription, or browser-local source of truth.
### Proxmox owner snapshots remain complete on first paint
The scoped Proxmox owner reuses the canonical resource snapshot and performs
only constant-time field projection per workload row. That snapshot carries
top-level uptime and the intact source-authored Proxmox facet, so the first
successful REST paint can render runtime and backup evidence without showing
an interim unknown or never-backed-up state while waiting for a WebSocket
tick. This correction adds no request, subscription, retry, or resource scan;
`useUnifiedResources.test.ts` and `useWorkloads.test.ts` pin the boundary.
### Command-session liveness lookup stays bounded and in-memory
The connections ledger's command-channel liveness check

View file

@ -2389,6 +2389,16 @@ legacy `/proxmox/backups?view=...` query form remains compatibility input only;
new links and tab state must use the path segment, preserve shared scope
filters, and clear incompatible per-view facets when crossing sections.
### Overview backup evidence is authoritative on first paint
The canonical REST-to-resource-to-workload boundary preserves Proxmox
`lastBackup` and `backupInProgress` evidence before the overview renders. A
missing value may be presented as never backed up only after that authoritative
facet is loaded; the UI must not require a later WebSocket merge to replace a
transport-induced absence. Preserving this read-only evidence adds no backup,
restore, retention, or recovery authority. The behavior is pinned by
`useUnifiedResources.test.ts` and `useWorkloads.test.ts`.
### Retained Patrol objectives do not create recovery authority
The shared `internal/api` retained-objective endpoints may scope an outcome to

View file

@ -2035,6 +2035,17 @@ served clones. Proof: `TestClonedResourcesPreservePlatformAdmission` and
## Current State
### Canonical REST facets preserve realtime workload evidence
The frontend REST projection retains the complete source-authored Proxmox
facet, including runtime status, uptime, last backup, backup-in-progress, and
guest metadata, while applying only the canonical identity and metric
normalizations. It also preserves the provider-neutral `virtualMachine` facet.
Platform owners may therefore adapt the first REST snapshot into workload rows
without waiting for a later WebSocket merge; REST and WebSocket delivery must
not disagree about already-authoritative fields. The boundary is pinned by
`useUnifiedResources.test.ts` and `useWorkloads.test.ts`.
### Agent libvirt domains use a provider-neutral VM facet
The registry projects a host's validated libvirt domains as `vm` resources