Remove app insights (#154296)

* Remove app insights

* Update product service to remove asimovKey
This commit is contained in:
Logan Ramos
2022-07-06 22:23:30 -04:00
committed by GitHub
parent 93d1f7c881
commit d6114a70be
20 changed files with 36 additions and 697 deletions
+5 -5
View File
@@ -53,7 +53,7 @@ import { resolveCommonProperties } from 'vs/platform/telemetry/common/commonProp
import { ITelemetryService, machineIdKey } from 'vs/platform/telemetry/common/telemetry';
import { ITelemetryServiceConfig, TelemetryService } from 'vs/platform/telemetry/common/telemetryService';
import { supportsTelemetry, NullTelemetryService, getPiiPathsFromEnvironment } from 'vs/platform/telemetry/common/telemetryUtils';
import { AppInsightsAppender } from 'vs/platform/telemetry/node/appInsightsAppender';
import { OneDataSystemAppender } from 'vs/platform/telemetry/node/1dsAppender';
import { buildTelemetryMessage } from 'vs/platform/telemetry/node/telemetry';
import { IUriIdentityService } from 'vs/platform/uriIdentity/common/uriIdentity';
import { UriIdentityService } from 'vs/platform/uriIdentity/common/uriIdentityService';
@@ -104,7 +104,7 @@ class CliMain extends Disposable {
});
}
private async initServices(): Promise<[IInstantiationService, AppInsightsAppender[]]> {
private async initServices(): Promise<[IInstantiationService, OneDataSystemAppender[]]> {
const services = new ServiceCollection();
// Product
@@ -186,10 +186,10 @@ class CliMain extends Disposable {
services.set(ILanguagePackService, new SyncDescriptor(NativeLanguagePackService));
// Telemetry
const appenders: AppInsightsAppender[] = [];
const appenders: OneDataSystemAppender[] = [];
if (supportsTelemetry(productService, environmentService)) {
if (productService.aiConfig && productService.aiConfig.asimovKey) {
appenders.push(new AppInsightsAppender('monacoworkbench', null, productService.aiConfig.asimovKey));
if (productService.aiConfig && productService.aiConfig.ariaKey) {
appenders.push(new OneDataSystemAppender(configurationService, 'monacoworkbench', null, productService.aiConfig.ariaKey));
}
const { installSourcePath } = environmentService;