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

Support multiple folders per workspace #482

Closed
radeksimko opened this issue May 4, 2021 · 1 comment · Fixed by #502
Closed

Support multiple folders per workspace #482

radeksimko opened this issue May 4, 2021 · 1 comment · Fixed by #502
Labels

Comments

@radeksimko
Copy link
Member

radeksimko commented May 4, 2021

Depends on hashicorp/vscode-terraform#627


Current Version

0.16.1

Problem Definition

Typically folders represent Terraform modules and the LS needs to obtain certain metadata about each module, before providing much of the functionality, such as completion, hover or semantic highlighting.

Obtaining such metadata can be CPU/memory intensive, which in itself shouldn't be problem as we cap CPU consumption by limiting number of tasks that can run at any given time based on available CPU.

However such caps don't apply when multiple instances of LS run at the same time as it is the client which orchestrates launching these instances and the instances do not know about each other.

Attempted Solutions

Currently the LS does not support multiple folders per workspace. As described above this may cause CPU spikes.

Proposal

Support multiple folders natively via LSP, as per https://microsoft.github.io/language-server-protocol/specifications/specification-current/#workspace_workspaceFolders
so that clients can run just a single instance of LS and just pass list of folders.

For clients that support this, we may also consider disabling the module walker.

References

hashicorp/vscode-terraform#591

@github-actions
Copy link

github-actions bot commented Aug 5, 2021

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 5, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant