Commit 1996083
chore: improve java upgrade telemetry tracking and extension installation flow (#1030)
* Add source/install telemetry and drop unreliable activation check
Follow-up to v0.27.5 telemetry analysis
(devdiv-azure-service-dmitryr/azure-java-migration-copilot-vscode-extension#5979):
- Add a source field (SOURCE_CVE / SOURCE_JAVA_UPGRADE) to the
upgradeNotification.show event so NOTIFY-level data can be split by
CVE vs upgrade and aligned with downstream funnel stages.
- Emit an installSucceeded event (with the initial extensionState, so
fresh installs and updates can be told apart) right after
installExtension resolves.
- Drop the post-install getExtensionState re-check that produced false
activation-timeout results; the not-installed path now reports
proceeded and returns true after install completes.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Drop dedicated installSucceeded telemetry event
Address review: avoid adding a new business operationName for the
install step. Install success is already implied by the subsequent
upgradeFlow.result event under the same operation ID.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Track install-success as a dimension on the result event
Address review: instead of a dedicated installSucceeded operationName,
reuse the stable java.dependency.upgradeFlow.result event and mark the
install step with an upgradeFlowStep dimension (plus extensionState so
fresh installs and updates can be told apart). Easier to query and evolve.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Label install step by action instead of pre-install state
Address review: extensionState was the pre-install value, so tagging a
'succeeded' event with 'not-installed'/'outdated' was contradictory.
Replace it with installType ('installed' vs 'updated') derived from the
pre-install state, which is unambiguous and avoids an unreliable
post-install state recompute (the original activation-race bug).
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Don't prompt to enable extension in upgrade flow
extensions.getExtension() returns undefined both when the extension is
disabled and when it is freshly installed but not yet activated, so the
'seems disabled, enable it manually' prompt is misleading right after a
successful install. Skip it on the upgrade path; the function and the
modernization caller are left unchanged.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Wait for extension registration via onDidChange instead of fixed sleep
Replace the fixed 2s wait after a fresh install with an event-driven
wait: resolve immediately if the extension is already registered,
otherwise listen on extensions.onDidChange and proceed as soon as it
appears, with a 5s timeout fallback. Returns as early as possible while
still bounding the wait.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Frank Liu <haital@microsoft.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: wenyt <75360946+wenytang-ms@users.noreply.github.com>1 parent 0dc2467 commit 1996083
2 files changed
Lines changed: 33 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
| 96 | + | |
96 | 97 | | |
97 | 98 | | |
98 | 99 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
197 | 197 | | |
198 | 198 | | |
199 | 199 | | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
200 | 205 | | |
201 | 206 | | |
202 | 207 | | |
| |||
219 | 224 | | |
220 | 225 | | |
221 | 226 | | |
222 | | - | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
223 | 230 | | |
224 | | - | |
225 | | - | |
226 | | - | |
227 | | - | |
228 | | - | |
229 | | - | |
230 | 231 | | |
231 | 232 | | |
232 | | - | |
| 233 | + | |
233 | 234 | | |
234 | | - | |
| 235 | + | |
235 | 236 | | |
236 | | - | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
0 commit comments