The old objects of eclipse.jdt.ls took up the entire heap space, and then emacs crashed.
When I use to open a project and use dap-java-debug to execute several times, the code prompt is very slow and the editing is not smooth. It crashed after executing emacs a few more times. I found that the heap of eclipse.jdt.ls is full, all objects of the old age. Garbage collection cannot reclaim any space. Then I set lsp-server-vmargs -Xmx2G, the same situation appeared again, but the time of appearance was extended. What happened? Does eclispse.jdt.ls retain the previously compiled and modified code objects every time?
jdk: openjdk-11 gc: G1
Other: default
I think that you should generate hprof file and report that in jdtls repo. It might be a bug in emacs infrastructure(e. g. not doing cleanup call) or memory leak in jdtls. In both cases the hprof will help out.
Also, it might be not a bug but an issue with your project being too bit to have several debug session at the time.
ok, Thank you