mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-18 01:25:37 -05:00
Add more telemetry props to sql migration extension (#17026)
This commit is contained in:
@@ -95,8 +95,8 @@ export class WizardController {
|
||||
TelemetryViews.SqlMigrationWizard,
|
||||
TelemetryAction.PageButtonClick,
|
||||
{
|
||||
'sessionId': this._model._sessionId,
|
||||
'buttonPressed': 'cancel',
|
||||
...this.getTelemetryProps(),
|
||||
'buttonPressed': TelemetryAction.Cancel,
|
||||
'pageTitle': this._wizardObject.pages[this._wizardObject.currentPage].title
|
||||
}, {});
|
||||
});
|
||||
@@ -106,25 +106,34 @@ export class WizardController {
|
||||
TelemetryViews.SqlMigrationWizard,
|
||||
TelemetryAction.PageButtonClick,
|
||||
{
|
||||
'sessionId': this._model._sessionId,
|
||||
'buttonPressed': 'done',
|
||||
...this.getTelemetryProps(),
|
||||
'buttonPressed': TelemetryAction.Done,
|
||||
'pageTitle': this._wizardObject.pages[this._wizardObject.currentPage].title
|
||||
}, {});
|
||||
});
|
||||
}
|
||||
|
||||
private async sendPageButtonClickEvent(pageChangeInfo: azdata.window.WizardPageChangeInfo) {
|
||||
const buttonPressed = pageChangeInfo.newPage > pageChangeInfo.lastPage ? 'next' : 'prev';
|
||||
const pageTitle = this._wizardObject.pages[pageChangeInfo.lastPage].title;
|
||||
const buttonPressed = pageChangeInfo.newPage > pageChangeInfo.lastPage ? TelemetryAction.Next : TelemetryAction.Prev;
|
||||
const pageTitle = this._wizardObject.pages[pageChangeInfo.lastPage]?.title;
|
||||
sendSqlMigrationActionEvent(
|
||||
TelemetryViews.SqlMigrationWizard,
|
||||
TelemetryAction.PageButtonClick,
|
||||
{
|
||||
'sessionId': this._model._sessionId,
|
||||
...this.getTelemetryProps(),
|
||||
'buttonPressed': buttonPressed,
|
||||
'pageTitle': pageTitle
|
||||
}, {});
|
||||
}
|
||||
|
||||
private getTelemetryProps() {
|
||||
return {
|
||||
'sessionId': this._model._sessionId,
|
||||
'subscriptionId': this._model._targetSubscription?.id,
|
||||
'resourceGroup': this._model._resourceGroup?.name,
|
||||
'targetType': this._model._targetType,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
export function createInformationRow(view: azdata.ModelView, label: string, value: string): azdata.FlexContainer {
|
||||
|
||||
Reference in New Issue
Block a user