Skip to content

Final: live fleet monitoring + Azure Monitor (App Insights)#108

Merged
CarsonL15 merged 1 commit into
mainfrom
final-live-monitoring
Jun 11, 2026
Merged

Final: live fleet monitoring + Azure Monitor (App Insights)#108
CarsonL15 merged 1 commit into
mainfrom
final-live-monitoring

Conversation

@CarsonL15

Copy link
Copy Markdown
Contributor

Summary

A significant feature update to the Admin & Maintenance App for the final, adding two more Azure services to the solution and a real-time operations view.

1. Live fleet monitoring (real-time)

  • The Bots page now auto-refreshes every 5s and merges the simulator's live runtime telemetry (power level, status) into the registry view, matched by botId.
  • A "🟢 Live" indicator with last-updated time + a Pause/Resume control; polling pauses during edits/deletes so it never disrupts the operator.
  • Per-bot telemetry shows live power % + status, and flags "no signal"/"offline" when a bot has no live data or the simulator is unreachable.

2. Azure Monitor / Application Insights (new service)

  • IaC (Iac/admin-webapp) provisions a dedicated Log Analytics workspace + Application Insights for the admin app.
  • The SPA is instrumented with the App Insights web SDK: page views + custom events for every admin action (BotCreated, BotRecharged, BotServicingToggled, BotUpdated, BotDeleted).
  • The connection string (a client ingestion key, not a secret) is fetched at build time from the IaC-provisioned resource via az and baked in — no data-plane RBAC / role assignment needed, so it's fully self-service.

Passwordless / IaC / Actions

  • App Insights connection via client ingestion key; no secrets, no new role assignments.
  • Provisioned by the consolidated iac.yml (PR = plan, merge = apply).
  • Built + deployed via AdminWebpage-Deploy-WF.yml (OIDC).

Tests

  • 26 unit tests pass (added telemetry-merge + App Insights config tests); build clean. App Insights SDK lazy-loads only when configured.

Notes for reviewers

  • On merge, iac.yml creates the App Insights resource; the admin deploy then fetches its connection string. If the deploy races ahead of the apply on first merge, telemetry turns on at the next deploy (graceful no-op until then).

Relates to #18. Final feature (Option 1).

@CarsonL15 CarsonL15 requested a review from a team June 11, 2026 07:53

@philspokas philspokas left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@CarsonL15 CarsonL15 merged commit 4c947e5 into main Jun 11, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants