Skip to content

Spring Boot Tools for VS Code shows unhelpful/incorrect warning #621

Closed

Description

@Herohtar

Expected Behavior

Spring Boot Tools should show a more informative warning when Java components are missing, or not show a warning at all if functionality is not actually affected.

Current Behavior

Currently, Spring Boot Tools will show the following warning message if the jmods component for Java is not installed, even if JAVA_HOME and/or PATH are pointing to the correct JDK location:

JAVA_HOME or PATH environment variable seems to point to a JRE. A JDK is required, hence Boot Hints are unavailable.

Installing the jmods component causes the message to go away. (eg, on my CentOS 8 system that involved installing the java-11-openjdk-jmods package)

Context

The warning message is confusing, as the problem is not with JAVA_HOME or PATH at all, and results in a lot of wasted time trying to figure out what is wrong.

This has been reported here multiple times by other confused users (#576 and #347, for example).

Despite the warning, there doesn't seem to actually be any issues with the extension when jmods is not installed, unless I misunderstand what "Boot Hints" are -- I can't seem to find any documentation that actually mentions that.

If functionality is not affected, the warning should not be shown, otherwise the warning should be updated to explain what is actually being complained about.

Activity

  1. added
    for: eclipse
    for: vscode
    and removed on Apr 8, 2021
  2. martinlippert commented on Apr 8, 2021

    @martinlippert
    Member

    Hey @Herohtar, yeah, I agree, this needs some improvements. I will add it to our backlog for one of the next releases.

  3. added this to the milestone on Apr 8, 2021
  4. self-assigned this
    on Apr 8, 2021
  5. wduminy commented on Apr 12, 2021

    @wduminy

    @Herohtar

    Despite the warning, there doesn't seem to actually be any issues with the extension when jmods is not installed

    This is good news. Thanks!

  6. kdvolder commented on Apr 12, 2021

    @kdvolder
    Member

    Despite the warning, there doesn't seem to actually be any issues with the extension when jmods is not installed

    The functionality that would be affected is not everything but only the live hover hints that show information about live beans.
    So this may be something that isn't easy to spot (i.e. most of the functionality will still work and many folks may not care about the live hovers to notice their absence).

    This is just for clarification, but I think we all agree the warning can be improved.

  7. modified the milestones: , 4.11.0.RELEASE on Apr 25, 2021
  8. removed this from the 4.14.0.RELEASE milestone on Mar 22, 2022
  9. added a commit that references this issue on Aug 20, 2026
  10. added this to the 5.4.0.RELEASE milestone on Aug 20, 2026
  11. martinlippert commented on Aug 20, 2026

    @martinlippert
    Member

    The check for the jmod files is already gone for quite some time, but I went ahead and adjusted the new test to include jdk.management and jdk.attach, and updated the error message to be more user friendly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

for: eclipsefor: vscodetype: enhancement

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions