spring-projects / spring-projects/spring-tools

[aot repositories] refresh AOT metadata fails when terminal process has different JVM

Open
#1,813 4 comments 0 reactions 1 assignee View on GitHub

@BoykoAlex is already working on this.

Since Feb 27, 2026.

for: vscode theme: spring-data-support type: bug
Dominant language
Java
Stars
983
Forks
240
Avg merge
7d 1h
Merged PRs (30d)
7

Description

Clicking on the Refresh AOT metadata code lens causes a build to be executed on the terminal, but that fails if the project uses a more recent JDK than what is being used by default in the terminal. In my case, I had JDK 21 set as the default in the terminal (on my macOS system in general, not specific to VSCode), but the project was configured to use Java 25. As a result, the build to refresh the AOT metadata failed.

We maybe need to use the project configuration to at least check whether the JDK that the terminal uses is compatible with what the project requires.

Not surf through whether we can go one step further and identify the correct JDK to use to run the build. Maybe we could infer that from the JDK-related classpath entries from the project.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.