You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Christoph Läubrich (Jira)" <ji...@apache.org> on 2024/02/04 08:06:00 UTC
[jira] [Created] (MNG-8040) Allow prerequisites of maven plugins to define there minimum required java version
Christoph Läubrich created MNG-8040:
---------------------------------------
Summary: Allow prerequisites of maven plugins to define there minimum required java version
Key: MNG-8040
URL: https://issues.apache.org/jira/browse/MNG-8040
Project: Maven
Issue Type: New Feature
Reporter: Christoph Läubrich
Currently the [prerequisites|https://maven.apache.org/pom.html#Prerequisites] of a maven-plugin to define a minimum maven version and then maven gives a nice message to the user if this is not meet.
Given the fast evolution of java versions plugins are facing another issue, e.g. if one of their dependencies require a *higher java version* than is the default for maven this currently fails with a rather cryptic "unsupported class version" error when running such a build.
It would therefore be good to extend the element so that plugins can declare:
{code:java}
<prerequisites>
<maven>${minimal-maven-version}</maven>
<java>${minimal-java-version}</java>
</prerequisites>
{code}
please note that using [Maven Enforcer Plugin's|https://maven.apache.org/enforcer/index.html] is not an option here as it requires the user to know beforehand the java version of all its build plugins.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)