Skip to content

Persist provisioning progress so UI can show activation stage during in-flight provisioning #3472

Description

@nbmaiti

Summary

During device activation, stage updates are sent in real time but are not reliably persisted for UI consumption while provisioning is still in progress. If the UI refreshes or reconnects mid-activation, users can lose visibility into the current provisioning stage.

Problem

The activation pipeline emits progress labels (for example, stage-by-stage status), but those labels are transient unless the final status is written. This causes a gap where the UI cannot consistently display the latest in-progress stage for already-registered devices.

User Impact

  • Users may see stale or missing progress after page reload/reconnect.
  • Support/debug workflows become harder because in-flight stage context is lost.
  • Provisioning appears “stuck” even when progress is advancing.

Expected Behavior

  • The latest provisioning progress label should be persisted while activation is in progress.
  • Persisted progress should be included in device status payloads consumed by UI.
  • Progress should be cleared once activation reaches a terminal state (success or failure), so stale stage text is not shown afterward.

Proposed Fix

  • Add a transient provisioning progress field to the device/client runtime model.
  • Update this field when progress events are emitted.
  • Persist progress to MPS during in-progress updates for devices already registered in MPS.
  • Include the progress field in persisted device info payloads.
  • Reset/clear progress on terminal completion paths.

Acceptance Criteria

  • UI can recover and display the latest provisioning stage after refresh during activation.
  • Persisted device info contains the latest in-progress stage label when activation is active.
  • Progress label is cleared after terminal activation result.
  • Existing structured component status remains unchanged and backward compatible.
  • Unit tests cover persistence and payload propagation of provisioning progress.

Notes

This issue tracks persistence of in-progress provisioning stage for better UI continuity and observability, without changing final activation semantics.

Metadata

Metadata

Assignees

Labels

user-experienceImprovements focused on usability, workflows, accessibility, and the overall user experience.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions