Skip to content

Commit 34b695a

Browse files
authored
fix(amazonq): Improve indexing auto start-stop strategy #5929
## Problem When multiple IDE instances are opened at the same time, the `@workspace ` indexing can increase CPU usage to a point that system fan needs to engage. IDE can be slow if it is older devices like intel i5 or i7 Mac OS. ## Solution When multiple IDE instances are opened at the same time, the `@workspace` indexing can increase CPU usage to a point that system fan needs to engage. IDE can be slow if it is older devices like intel i5 or i7 Mac OS. This PR is to improve indexing auto start-stop strategy, detect CPU usage more frequently and pause indexing more aggressively whenever system total CPU usage goes up. In the mean time, further reduce CPU usage for old Intel i5, i7 devices, make sure one IDE instance at most utilize one physical core and all instance combined cannot exceed 1 for any extended period of time more than a few seconds, unless user explicit allows more CPU usage in settings. Other mechanisms are implemented to stop indexing if system available memory is small.
1 parent 1486e3a commit 34b695a

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"type": "Bug Fix",
3+
"description": "Improve `@workspace` index auto pause start strategy. "
4+
}

packages/core/src/amazonq/lsp/lspController.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ export interface Manifest {
6666
}
6767
const manifestUrl = 'https://aws-toolkit-language-servers.amazonaws.com/q-context/manifest.json'
6868
// this LSP client in Q extension is only going to work with these LSP server versions
69-
const supportedLspServerVersions = ['0.1.24']
69+
const supportedLspServerVersions = ['0.1.25']
7070

7171
const nodeBinName = process.platform === 'win32' ? 'node.exe' : 'node'
7272

0 commit comments

Comments
 (0)