-
Notifications
You must be signed in to change notification settings - Fork 377
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
Server hangs after a burst of editing followed by a period of inactivity, emacs client #2431
Comments
1.12.0 was the last language server version to support starting up with a Java 11 runtime. If you're running 1.12.0 under Java 17, there might be some issues. I would maybe try the same with 1.13.0 if possible, or even the more recent 1.19.0. Also, is there a file at |
Unfortunately I found nothing unusual in the jdtls-1.19.log.txt
|
@gnuemacscoin Are you using maven? If so, can you show your pom.xml? |
From the client/server communication, it looks like the client initiated a shutdown, followed by an exit. It doesn't look like the server responded to the shutdown request, but I don't think that's necessarily required. Once a shutdown is sent, and processed the server will not respond to any requests, except exit. See https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#shutdown .
There's an attempt to cancel the shutdown but I don't think the protocol would support that. If you didn't close your client window, then I think it's an issue of figuring out what triggered the shutdown, since it looks to have come from the client. |
Here's pom along with logs from a brand new session, complete from start to finish this time. @Bean
protected IntegrationFlow someFlow() {
return IntegrationFlow
.from("someinput")
.log()
.channel("someOutput")
.get();
} then I wait for 15 minutes (starting with Note that using gradle doesn't fix anything. |
@gnuemacscoin Could you reproduce the issue when opening your project with VS Code? |
I couldn't reproduce it with VS Code, though I'm not too familiar with the editor. On Emacs side I'm confident that v1.7.0 is the milestone release that introduced this bug, v1.6.0 works fine (with JRE 17). Will try to bisect further. |
Here's an update. Commit I went and tried to debug this using vscode to attach to While executing // id: "_java.reloadBundles.command"
// params: []
public Object executeClientCommand(String id, Object... params) {
return this.client.executeClientCommand(new ExecuteCommandParams(id, ImmutableList.copyOf(params))).join();
} one thread hangs with trace
Similarly, at least 3 threads hang while executing // configurationParams:
// items:
// - scopeUri: "file:///home/username/alien/code/java/.eval/eval-messaging-and-integration/src/main/java/me/abcdef/eval/EvalMessagingAndIntegrationApplication.java"
// section: "java.format.tabSize"
// - scopeUri: "file:///home/username/alien/code/java/.eval/eval-messaging-and-integration/src/main/java/me/abcdef/eval/EvalMessagingAndIntegrationApplication.java"
// section: "java.format.insertSpaces"
public List<Object> configuration(ConfigurationParams configurationParams) {
this.client.configuration(configurationParams).join();
} with traces like
Then, 13 minutes later, I'm guessing this blockage catches up with the pool, causing To reproduce, try |
Closing as this is on |
Since I upgraded to java 11, and then later 17, every
jdtls
version I try tends to hang after editing a little bit of code, and then leaving the editor idle for around 10 minutes. First it'll stop responding totextDocument/hover
s,textDocument/codeAction
s andtextDocument/documentHighlight
s, but will keep responding to theircancelRequest
s. Then it'll process and send diagnostics for one finaltextDocument/didChange
, and after that it'll stop reading from standard input, eventually hanging my editor.Launched with
Taken from
https://download.eclipse.org/jdtls/snapshots/jdt-language-server-1.20.0-202302020244.tar.gz
, but also occurs underhttps://download.eclipse.org/jdtls/milestones/1.12.0/jdt-language-server-1.12.0-202206011637.tar.gz
.The text was updated successfully, but these errors were encountered: