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

[lsp-server] 🐞 Heap out of memory #3869

Open
1 task done
MeKo-Christian opened this issue Feb 27, 2025 · 1 comment
Open
1 task done

[lsp-server] 🐞 Heap out of memory #3869

MeKo-Christian opened this issue Feb 27, 2025 · 1 comment
Labels
bug lsp-server graphql-language-service-server

Comments

@MeKo-Christian
Copy link

MeKo-Christian commented Feb 27, 2025

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

In our big project, we are constantly seeing crashes like this:

<--- Last few GCs --->

[3450436:0x18d8000e8000]     6166 ms: Mark-Compact (reduce) 2853.2 (2882.3) -> 2853.2 (2875.3) MB, pooled: 0 MB, 50.26 / 0.00 ms  (average mu = 0.615, current mu = 0.260) last resort; GC in old space requested
[3450436:0x18d8000e8000]     6220 ms: Mark-Compact (reduce) 2853.2 (2875.3) -> 2853.2 (2875.3) MB, pooled: 0 MB, 53.84 / 0.00 ms  (average mu = 0.414, current mu = 0.001) last resort; GC in old space requested


<--- JS stacktrace --->

FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory
----- Native stack trace -----

[Error - 09:51:48] The vscode-graphql server crashed 5 times in the last 3 minutes. The server will not be restarted. See the output for more information.
[Info  - 09:51:48] The graphql server has stopped running

Any ideas / solutions for this?

Expected Behavior

Should not crash or at least show a graceful error message

Steps To Reproduce

Run VSCode with a big project

Environment

  • LSP Server Version: 0.13.0 (2025-02-19, 18:23:00)
  • OS: Ubuntu 24.04
  • LSP Client: VSCode v1.97.2

Anything else?

Happens on a similar system with the same projects for a colleague as well.

@MeKo-Christian MeKo-Christian added bug lsp-server graphql-language-service-server labels Feb 27, 2025
@acao
Copy link
Member

acao commented Feb 28, 2025

hello @MeKo-Christian - there is a refactor underway that should reduce the memory usage, as some drift has caused a bit of duplication in cacheing. can you share your graphql config file, with any necessary redactions? i may be able to help you find ways to optimize it for the time being

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug lsp-server graphql-language-service-server
Projects
None yet
Development

No branches or pull requests

2 participants