You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Guillaume Nodet <gn...@apache.org> on 2024/07/12 13:26:38 UTC

[DISCUSS] Move some mojohaus plugins to the ASF

I've been working on migrating the build-helper-maven-plugin to the
Maven 4.x API.
The work is available at [1] (PR is red, but that's a CI configuration problem).
While doing so, I've had a hard time figuring out why some plugins are
hosted at the ASF while some others are hosted at MojoHaus.
This plugin in particular is used a lot (to add generated
source/resources and attach artifacts) and there's no other way to do
it.  This is essentially a core feature of Maven, and thus, I think it
should be provided by a Maven plugin.
I've created a repo and migrated it at [2], but now raising the discussion...

If that causes a problem, I think we should provide a new plugin with
just those goals (add main/test source/resources directory, and attach
artifact).

It just feels weird that Maven does not provide the required plugins directly...

That said, I think we have some old plugins that have not been
released since nearly 10 years [3], probably indicating they are not
used anymore: verifier, acr ?, jmod, changelog, changes, doap, jdeps,
linkcheck, jarsigner, jdeprscan, patch, pdf, stage.
I think those should be retired...

[1] https://github.com/mojohaus/build-helper-maven-plugin/pull/215
[2] https://github.com/apache/maven-build-helper-plugin
[3] https://maven.apache.org/plugins/

-- 
------------------------
Guillaume Nodet

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


Re: [DISCUSS] Move some mojohaus plugins to the ASF

Posted by Olivier Lamy <ol...@apache.org>.
Hi,
This should be discussed at the maybe dormant but original mojohaus
mailing list  as well: https://www.mojohaus.org/mailing-lists.html
the last few years were all about reducing code we maintain here and
now we want to add more?
I find the mojohaus release process very simple and quick compared to
what we have here.
At the end of the day it's just a github repo somewhere else where
most of maven dev folks have permissions
I'm not really sure what moving this here will fix except slow down
the release process?

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


Re: [DISCUSS] Move some mojohaus plugins to the ASF

Posted by Martin Desruisseaux <ma...@geomatys.com>.
Le 2024-07-12 à 19 h 00, Guillaume Nodet a écrit :

> I like it a lot. This could also prove very useful to better support 
> multi-release JARs.
>
Yes, I had that purpose in mind as well, and multi-releases is one of 
the reasons for the proposal. It would also be useful for Module Source 
Hierarchy, but I avoid that discussion for now because I do not want 
JPMS debate to block the rest.


> However, resources have many more fields, see 
> https://maven.apache.org/pom.html#resources, so I'm not really sure 
> they can really be merged together.
>
We could consider that those fields can potentially apply to many kinds 
of sources (e.g. filtering), and make them available in <source> elements.


> I used `scope` above, because we have `ProjectScope`defined in the API 
> for that already.
>
Fine for me (I also thought about using "scope" instead of "type").

     Martin


Re: [DISCUSS] Move some mojohaus plugins to the ASF

Posted by Guillaume Nodet <gn...@apache.org>.
Le ven. 12 juil. 2024 à 15:55, Martin Desruisseaux <
martin.desruisseaux@geomatys.com> a écrit :

> Le 2024-07-12 à 15 h 26, Guillaume Nodet a écrit :
>
> > I've been working on migrating the build-helper-maven-plugin to the
> > Maven 4.x API. (…snip…). This plugin in particular is used a lot (to
> > add generated source/resources and attach artifacts) and there's no
> > other way to do it. This is essentially a core feature of Maven, and
> > thus, I think it should be provided by a Maven plugin. (…snip…) It
> > just feels weird that Maven does not provide the required plugins
> > directly...
> >
> Alternatively, should we open the "multi-sources" discussion? We can
> leave apart all the aspects related to JPMS for now. Reminder: it is
> about changing the POM model for replacing:
>
>     <build>
>        <sourceDirectory>src/main/java</sourceDirectory>
>     </build>
>
> By something like below (the addition of "generated/main/java" is what
> build-helper-maven-plugin is used for):
>
>     <build>
>        <sources>
>          <source>src/main/java</source>
>          <source>generated/main/java</source>
>        <sources>
>     </build>
>
> Additional attributes (release version, module name) may be added later,
> but I would like to avoid this debate for now. But if we add a "type"
> attribute now, the above proposal can actually replace all the following
> (from the current POM model):
>
>     <build>
>        <sourceDirectory>src/main/java</sourceDirectory>
>        <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
>        <testSourceDirectory>src/test/java</testSourceDirectory>
>        <resources>
>          <resource>
>            <directory>src/main/resources</directory>
>          </resource>
>        </resources>
>        <testResources>
>          <testResource>
>            <directory>src/test/resources</directory>
>          </testResource>
>        </testResources>
>     </build>
>
> By a more uniform pattern like below. Keep in mind that the core of this
> proposal is that all <source> elements are repeatable, not only the
> <resource> or <testResource> ones:
>
>     <sources>
>        <source  type="main">src/main/java</source>
>        <source  type="script">src/main/scripts</source>
>        <source  type="test">src/test/java</source>
>        <source  type="resource">src/main/resources</source>
>        <source  type="test-resource">src/test/resources</source>
>     <sources>
>

I like it a lot.  This could also prove very useful to better support
multi-release JARs.
However, resources have many more fields, see
https://maven.apache.org/pom.html#resources,
so I'm not really sure they can really be merged together.
But we could have two sets:

  <build>
    <sources>
       <source  scope="main">src/main/java</source>
       <source  scope="main" multi-release="11">src/main/java11</source>
       <source  scope="test">src/test/java</source>
    </sources>
    <resources>
      <resource  type="main">
         ...
      </resource>
      <resource  type="test">
         ...
      </resource>
    </resources>

I used `scope` above, because we have `ProjectScope`defined in the API for
that already.


>
>      Martin
>
>

Re: [DISCUSS] Move some mojohaus plugins to the ASF

Posted by Martin Desruisseaux <ma...@geomatys.com>.
Le 2024-07-12 à 15 h 26, Guillaume Nodet a écrit :

> I've been working on migrating the build-helper-maven-plugin to the 
> Maven 4.x API. (…snip…). This plugin in particular is used a lot (to 
> add generated source/resources and attach artifacts) and there's no 
> other way to do it. This is essentially a core feature of Maven, and 
> thus, I think it should be provided by a Maven plugin. (…snip…) It 
> just feels weird that Maven does not provide the required plugins 
> directly...
>
Alternatively, should we open the "multi-sources" discussion? We can 
leave apart all the aspects related to JPMS for now. Reminder: it is 
about changing the POM model for replacing:

    <build>
       <sourceDirectory>src/main/java</sourceDirectory>
    </build>

By something like below (the addition of "generated/main/java" is what 
build-helper-maven-plugin is used for):

    <build>
       <sources>
         <source>src/main/java</source>
         <source>generated/main/java</source>
       <sources>
    </build>

Additional attributes (release version, module name) may be added later, 
but I would like to avoid this debate for now. But if we add a "type" 
attribute now, the above proposal can actually replace all the following 
(from the current POM model):

    <build>
       <sourceDirectory>src/main/java</sourceDirectory>
       <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
       <testSourceDirectory>src/test/java</testSourceDirectory>
       <resources>
         <resource>
           <directory>src/main/resources</directory>
         </resource>
       </resources>
       <testResources>
         <testResource>
           <directory>src/test/resources</directory>
         </testResource>
       </testResources>
    </build>

By a more uniform pattern like below. Keep in mind that the core of this 
proposal is that all <source> elements are repeatable, not only the 
<resource> or <testResource> ones:

    <sources>
       <source  type="main">src/main/java</source>
       <source  type="script">src/main/scripts</source>
       <source  type="test">src/test/java</source>
       <source  type="resource">src/main/resources</source>
       <source  type="test-resource">src/test/resources</source>
    <sources>

     Martin


Re: [DISCUSS] Move some mojohaus plugins to the ASF

Posted by Grzegorz Grzybek <gr...@gmail.com>.
Hello

My 2¢. Big +1 for bringing in build-helper-maven-plugin under
org.apache.maven.plugins - its add-[test]-(re)source goals are really the
"core" of Maven. But also attach-artifact.

I don't quite like using attributes for configuration - these were
historically (at least since Maven 2) meta configuration (combine.children,
combine.self). And even if using elements is more verbose, verbosity is the
theme of Maven - some may don't like it but after working with Maven 2+ for
15+ years, it's the best way to ensure build safety and good maintenance.

Another plugin that I'd love to see under org.apache.maven.plugins is
versions-maven-plugin, so please consider it as well ;)

kind regards
Grzegorz Grzybek

pt., 12 lip 2024 o 21:20 Karl Heinz Marbaise <kh...@gmx.de.invalid>
napisał(a):

> Hi,
>
> good questions.
>
> On 12.07.24 15:53, Elliotte Rusty Harold wrote:
> > Meta-question: how do you plan to change group IDs and licenses?
> > Presumably everything would now be under the Apache license instead of
> > MIT or whatever they're currently using. I hope the licenses are all
> > compatible with this shift.
>
>
> First based on the licenses that is simply not possible, because it's a
> different license apart from the legal aspects(INAL!!) (in my opinion!).
> This would requires also to ask everyone of the committers (MojoHaus;
> and even contributors) if they agree on the license change... (INAL) but
> I doubt that this is even possible or practically will work...
>
> Furthermore we need to go through a ip-clearance (if I see it correctly)
> as we did with the resolver (aka aether)..
>
> My suggestions is to create new plugins (maven 4 based) with the
> functionality we need instead ... or integrate that into Maven core...
> instead...
>
>
> Kind regards
> Karl Heinz Marbaise
> >
> > Should the group IDs change too? Ideally they wouldn't, but we'd need
> > to make sure that the Apache project and the Maven PMC has the same
> > rights to publish the artifacts to Maven Central that they have for
> > current artifacts under org.apache. This shouldn't be tied to
> > individual developers.
> >
> > On Fri, Jul 12, 2024 at 9:27 AM Guillaume Nodet <gn...@apache.org>
> wrote:
> >>
> >> I've been working on migrating the build-helper-maven-plugin to the
> >> Maven 4.x API.
> >> The work is available at [1] (PR is red, but that's a CI configuration
> problem).
> >> While doing so, I've had a hard time figuring out why some plugins are
> >> hosted at the ASF while some others are hosted at MojoHaus.
> >> This plugin in particular is used a lot (to add generated
> >> source/resources and attach artifacts) and there's no other way to do
> >> it.  This is essentially a core feature of Maven, and thus, I think it
> >> should be provided by a Maven plugin.
> >> I've created a repo and migrated it at [2], but now raising the
> discussion...
> >>
> >> If that causes a problem, I think we should provide a new plugin with
> >> just those goals (add main/test source/resources directory, and attach
> >> artifact).
> >>
> >> It just feels weird that Maven does not provide the required plugins
> directly...
> >>
> >> That said, I think we have some old plugins that have not been
> >> released since nearly 10 years [3], probably indicating they are not
> >> used anymore: verifier, acr ?, jmod, changelog, changes, doap, jdeps,
> >> linkcheck, jarsigner, jdeprscan, patch, pdf, stage.
> >> I think those should be retired...
> >>
> >> [1] https://github.com/mojohaus/build-helper-maven-plugin/pull/215
> >> [2] https://github.com/apache/maven-build-helper-plugin
> >> [3] https://maven.apache.org/plugins/
> >>
> >> --
> >> ------------------------
> >> Guillaume Nodet
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> >> For additional commands, e-mail: dev-help@maven.apache.org
> >>
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>

Re: [DISCUSS] Move some mojohaus plugins to the ASF

Posted by Karl Heinz Marbaise <kh...@gmx.de.INVALID>.
Hi,

good questions.

On 12.07.24 15:53, Elliotte Rusty Harold wrote:
> Meta-question: how do you plan to change group IDs and licenses?
> Presumably everything would now be under the Apache license instead of
> MIT or whatever they're currently using. I hope the licenses are all
> compatible with this shift.


First based on the licenses that is simply not possible, because it's a
different license apart from the legal aspects(INAL!!) (in my opinion!).
This would requires also to ask everyone of the committers (MojoHaus;
and even contributors) if they agree on the license change... (INAL) but
I doubt that this is even possible or practically will work...

Furthermore we need to go through a ip-clearance (if I see it correctly)
as we did with the resolver (aka aether)..

My suggestions is to create new plugins (maven 4 based) with the
functionality we need instead ... or integrate that into Maven core...
instead...


Kind regards
Karl Heinz Marbaise
>
> Should the group IDs change too? Ideally they wouldn't, but we'd need
> to make sure that the Apache project and the Maven PMC has the same
> rights to publish the artifacts to Maven Central that they have for
> current artifacts under org.apache. This shouldn't be tied to
> individual developers.
>
> On Fri, Jul 12, 2024 at 9:27 AM Guillaume Nodet <gn...@apache.org> wrote:
>>
>> I've been working on migrating the build-helper-maven-plugin to the
>> Maven 4.x API.
>> The work is available at [1] (PR is red, but that's a CI configuration problem).
>> While doing so, I've had a hard time figuring out why some plugins are
>> hosted at the ASF while some others are hosted at MojoHaus.
>> This plugin in particular is used a lot (to add generated
>> source/resources and attach artifacts) and there's no other way to do
>> it.  This is essentially a core feature of Maven, and thus, I think it
>> should be provided by a Maven plugin.
>> I've created a repo and migrated it at [2], but now raising the discussion...
>>
>> If that causes a problem, I think we should provide a new plugin with
>> just those goals (add main/test source/resources directory, and attach
>> artifact).
>>
>> It just feels weird that Maven does not provide the required plugins directly...
>>
>> That said, I think we have some old plugins that have not been
>> released since nearly 10 years [3], probably indicating they are not
>> used anymore: verifier, acr ?, jmod, changelog, changes, doap, jdeps,
>> linkcheck, jarsigner, jdeprscan, patch, pdf, stage.
>> I think those should be retired...
>>
>> [1] https://github.com/mojohaus/build-helper-maven-plugin/pull/215
>> [2] https://github.com/apache/maven-build-helper-plugin
>> [3] https://maven.apache.org/plugins/
>>
>> --
>> ------------------------
>> Guillaume Nodet
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> For additional commands, e-mail: dev-help@maven.apache.org
>>
>


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


Re: [DISCUSS] Move some mojohaus plugins to the ASF

Posted by Elliotte Rusty Harold <el...@ibiblio.org>.
Meta-question: how do you plan to change group IDs and licenses?
Presumably everything would now be under the Apache license instead of
MIT or whatever they're currently using. I hope the licenses are all
compatible with this shift.

Should the group IDs change too? Ideally they wouldn't, but we'd need
to make sure that the Apache project and the Maven PMC has the same
rights to publish the artifacts to Maven Central that they have for
current artifacts under org.apache. This shouldn't be tied to
individual developers.

On Fri, Jul 12, 2024 at 9:27 AM Guillaume Nodet <gn...@apache.org> wrote:
>
> I've been working on migrating the build-helper-maven-plugin to the
> Maven 4.x API.
> The work is available at [1] (PR is red, but that's a CI configuration problem).
> While doing so, I've had a hard time figuring out why some plugins are
> hosted at the ASF while some others are hosted at MojoHaus.
> This plugin in particular is used a lot (to add generated
> source/resources and attach artifacts) and there's no other way to do
> it.  This is essentially a core feature of Maven, and thus, I think it
> should be provided by a Maven plugin.
> I've created a repo and migrated it at [2], but now raising the discussion...
>
> If that causes a problem, I think we should provide a new plugin with
> just those goals (add main/test source/resources directory, and attach
> artifact).
>
> It just feels weird that Maven does not provide the required plugins directly...
>
> That said, I think we have some old plugins that have not been
> released since nearly 10 years [3], probably indicating they are not
> used anymore: verifier, acr ?, jmod, changelog, changes, doap, jdeps,
> linkcheck, jarsigner, jdeprscan, patch, pdf, stage.
> I think those should be retired...
>
> [1] https://github.com/mojohaus/build-helper-maven-plugin/pull/215
> [2] https://github.com/apache/maven-build-helper-plugin
> [3] https://maven.apache.org/plugins/
>
> --
> ------------------------
> Guillaume Nodet
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>


-- 
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