Skip to content

Commit 89a91f0

Browse files
authored
Instrument sync (microsoft#167117)
1 parent d7e836d commit 89a91f0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/vs/platform/userDataSync/common/userDataAutoSyncService.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ type AutoSyncClassification = {
2525
owner: 'sandy081';
2626
comment: 'Information about the sources triggering auto sync';
2727
sources: { classification: 'SystemMetaData'; purpose: 'FeatureInsight'; isMeasurement: true; comment: 'Source that triggered auto sync' };
28+
providerId: { classification: 'SystemMetaData'; purpose: 'FeatureInsight'; isMeasurement: true; comment: 'Auth provider id used for sync' };
2829
};
2930

3031
type AutoSyncErrorClassification = {
@@ -354,7 +355,8 @@ export class UserDataAutoSyncService extends Disposable implements IUserDataAuto
354355
this.sources.push(...sources);
355356
return this.syncTriggerDelayer.trigger(async () => {
356357
this.logService.trace('activity sources', ...this.sources);
357-
this.telemetryService.publicLog2<{ sources: string[] }, AutoSyncClassification>('sync/triggered', { sources: this.sources });
358+
const providerId = this.userDataSyncAccountService.account?.authenticationProviderId || '';
359+
this.telemetryService.publicLog2<{ sources: string[]; providerId: string }, AutoSyncClassification>('sync/triggered', { sources: this.sources, providerId });
358360
this.sources = [];
359361
if (this.autoSync.value) {
360362
await this.autoSync.value.sync('Activity', disableCache);

0 commit comments

Comments
 (0)