redhat-developer / redhat-developer/vscode-java

Slow workspace initialization and reference search in large Gradle monorep

Abierto
#3,904 16 comentarios 2 reacciones 1 asignado Ver en GitHub

@snjeza ya está trabajando en esto.

Desde el 29/12/2024.

regression
Lenguaje dominante
TypeScript
Estrellas
2.3k
Forks
546
Merge medio
20 h 1 min
PR fusionados (30 d)
11

Descripción

Description

Each time I start VSCode, the Java Language Server re-initializes the workspace which takes a considerable amount of time. During this initialization period, I cannot:

  • Navigate to object references
  • See method callers/usages
  • Use other indexing-dependent features

Even after indexing is complete, searching for references takes several seconds to display results, which is significantly slower compared to IntelliJ.

Project Structure
  • Type: Monorepo with root project and multiple modules
  • Build Tool: Gradle
Current Setup
  • Extensions installed:
    • Gradle for Java
    • Java Language Server
What I've tried
  • Setting "java.import.gradle.enabled": false - This didn't help as it prevented project importing altogether, making indexing features unavailable
  • Default settings with "java.import.gradle.enabled": true - Works but very slow initialization
Expected Behavior
  • Faster workspace initialization on startup
  • Quick reference search response (similar to IntelliJ performance)
  • Persistence of indexing between editor sessions
Actual Behavior
  1. Every editor restart triggers full workspace reinitialization
  2. Reference search takes several seconds to display results
  3. Unable to use navigation features during initialization
Environment
  • OS: macOS Ventura 13.1
  • Java Language Server Extension Version: 1.38.0
  • Gradle for Java Extension Version: 3.16.4
  • VSCoder Version: 1.93.1
  • JDK Version: Amazon Coretto 1.8
Additional Context

This is affecting development productivity significantly, especially when working with large codebases that require frequent navigation between references and implementations.

Question

Is there a way to:

  1. Persist the indexing between editor sessions?
  2. Optimize the reference search performance?
  3. Configure selective indexing for specific modules while maintaining full functionality?

Guía de contribución

Abrir la guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.