Skip to content

Don't overwrite system property java.version in org.springframework.boot:spring-boot-starter-parent #46650

@obfischer

Description

@obfischer

The starter parent of Spring Boot explicitly sets a property java.version.

<properties>
  <java.version>17</java.version>
  <resource.delimiter>@</resource.delimiter>
  <maven.compiler.release>${java.version}</maven.compiler.release>
  <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
  <spring-boot.run.main-class>${start-class}</spring-boot.run.main-class>
</properties>

Using this name for a property hinders your users to use the system property java.version set by the used virtual machine for checks and validations.

Please consider to use a different property name for Spring Boot 4.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions