Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shared process should have a clone of all profile storages #212904

Open
Tracked by #212907
sandy081 opened this issue May 16, 2024 · 2 comments
Open
Tracked by #212907

Shared process should have a clone of all profile storages #212904

sandy081 opened this issue May 16, 2024 · 2 comments
Assignees
Labels
debt Code quality issues settings-sync shared-process VS Code shared process issues workbench-state UI state across restarts
Milestone

Comments

@sandy081
Copy link
Member

sandy081 commented May 16, 2024

Discovered from #212664

At present when syncing a profile, Settings gets snapshot of each profile storage from main and discards the snapshot as soon as the sync is finished. On an average, settings sync syncs all profiles once per 5 minutes. This means, every 5 minutes settings sync reads all profiles storages from main.

Ref:

async readStorageData(profile: IUserDataProfile): Promise<Map<string, IStorageValue>> {
return this.withProfileScopedStorageService(profile, async storageService => this.getItems(storageService));
}

Instead

  • get profile storage from main when needed for the first time
  • from there on sync the storage from main using listeners - incrementally update the profile storage
@sandy081 sandy081 added debt Code quality issues settings-sync shared-process VS Code shared process issues workbench-state UI state across restarts labels May 16, 2024
@sandy081 sandy081 added this to the Backlog milestone May 16, 2024
@sandy081 sandy081 self-assigned this May 16, 2024
@sandy081
Copy link
Member Author

@bpasero What is your opinion?

@bpasero
Copy link
Member

bpasero commented May 16, 2024

Sounds good 👍

@sandy081 sandy081 modified the milestones: Backlog, June 2024 May 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
debt Code quality issues settings-sync shared-process VS Code shared process issues workbench-state UI state across restarts
Projects
None yet
Development

No branches or pull requests

2 participants