mirror of
https://github.com/Microsoft/vscode
synced 2024-10-02 17:32:41 +00:00
report telemetry even when not auto (#215792)
This commit is contained in:
parent
8dcd7945af
commit
fc1a9a48ec
|
@ -1299,7 +1299,7 @@ export class ExtensionsWorkbenchService extends Disposable implements IExtension
|
|||
return undefined;
|
||||
}
|
||||
|
||||
async updateRunningExtensions(auto?: boolean): Promise<void> {
|
||||
async updateRunningExtensions(auto: boolean = false): Promise<void> {
|
||||
const toAdd: ILocalExtension[] = [];
|
||||
const toRemove: string[] = [];
|
||||
|
||||
|
@ -1342,17 +1342,17 @@ export class ExtensionsWorkbenchService extends Disposable implements IExtension
|
|||
if (toAdd.length || toRemove.length) {
|
||||
if (await this.extensionService.stopExtensionHosts(nls.localize('restart', "Enable or Disable extensions"), auto)) {
|
||||
await this.extensionService.startExtensionHosts({ toAdd, toRemove });
|
||||
if (auto) {
|
||||
type ExtensionsAutoRestartClassification = {
|
||||
owner: 'sandy081';
|
||||
comment: 'Report when extensions are auto restarted';
|
||||
count: { classification: 'SystemMetaData'; purpose: 'FeatureInsight'; comment: 'Number of extensions auto restarted' };
|
||||
auto: { classification: 'SystemMetaData'; purpose: 'FeatureInsight'; comment: 'Whether the restart was triggered automatically' };
|
||||
};
|
||||
type ExtensionsAutoRestartEvent = {
|
||||
count: number;
|
||||
auto: boolean;
|
||||
};
|
||||
this.telemetryService.publicLog2<ExtensionsAutoRestartEvent, ExtensionsAutoRestartClassification>('extensions:autorestart', { count: toAdd.length + toRemove.length });
|
||||
}
|
||||
this.telemetryService.publicLog2<ExtensionsAutoRestartEvent, ExtensionsAutoRestartClassification>('extensions:autorestart', { count: toAdd.length + toRemove.length, auto });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue