You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Slawomir Jaranowski <s....@gmail.com> on 2023/03/23 19:57:45 UTC

[DISCUSSION] Apache Maven plugins versioning

Hi,

I know that historically plugin versions like 2.x was dedicated to Maven
2.x and versions 3.x is for Maven 3.x.

We don't have any written documentation about it (or I can't find it), it
looks like a traditional agreement.

Nowadays Semantic Versioning is very popular and it is understood by people
and by automatic tools.
In many cases we use versions which look like Semantic Versioning (x.y.z) -
but internally we try to classify it in different ways.

When we connect the plugins version with the Maven version as the major
version,
we have difficulty introducing breaking changes for plugins for the same
Maven version.
Also we can introduce many misunderstandings which version contains new
features and which only bug fixes.

Authors of plugins outside Maven core in many cases don't use 3.x as for
Maven 3 and so on.

One of the propositions can be - use Semantic Versioning as is described
and put a Maven version in the artifact name of the plugin.

So we can have:

maven4-XXX-plugin - for core plugins
XXX-maven4-plugin - for external plugins

Additionally Maven 4 will have a new Api which is incompatible with Maven
3, when we have the target Maven version in artifact it will be easier to
transition plugins from 3 to 4 and so on.

Simply in many cases business logic which plugin provides can be extracted
to a common module and next two modules will provide plugins for specific
Maven.
It can help maintain one plugin for many Maven versions.


-- 
Sławomir Jaranowski

Re: [DISCUSSION] Apache Maven plugins versioning

Posted by Romain Manni-Bucau <rm...@gmail.com>.
So you mean maven 5 will need to rename and rerelease all plugins even if
they will be compatible thanks the policy versioning rule + new API?
Npm and webpacks are not great rerefences since they don't aim at being
stable as we intend.
Look at javaee (before the jakarta big bang which broke this assumption):
you can use v4 and run on v7 and several parts were not even re-released so
not sure the related work is worth it.

Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://rmannibucau.metawerx.net/> | Old Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
<https://www.packtpub.com/application-development/java-ee-8-high-performance>


Le lun. 27 mars 2023 à 19:22, Benjamin Marwell <bm...@apache.org> a
écrit :

> The advantage is simple.
> With "maven4" in the module name, you don't need a compatibility matrix on
> every plugins homepage or readme.
>
> Just look at npm modules and webpack... Tables over tables...
>
>
>
>
> On Sun, 26 Mar 2023, 19:29 Michael Osipov, <mi...@apache.org> wrote:
>
> > Am 2023-03-26 um 19:02 schrieb Romain Manni-Bucau:
> > > @Benjamin what's the addtion of the "4" except looking weird after 1
> > > version since you use semver? It forces 2 changes instead of one
> without
> > > anything else explicit IMHO.
> >
> > I fully second that!
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> >
> >
>

Re: [DISCUSSION] Apache Maven plugins versioning

Posted by Benjamin Marwell <bm...@apache.org>.
The advantage is simple.
With "maven4" in the module name, you don't need a compatibility matrix on
every plugins homepage or readme.

Just look at npm modules and webpack... Tables over tables...




On Sun, 26 Mar 2023, 19:29 Michael Osipov, <mi...@apache.org> wrote:

> Am 2023-03-26 um 19:02 schrieb Romain Manni-Bucau:
> > @Benjamin what's the addtion of the "4" except looking weird after 1
> > version since you use semver? It forces 2 changes instead of one without
> > anything else explicit IMHO.
>
> I fully second that!
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>

Re: [DISCUSSION] Apache Maven plugins versioning

Posted by Michael Osipov <mi...@apache.org>.
Am 2023-03-26 um 19:02 schrieb Romain Manni-Bucau:
> @Benjamin what's the addtion of the "4" except looking weird after 1
> version since you use semver? It forces 2 changes instead of one without
> anything else explicit IMHO.

I fully second that!


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: [DISCUSSION] Apache Maven plugins versioning

Posted by Romain Manni-Bucau <rm...@gmail.com>.
@Benjamin what's the addtion of the "4" except looking weird after 1
version since you use semver? It forces 2 changes instead of one without
anything else explicit IMHO.

Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://rmannibucau.metawerx.net/> | Old Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
<https://www.packtpub.com/application-development/java-ee-8-high-performance>


Le dim. 26 mars 2023 à 18:16, Benjamin Marwell <bm...@apache.org> a
écrit :

> +1 to your proposal
>
> org.apache.maven:maven4-xyz-plugin:<semver>
>
> I don't think it would cause too much trouble as Maven APIs will love for a
> few years. It will only occasionally break when a new major Maven release
> is published. I can live with that.
>
> Also, maven 3 plugins will be compatible for a while.
>
>
>
>
> On Thu, 23 Mar 2023, 20:58 Slawomir Jaranowski, <s....@gmail.com>
> wrote:
>
> > Hi,
> >
> > I know that historically plugin versions like 2.x was dedicated to Maven
> > 2.x and versions 3.x is for Maven 3.x.
> >
> > We don't have any written documentation about it (or I can't find it), it
> > looks like a traditional agreement.
> >
> > Nowadays Semantic Versioning is very popular and it is understood by
> people
> > and by automatic tools.
> > In many cases we use versions which look like Semantic Versioning
> (x.y.z) -
> > but internally we try to classify it in different ways.
> >
> > When we connect the plugins version with the Maven version as the major
> > version,
> > we have difficulty introducing breaking changes for plugins for the same
> > Maven version.
> > Also we can introduce many misunderstandings which version contains new
> > features and which only bug fixes.
> >
> > Authors of plugins outside Maven core in many cases don't use 3.x as for
> > Maven 3 and so on.
> >
> > One of the propositions can be - use Semantic Versioning as is described
> > and put a Maven version in the artifact name of the plugin.
> >
> > So we can have:
> >
> > maven4-XXX-plugin - for core plugins
> > XXX-maven4-plugin - for external plugins
> >
> > Additionally Maven 4 will have a new Api which is incompatible with Maven
> > 3, when we have the target Maven version in artifact it will be easier to
> > transition plugins from 3 to 4 and so on.
> >
> > Simply in many cases business logic which plugin provides can be
> extracted
> > to a common module and next two modules will provide plugins for specific
> > Maven.
> > It can help maintain one plugin for many Maven versions.
> >
> >
> > --
> > Sławomir Jaranowski
> >
>

Re: [DISCUSSION] Apache Maven plugins versioning

Posted by Benjamin Marwell <bm...@apache.org>.
+1 to your proposal

org.apache.maven:maven4-xyz-plugin:<semver>

I don't think it would cause too much trouble as Maven APIs will love for a
few years. It will only occasionally break when a new major Maven release
is published. I can live with that.

Also, maven 3 plugins will be compatible for a while.




On Thu, 23 Mar 2023, 20:58 Slawomir Jaranowski, <s....@gmail.com>
wrote:

> Hi,
>
> I know that historically plugin versions like 2.x was dedicated to Maven
> 2.x and versions 3.x is for Maven 3.x.
>
> We don't have any written documentation about it (or I can't find it), it
> looks like a traditional agreement.
>
> Nowadays Semantic Versioning is very popular and it is understood by people
> and by automatic tools.
> In many cases we use versions which look like Semantic Versioning (x.y.z) -
> but internally we try to classify it in different ways.
>
> When we connect the plugins version with the Maven version as the major
> version,
> we have difficulty introducing breaking changes for plugins for the same
> Maven version.
> Also we can introduce many misunderstandings which version contains new
> features and which only bug fixes.
>
> Authors of plugins outside Maven core in many cases don't use 3.x as for
> Maven 3 and so on.
>
> One of the propositions can be - use Semantic Versioning as is described
> and put a Maven version in the artifact name of the plugin.
>
> So we can have:
>
> maven4-XXX-plugin - for core plugins
> XXX-maven4-plugin - for external plugins
>
> Additionally Maven 4 will have a new Api which is incompatible with Maven
> 3, when we have the target Maven version in artifact it will be easier to
> transition plugins from 3 to 4 and so on.
>
> Simply in many cases business logic which plugin provides can be extracted
> to a common module and next two modules will provide plugins for specific
> Maven.
> It can help maintain one plugin for many Maven versions.
>
>
> --
> Sławomir Jaranowski
>

Re: [DISCUSSION] Apache Maven plugins versioning

Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hi,

Think linking maven and maven plugins version does not make sense for most
people since at the end the compat is somehow documented by the
dependencyso using a more common versioning (semver or not) sounds straight
forward.
What would be very bad for me would be a renaming (xxx -> xxx4 for ex) in
the gav or packages (commons style), it has too much impacts for almost no
gain in practise so let's keep it simple and efficient.

Just my 2 cts.
Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://rmannibucau.metawerx.net/> | Old Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
<https://www.packtpub.com/application-development/java-ee-8-high-performance>


Le jeu. 23 mars 2023 à 20:58, Slawomir Jaranowski <s....@gmail.com>
a écrit :

> Hi,
>
> I know that historically plugin versions like 2.x was dedicated to Maven
> 2.x and versions 3.x is for Maven 3.x.
>
> We don't have any written documentation about it (or I can't find it), it
> looks like a traditional agreement.
>
> Nowadays Semantic Versioning is very popular and it is understood by people
> and by automatic tools.
> In many cases we use versions which look like Semantic Versioning (x.y.z) -
> but internally we try to classify it in different ways.
>
> When we connect the plugins version with the Maven version as the major
> version,
> we have difficulty introducing breaking changes for plugins for the same
> Maven version.
> Also we can introduce many misunderstandings which version contains new
> features and which only bug fixes.
>
> Authors of plugins outside Maven core in many cases don't use 3.x as for
> Maven 3 and so on.
>
> One of the propositions can be - use Semantic Versioning as is described
> and put a Maven version in the artifact name of the plugin.
>
> So we can have:
>
> maven4-XXX-plugin - for core plugins
> XXX-maven4-plugin - for external plugins
>
> Additionally Maven 4 will have a new Api which is incompatible with Maven
> 3, when we have the target Maven version in artifact it will be easier to
> transition plugins from 3 to 4 and so on.
>
> Simply in many cases business logic which plugin provides can be extracted
> to a common module and next two modules will provide plugins for specific
> Maven.
> It can help maintain one plugin for many Maven versions.
>
>
> --
> Sławomir Jaranowski
>

Re: [DISCUSSION] Apache Maven plugins versioning

Posted by Slawomir Jaranowski <s....@gmail.com>.
Hi

We can also publish in plugin documentation history of Maven API and JDK
requirements [1]

I still think we should make some decisions on it ... and publish to be
clear in such matters.

We have m-site-p in version 4.0.0-M6 - does mean that should be used with
Maven 4, it still require Maven 3.2.5 [2]

[1]
https://www.mojohaus.org/animal-sniffer/animal-sniffer-maven-plugin/plugin-info.html
[2] https://maven.apache.org/plugins/maven-site-plugin/plugin-info.html


czw., 23 mar 2023 o 20:57 Slawomir Jaranowski <s....@gmail.com>
napisał(a):

> Hi,
>
> I know that historically plugin versions like 2.x was dedicated to Maven
> 2.x and versions 3.x is for Maven 3.x.
>
> We don't have any written documentation about it (or I can't find it), it
> looks like a traditional agreement.
>
> Nowadays Semantic Versioning is very popular and it is understood by
> people and by automatic tools.
> In many cases we use versions which look like Semantic Versioning (x.y.z)
> - but internally we try to classify it in different ways.
>
> When we connect the plugins version with the Maven version as the major
> version,
> we have difficulty introducing breaking changes for plugins for the same
> Maven version.
> Also we can introduce many misunderstandings which version contains new
> features and which only bug fixes.
>
> Authors of plugins outside Maven core in many cases don't use 3.x as for
> Maven 3 and so on.
>
> One of the propositions can be - use Semantic Versioning as is described
> and put a Maven version in the artifact name of the plugin.
>
> So we can have:
>
> maven4-XXX-plugin - for core plugins
> XXX-maven4-plugin - for external plugins
>
> Additionally Maven 4 will have a new Api which is incompatible with Maven
> 3, when we have the target Maven version in artifact it will be easier to
> transition plugins from 3 to 4 and so on.
>
> Simply in many cases business logic which plugin provides can be extracted
> to a common module and next two modules will provide plugins for specific
> Maven.
> It can help maintain one plugin for many Maven versions.
>
>
> --
> Sławomir Jaranowski
>


-- 
Sławomir Jaranowski

Re: [DISCUSSION] Apache Maven plugins versioning

Posted by Michael Osipov <mi...@apache.org>.
Am 2023-03-23 um 20:57 schrieb Slawomir Jaranowski:
> Hi,
> 
> I know that historically plugin versions like 2.x was dedicated to Maven
> 2.x and versions 3.x is for Maven 3.x.
> 
> We don't have any written documentation about it (or I can't find it), it
> looks like a traditional agreement.

I wouldn't tie it anymore. It just needs proper documentation. I will 
soon bump *all* reporting plugins to new major versions because the 
Doxia 2.0.0 stack is coming. Same Maven version, but Doxia 1.x will be 
left behind. This CANNOT happen in a minor version.

SemVer has its issues, it does not support post-release qualifiers, I 
consider it, by looking at the EBNF too complex.

We have also this: 
https://ci-maven.apache.org/job/Maven/job/maven-box/job/maven-dist-tool/job/master/site/dist-tool-prerequisites.html

M

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: [DISCUSSION] Apache Maven plugins versioning

Posted by Elliotte Rusty Harold <el...@ibiblio.org>.
I vote +1 on just using semver, more or less, and calling it a day.

We really shouldn't change artifact IDs unless we're changing
everything else too so it's basically a new artifact. Even if it is a
completely new plugin, it's likely that in the future it will want to
support Maven 5+ so let's not bake the Maven version into the artifact
ID. They should be able to evolve more independently. The Maven
coordinates are not the right place to indicate which Maven versions a
given plugin supports.

On Thu, Mar 23, 2023 at 3:58 PM Slawomir Jaranowski
<s....@gmail.com> wrote:
>
> Hi,
>
> I know that historically plugin versions like 2.x was dedicated to Maven
> 2.x and versions 3.x is for Maven 3.x.
>
> We don't have any written documentation about it (or I can't find it), it
> looks like a traditional agreement.
>
> Nowadays Semantic Versioning is very popular and it is understood by people
> and by automatic tools.
> In many cases we use versions which look like Semantic Versioning (x.y.z) -
> but internally we try to classify it in different ways.
>
> When we connect the plugins version with the Maven version as the major
> version,
> we have difficulty introducing breaking changes for plugins for the same
> Maven version.
> Also we can introduce many misunderstandings which version contains new
> features and which only bug fixes.
>
> Authors of plugins outside Maven core in many cases don't use 3.x as for
> Maven 3 and so on.
>
> One of the propositions can be - use Semantic Versioning as is described
> and put a Maven version in the artifact name of the plugin.
>
> So we can have:
>
> maven4-XXX-plugin - for core plugins
> XXX-maven4-plugin - for external plugins
>
> Additionally Maven 4 will have a new Api which is incompatible with Maven
> 3, when we have the target Maven version in artifact it will be easier to
> transition plugins from 3 to 4 and so on.
>
> Simply in many cases business logic which plugin provides can be extracted
> to a common module and next two modules will provide plugins for specific
> Maven.
> It can help maintain one plugin for many Maven versions.
>
>
> --
> Sławomir Jaranowski



-- 
Elliotte Rusty Harold
elharo@ibiblio.org

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org