Skip to content

Emit explicit telemetry when workload execution is canceled due to experiment timeout#697

Merged
nchapagain001 merged 9 commits intomainfrom
copilot/fix-experiment-timeout-telemetry
Apr 28, 2026
Merged

Emit explicit telemetry when workload execution is canceled due to experiment timeout#697
nchapagain001 merged 9 commits intomainfrom
copilot/fix-experiment-timeout-telemetry

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 24, 2026

  • Add telemetry logging in ProfileExecutor.ExecuteAsync() when the experiment times out — emits ProfileExecutor.ExperimentTimeoutReached with timeout duration and timestamp
  • Add telemetry logging in VirtualClientComponent.ExecuteAsync() when execution is cancelled — emits {TypeName}.ExecutionCancelled with executionCancelled=true
  • Address feedback: make component-level message generic (not assume timeout) and crisp (not wordy)
  • Include timeout value in ProfileExecutor-level telemetry context
  • Update unit tests to match
  • Build and run tests to verify changes

Copilot AI and others added 2 commits April 24, 2026 01:12
…imeout

Add warning-level telemetry events in two key locations:
1. ProfileExecutor.ExperimentTimeoutReached - logged when the experiment
   timeout is reached, before canceling in-progress workloads
2. {TypeName}.ExecutionCancelled - logged per-component when an
   OperationCanceledException is caught due to cancellation token

Both events include a structured 'terminationReason' field set to
'ExperimentTimeout' and a descriptive message to help users and
dashboards distinguish timeout-induced cancellations from real failures.

Agent-Logs-Url: https://github.com/microsoft/VirtualClient/sessions/ed26e102-6dfe-4c37-ab5f-c52008932555

Co-authored-by: nchapagain001 <165215502+nchapagain001@users.noreply.github.com>
Address code review feedback: the component-level cancellation telemetry
now uses 'Cancellation' as the terminationReason since cancellation could
be from timeout, manual cancellation, or reboot request. The more specific
'ExperimentTimeout' terminationReason is kept in ProfileExecutor where
we know the exact cause.

Agent-Logs-Url: https://github.com/microsoft/VirtualClient/sessions/ed26e102-6dfe-4c37-ab5f-c52008932555

Co-authored-by: nchapagain001 <165215502+nchapagain001@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix workload cancellation telemetry for experiment timeouts Emit explicit telemetry when workload execution is canceled due to experiment timeout Apr 24, 2026
Copilot AI requested a review from nchapagain001 April 24, 2026 01:15
- Component-level: emit crisp {TypeName}.ExecutionCancelled with
  executionCancelled=true context (no assumption about cause)
- ProfileExecutor-level: emit ExperimentTimeoutReached with timeout
  duration and timestamp (specific cause is known here)
- Remove wordy messages and redundant terminationReason fields

Agent-Logs-Url: https://github.com/microsoft/VirtualClient/sessions/1047bfc3-e0ae-4aca-b56f-ef3726de1a9b

Co-authored-by: nchapagain001 <165215502+nchapagain001@users.noreply.github.com>
@nchapagain001 nchapagain001 marked this pull request as ready for review April 24, 2026 01:31
@nchapagain001 nchapagain001 enabled auto-merge (squash) April 28, 2026 22:37
@nchapagain001 nchapagain001 merged commit 22fe633 into main Apr 28, 2026
5 checks passed
@nchapagain001 nchapagain001 deleted the copilot/fix-experiment-timeout-telemetry branch April 28, 2026 22:38
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.

Workload canceled due to experiment timeout without explicit telemetry

3 participants