Closed harry-xm closed 1 month ago
When you define your server <server id="XXXlsp"
you can add the parameter lastDocumentDisconnectedTimeout="3600"
which is an inactivity timeout.
@harry-xm as @turkeylurkey suggested, you can define lastDocumentDisconnectedTimeout="3600"
for the moment.
Thanks. I guess if I set it to a year, that is effectively keeping servers alive.
Duplicate of https://github.com/redhat-developer/lsp4ij/issues/556
which will be covered in 0.7.0 with https://github.com/redhat-developer/lsp4ij/pull/543
Please read https://github.com/redhat-developer/lsp4ij/issues/556#issuecomment-2388699488 and give me your feedback about the name of the method.
In a large project, it might take quite some time for rust-analyzer to initialize itself.
If someone clicked "Close All Tabs" and subsequently opens another file, the language server is restarted and I have to wait until it finishes loading.
I'm thinking of keeping the language server running until the IDE window is closed, or after an inactivity timeout. IMHO, either the user should be given an option, or plugin authors should be able to control it via some API.
Originally posted in https://github.com/redhat-developer/lsp4ij/discussions/487