Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[jdt-ls-dev] How Does the single LSP Service efficiently and exactly support the multi-workspace folders which differentiate between the different user?

Hello, I am a java programer who is employed in a tiny firm and have several questions about the eclipse.jdt.ls project.

eclipse.jdt.ls version: 1.6.0.20211126152438, java version "11.0.10" 2021-01-19 LTS


At first, I use the JLS for users to support their own workspace and start a new process(JLS instance) for every user when they enter the code edit page.

I find that the service is very slow during initialization, including initialize, publishDiagnostics method etc. Then I change the relation of workspace and JLS instance from one-to-one to many-to-one mode and pre-init the all projects when my app start. However, the JLS service is not as effective as I expect, there exist many problems as follows:

1、When the workspace have same projects with different URI such as /workspace/kim/project1 and /workspace/jack/project1, user open the same java file in both URI at same time, the completion method return the full compute result include both java file of the project itself and jar file to one user, and another only return the latter one.

the exact one:

exact one

the inexact one:

inexact one

the workspace of one user

image

the workspace of another user

image

2、The response time is very long even suspending the request when the different users use the JLS Service at the same time on the website for a while.

the response time(ms):

rt

To sum up, I wonder whether the single JLS service instance can support the multi-workspace folders includes same projects? if so, what do I have to do to improve the performance of service?



Back to the top