Skip to content

Clear timeouts/intervals on dispose in extensions#319125

Merged
dmitrivMS merged 6 commits into
mainfrom
dev/dmitriv/perf-timers-chat
May 30, 2026
Merged

Clear timeouts/intervals on dispose in extensions#319125
dmitrivMS merged 6 commits into
mainfrom
dev/dmitriv/perf-timers-chat

Conversation

@dmitrivMS
Copy link
Copy Markdown
Contributor

No description provided.

dmitrivMS and others added 5 commits May 30, 2026 04:45
Copilot AI review requested due to automatic review settings May 30, 2026 11:51
@dmitrivMS dmitrivMS added the perf label May 30, 2026
@dmitrivMS dmitrivMS self-assigned this May 30, 2026
@dmitrivMS dmitrivMS enabled auto-merge (squash) May 30, 2026 11:51
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves lifecycle cleanup in the Copilot Chat extension by ensuring scheduled timers (timeouts/intervals) are cleared when related services are disposed, reducing the risk of background work continuing after deactivation.

Changes:

  • Track and clear the inactivity survey timeout and usage debounce timeout in SurveyService.dispose().
  • Clear the active-thread monitoring interval in ReviewServiceImpl.dispose().
  • Add disposal cleanup for blocked-extension expiry timers in BlockedExtensionService.
Show a summary per file
File Description
extensions/copilot/src/platform/survey/vscode/surveyServiceImpl.ts Tracks timeout handles and clears them on service disposal.
extensions/copilot/src/platform/review/vscode/reviewServiceImpl.ts Clears the review-thread monitoring interval during disposal.
extensions/copilot/src/platform/chat/common/blockedExtensionService.ts Uses typed timeout handles and clears them during disposal.

Copilot's findings

  • Files reviewed: 3/3 changed files
  • Comments generated: 4

Comment thread extensions/copilot/src/platform/survey/vscode/surveyServiceImpl.ts
Comment thread extensions/copilot/src/platform/survey/vscode/surveyServiceImpl.ts
Comment thread extensions/copilot/src/platform/review/vscode/reviewServiceImpl.ts
@dmitrivMS dmitrivMS changed the title Clear timeouts/intervals on dispose in chat extension Clear timeouts/intervals on dispose in extensions May 30, 2026
@vs-code-engineering
Copy link
Copy Markdown
Contributor

📬 CODENOTIFY

The following users are being notified based on files changed in this PR:

@lszomoru

Matched files:

  • extensions/git/src/askpass.ts
  • extensions/git/src/fileSystemProvider.ts

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot's findings

  • Files reviewed: 8/8 changed files
  • Comments generated: 2

Comment thread extensions/php-language-features/src/features/validationProvider.ts
@dmitrivMS dmitrivMS merged commit 92fe1dc into main May 30, 2026
26 checks passed
@dmitrivMS dmitrivMS deleted the dev/dmitriv/perf-timers-chat branch May 30, 2026 12:19
@vs-code-engineering vs-code-engineering Bot added this to the 1.123.0 milestone May 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants