Extension telemetry feature cleanup (#21779)

* Extension telemetry feature cleanup

* one more
This commit is contained in:
Charles Gagnon
2023-01-30 13:14:38 -08:00
committed by GitHub
parent c33d2cc40a
commit ad69164f09
42 changed files with 145 additions and 619 deletions

View File

@@ -9,7 +9,7 @@ import * as Constants from './constants';
import * as vscode from 'vscode';
import * as path from 'path';
import { getCommonLaunchArgsAndCleanupOldLogFiles, getConfigTracingLevel, getOrDownloadServer, getParallelMessageProcessingConfig, TracingLevel } from './utils';
import { Telemetry, LanguageClientErrorHandler } from './telemetry';
import { TelemetryReporter, LanguageClientErrorHandler } from './telemetry';
import { SqlOpsDataClient, ClientOptions } from 'dataprotocol-client';
import { TelemetryFeature, AgentServicesFeature, SerializationFeature, AccountFeature, SqlAssessmentServicesFeature, ProfilerFeature, TableDesignerFeature, ExecutionPlanServiceFeature } from './features';
import { CredentialStore } from './credentialstore/credentialstore';
@@ -69,7 +69,7 @@ export class SqlToolsServer {
vscode.commands.registerCommand('mssql.loadCompletionExtension', (params: CompletionExtensionParams) => {
return this.client.sendRequest(CompletionExtLoadRequest.type, params);
});
Telemetry.sendTelemetryEvent('startup/LanguageClientStarted', {
TelemetryReporter.sendTelemetryEvent('startup/LanguageClientStarted', {
installationTime: String(installationComplete - installationStart),
processStartupTime: String(processEnd - processStart),
totalTime: String(processEnd - installationStart),
@@ -82,7 +82,7 @@ export class SqlToolsServer {
await Promise.all([this.activateFeatures(context), clientReadyPromise]);
return this.client;
} catch (e) {
Telemetry.sendTelemetryEvent('ServiceInitializingFailed');
TelemetryReporter.sendTelemetryEvent('ServiceInitializingFailed');
void vscode.window.showErrorMessage(localize('failedToStartServiceErrorMsg', "Failed to start {0}", Constants.serviceName));
throw e;
}