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 2021/10/07 17:41:41 UTC

Re: GitHub Actions on Maven projects

Ok,

if we want have to implement shared  Github Action  (I hope we do) I see
such steps:

- create repository for share / common GitHub Actions like
maven-jenkins-lib maybe: maven-actions-lib - I need help what issue should
be created for it
- prepare proposition for shared workflows  - I can try to do it
- use and test in some project
- propagate for other project after confirm

Now (at last) GitHub support shared workflows [1] [2] not only composite
action - it is something new, so we can start real shared workflows

[1]
https://github.blog/changelog/2021-10-05-github-actions-dry-your-github-actions-configuration-by-reusing-workflows/
[2]
https://docs.github.com/en/actions/learn-github-actions/reusing-workflows


niedz., 19 wrz 2021 o 21:49 Slawomir Jaranowski <s....@gmail.com>
napisał(a):

> Fo jlink on maven jenkins (a last log [1]) I don't see toolchains ... and
> on java 8 simple it tests are skipped ...
>
> Maybe instead complicate build configuration - drop unsupported java 8
> from matrix.
> I don't know this project, I may not see the reason for build it on java 8
> even then plugin require java 9+ for working
>
> I hope that most of projects can use common build steps. Of course we can
> prepare more than one build template.
>
>
> https://ci-maven.apache.org/job/Maven/job/maven-box/job/maven-jlink-plugin/job/master/112/execution/node/221/log/
>
> niedz., 19 wrz 2021 o 20:47 Benjamin Marwell <bm...@apache.org>
> napisał(a):
>
>> That won't work for all plugins.
>> The jlink plugin and others are using complicated setups so they can use
>> toolchains on GitHub Actions. It's a little bit complicated there because
>> the plugin does work with java 8 as long as a java 9+ is configured via
>> toolchains.
>>
>> Please make sure those actions continue to work.
>>
>>
>>
>>
>> On Sun, 19 Sep 2021, 20:22 Martin Kanters, <ma...@apache.org>
>> wrote:
>>
>> > Sounds like a great idea!
>> >
>> > Martin
>> >
>> > Op zo 19 sep. 2021 om 00:26 schreef Tamás Cservenák <
>> tamas@cservenak.net>:
>> >
>> > > +1 for global action
>> > >
>> > > T
>> > >
>> > > On Sat, Sep 18, 2021, 13:35 Slawomir Jaranowski <
>> s.jaranowski@gmail.com>
>> > > wrote:
>> > >
>> > > > Hi,
>> > > >
>> > > > Thanks for your response. I know that jenkins build is the master
>> for
>> > > > Apache projects,
>> > > > but most of the projects have some GA workflows configuration which
>> > many
>> > > > times are different.
>> > > > This situation generates more work for maintainer.
>> > > >
>> > > > Thanks to composite actions [1] we can create one global action
>> which
>> > has
>> > > > defined all required steps and one action for providing
>> configurations
>> > > > values like jkd list,
>> > > > both of these actions can be in one repository.
>> > > >
>> > > > In the rest of the project we can use those global actions, so when
>> > next
>> > > > time we want to change, e.g. jdk list (it changes every 6 month ;-)
>> )
>> > we
>> > > > only change it in one place.
>> > > > This approach can make less maintenance work in maven projects.
>> > > >
>> > > > If you are interested let me know, I can prepare some spikes for you
>> > and
>> > > > provide more details.
>> > > >
>> > > >
>> > > > [1]
>> > > >
>> > > >
>> > >
>> >
>> https://docs.github.com/en/actions/creating-actions/creating-a-composite-action
>> > > >
>> > > >
>> > > > sob., 18 wrz 2021 o 08:27 Martin Kanters <ma...@apache.org>
>> > > > napisał(a):
>> > > >
>> > > > > Hi Slawomir, sorry for the late reply.
>> > > > >
>> > > > > Great that you see the value of the workflows.
>> > > > > I don't think there are any strict rules or guidelines around how
>> the
>> > > > > workflow should be configured exactly, but I think it makes sense
>> to
>> > > have
>> > > > > them in place.
>> > > > > Perhaps we should also look into a way of reusing workflows in
>> all or
>> > > > most
>> > > > > of the projects (maven-core is a bit different).
>> > > > >
>> > > > > Just wanted to mention that for the Apache team the Apache Jenkins
>> > > server
>> > > > > is what matters most. GA are helpful for contributors and
>> committers
>> > > > > working via PRs, but in the end Apache Jenkins has to pass before
>> a
>> > > merge
>> > > > > is allowed. Hence, I think we should go for a reasonable workflow
>> > > > > configuration, it does not have to be more extensive than the
>> Jenkins
>> > > > > setup. Still, having macOS builds is very useful, Jenkins does not
>> > have
>> > > > > that AFAIK.
>> > > > >
>> > > > > Martin
>> > > > >
>> > > > >
>> > > > >
>> > > > >
>> > > > > Op za 11 sep. 2021 om 20:43 schreef Slawomir Jaranowski <
>> > > > > s.jaranowski@gmail.com>:
>> > > > >
>> > > > > > Hi,
>> > > > > >
>> > > > > > Many of maven, maven plugins projects have GutHub Action build
>> > > > > configured.
>> > > > > > It is very useful for contributors - we can verify PR early,
>> > > especially
>> > > > > on
>> > > > > > many different operating systems - which can't be done locally,
>> or
>> > is
>> > > > > more
>> > > > > > complicated.
>> > > > > >
>> > > > > > Most of workflows have define build matrix like:
>> > > > > >
>> > > > > >   matrix:
>> > > > > >         os: [ubuntu-latest, windows-latest, macOS-latest]
>> > > > > >         java: [8, 11, 16, 17-ea]
>> > > > > >
>> > > > > > But some have:
>> > > > > >
>> > > > > >   matrix:
>> > > > > >        os: [ubuntu-latest, windows-latest, macOS-latest]
>> > > > > >        java: [8, 11, 16, 17-ea]
>> > > > > >        jdk: [adopt, zulu]
>> > > > > >
>> > > > > >
>> > > > > > Question:
>> > > > > >
>> > > > > > Are there some guidelines about how GitHub Action should be
>> > > configured?
>> > > > > > If no guidelines, which build matrix will be the most expected?
>> > > > > >
>> > > > > >  I ask in conjunction to
>> > > > https://issues.apache.org/jira/browse/MDEP-768
>> > > > > >
>> > > > > >
>> > > > > > --
>> > > > > > Sławomir Jaranowski
>> > > > > >
>> > > > > > https://twitter.com/SlawekJaran
>> > > > > > https://github.com/slawekjaranowski
>> > > > > > https://linkedin.com/in/slawomirjaranowski
>> > > > > >
>> > > > >
>> > > >
>> > > >
>> > > > --
>> > > > Sławomir Jaranowski
>> > > >
>> > >
>> >
>>
>
>
> --
> Sławomir Jaranowski
>


-- 
Sławomir Jaranowski

Re: GitHub Actions on Maven projects

Posted by Gary Gregory <ga...@gmail.com>.
At first glance, I can't tell if my projects would benefit from this plugin
or not. It seems to me the readme assumes to much domain knowledge.

Gary

On Sun, Nov 7, 2021, 12:13 Slawomir Jaranowski <s....@gmail.com>
wrote:

> Hi,
>
> We have created maven-gh-actions-shared [1] with the first shared workflow.
> I hope that will be usable and help with less maintenance work.
>
> I'm starting to use this workflow in some of project [2]
>
> Lastly, what I think we need is a jira project to track changes.
>
> Thanks Olivier for supporting me.
>
> [1] https://github.com/apache/maven-gh-actions-shared
> [2]
>
> https://github.com/search?l=YAML&q=%22apache%2Fmaven-gh-actions-shared%2F%22&type=Code
>
>
> czw., 7 paź 2021 o 19:41 Slawomir Jaranowski <s....@gmail.com>
> napisał(a):
>
> > Ok,
> >
> > if we want have to implement shared  Github Action  (I hope we do) I see
> > such steps:
> >
> > - create repository for share / common GitHub Actions like
> > maven-jenkins-lib maybe: maven-actions-lib - I need help what issue
> should
> > be created for it
> > - prepare proposition for shared workflows  - I can try to do it
> > - use and test in some project
> > - propagate for other project after confirm
> >
> > Now (at last) GitHub support shared workflows [1] [2] not only composite
> > action - it is something new, so we can start real shared workflows
> >
> > [1]
> >
> https://github.blog/changelog/2021-10-05-github-actions-dry-your-github-actions-configuration-by-reusing-workflows/
> > [2]
> >
> https://docs.github.com/en/actions/learn-github-actions/reusing-workflows
> >
> >
> > niedz., 19 wrz 2021 o 21:49 Slawomir Jaranowski <s....@gmail.com>
> > napisał(a):
> >
> >> Fo jlink on maven jenkins (a last log [1]) I don't see toolchains ...
> and
> >> on java 8 simple it tests are skipped ...
> >>
> >> Maybe instead complicate build configuration - drop unsupported java 8
> >> from matrix.
> >> I don't know this project, I may not see the reason for build it on java
> >> 8 even then plugin require java 9+ for working
> >>
> >> I hope that most of projects can use common build steps. Of course we
> can
> >> prepare more than one build template.
> >>
> >>
> >>
> https://ci-maven.apache.org/job/Maven/job/maven-box/job/maven-jlink-plugin/job/master/112/execution/node/221/log/
> >>
> >> niedz., 19 wrz 2021 o 20:47 Benjamin Marwell <bm...@apache.org>
> >> napisał(a):
> >>
> >>> That won't work for all plugins.
> >>> The jlink plugin and others are using complicated setups so they can
> use
> >>> toolchains on GitHub Actions. It's a little bit complicated there
> because
> >>> the plugin does work with java 8 as long as a java 9+ is configured via
> >>> toolchains.
> >>>
> >>> Please make sure those actions continue to work.
> >>>
> >>>
> >>>
> >>>
> >>> On Sun, 19 Sep 2021, 20:22 Martin Kanters, <ma...@apache.org>
> >>> wrote:
> >>>
> >>> > Sounds like a great idea!
> >>> >
> >>> > Martin
> >>> >
> >>> > Op zo 19 sep. 2021 om 00:26 schreef Tamás Cservenák <
> >>> tamas@cservenak.net>:
> >>> >
> >>> > > +1 for global action
> >>> > >
> >>> > > T
> >>> > >
> >>> > > On Sat, Sep 18, 2021, 13:35 Slawomir Jaranowski <
> >>> s.jaranowski@gmail.com>
> >>> > > wrote:
> >>> > >
> >>> > > > Hi,
> >>> > > >
> >>> > > > Thanks for your response. I know that jenkins build is the master
> >>> for
> >>> > > > Apache projects,
> >>> > > > but most of the projects have some GA workflows configuration
> which
> >>> > many
> >>> > > > times are different.
> >>> > > > This situation generates more work for maintainer.
> >>> > > >
> >>> > > > Thanks to composite actions [1] we can create one global action
> >>> which
> >>> > has
> >>> > > > defined all required steps and one action for providing
> >>> configurations
> >>> > > > values like jkd list,
> >>> > > > both of these actions can be in one repository.
> >>> > > >
> >>> > > > In the rest of the project we can use those global actions, so
> when
> >>> > next
> >>> > > > time we want to change, e.g. jdk list (it changes every 6 month
> >>> ;-) )
> >>> > we
> >>> > > > only change it in one place.
> >>> > > > This approach can make less maintenance work in maven projects.
> >>> > > >
> >>> > > > If you are interested let me know, I can prepare some spikes for
> >>> you
> >>> > and
> >>> > > > provide more details.
> >>> > > >
> >>> > > >
> >>> > > > [1]
> >>> > > >
> >>> > > >
> >>> > >
> >>> >
> >>>
> https://docs.github.com/en/actions/creating-actions/creating-a-composite-action
> >>> > > >
> >>> > > >
> >>> > > > sob., 18 wrz 2021 o 08:27 Martin Kanters <
> martinkanters@apache.org
> >>> >
> >>> > > > napisał(a):
> >>> > > >
> >>> > > > > Hi Slawomir, sorry for the late reply.
> >>> > > > >
> >>> > > > > Great that you see the value of the workflows.
> >>> > > > > I don't think there are any strict rules or guidelines around
> >>> how the
> >>> > > > > workflow should be configured exactly, but I think it makes
> >>> sense to
> >>> > > have
> >>> > > > > them in place.
> >>> > > > > Perhaps we should also look into a way of reusing workflows in
> >>> all or
> >>> > > > most
> >>> > > > > of the projects (maven-core is a bit different).
> >>> > > > >
> >>> > > > > Just wanted to mention that for the Apache team the Apache
> >>> Jenkins
> >>> > > server
> >>> > > > > is what matters most. GA are helpful for contributors and
> >>> committers
> >>> > > > > working via PRs, but in the end Apache Jenkins has to pass
> >>> before a
> >>> > > merge
> >>> > > > > is allowed. Hence, I think we should go for a reasonable
> workflow
> >>> > > > > configuration, it does not have to be more extensive than the
> >>> Jenkins
> >>> > > > > setup. Still, having macOS builds is very useful, Jenkins does
> >>> not
> >>> > have
> >>> > > > > that AFAIK.
> >>> > > > >
> >>> > > > > Martin
> >>> > > > >
> >>> > > > >
> >>> > > > >
> >>> > > > >
> >>> > > > > Op za 11 sep. 2021 om 20:43 schreef Slawomir Jaranowski <
> >>> > > > > s.jaranowski@gmail.com>:
> >>> > > > >
> >>> > > > > > Hi,
> >>> > > > > >
> >>> > > > > > Many of maven, maven plugins projects have GutHub Action
> build
> >>> > > > > configured.
> >>> > > > > > It is very useful for contributors - we can verify PR early,
> >>> > > especially
> >>> > > > > on
> >>> > > > > > many different operating systems - which can't be done
> >>> locally, or
> >>> > is
> >>> > > > > more
> >>> > > > > > complicated.
> >>> > > > > >
> >>> > > > > > Most of workflows have define build matrix like:
> >>> > > > > >
> >>> > > > > >   matrix:
> >>> > > > > >         os: [ubuntu-latest, windows-latest, macOS-latest]
> >>> > > > > >         java: [8, 11, 16, 17-ea]
> >>> > > > > >
> >>> > > > > > But some have:
> >>> > > > > >
> >>> > > > > >   matrix:
> >>> > > > > >        os: [ubuntu-latest, windows-latest, macOS-latest]
> >>> > > > > >        java: [8, 11, 16, 17-ea]
> >>> > > > > >        jdk: [adopt, zulu]
> >>> > > > > >
> >>> > > > > >
> >>> > > > > > Question:
> >>> > > > > >
> >>> > > > > > Are there some guidelines about how GitHub Action should be
> >>> > > configured?
> >>> > > > > > If no guidelines, which build matrix will be the most
> expected?
> >>> > > > > >
> >>> > > > > >  I ask in conjunction to
> >>> > > > https://issues.apache.org/jira/browse/MDEP-768
> >>> > > > > >
> >>> > > > > >
> >>> > > > > > --
> >>> > > > > > Sławomir Jaranowski
> >>> > > > > >
> >>> > > > > > https://twitter.com/SlawekJaran
> >>> > > > > > https://github.com/slawekjaranowski
> >>> > > > > > https://linkedin.com/in/slawomirjaranowski
> >>> > > > > >
> >>> > > > >
> >>> > > >
> >>> > > >
> >>> > > > --
> >>> > > > Sławomir Jaranowski
> >>> > > >
> >>> > >
> >>> >
> >>>
> >>
> >>
> >> --
> >> Sławomir Jaranowski
> >>
> >
> >
> > --
> > Sławomir Jaranowski
> >
>
>
> --
> Sławomir Jaranowski
>

Re: GitHub Actions on Maven projects

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

We have created maven-gh-actions-shared [1] with the first shared workflow.
I hope that will be usable and help with less maintenance work.

I'm starting to use this workflow in some of project [2]

Lastly, what I think we need is a jira project to track changes.

Thanks Olivier for supporting me.

[1] https://github.com/apache/maven-gh-actions-shared
[2]
https://github.com/search?l=YAML&q=%22apache%2Fmaven-gh-actions-shared%2F%22&type=Code


czw., 7 paź 2021 o 19:41 Slawomir Jaranowski <s....@gmail.com>
napisał(a):

> Ok,
>
> if we want have to implement shared  Github Action  (I hope we do) I see
> such steps:
>
> - create repository for share / common GitHub Actions like
> maven-jenkins-lib maybe: maven-actions-lib - I need help what issue should
> be created for it
> - prepare proposition for shared workflows  - I can try to do it
> - use and test in some project
> - propagate for other project after confirm
>
> Now (at last) GitHub support shared workflows [1] [2] not only composite
> action - it is something new, so we can start real shared workflows
>
> [1]
> https://github.blog/changelog/2021-10-05-github-actions-dry-your-github-actions-configuration-by-reusing-workflows/
> [2]
> https://docs.github.com/en/actions/learn-github-actions/reusing-workflows
>
>
> niedz., 19 wrz 2021 o 21:49 Slawomir Jaranowski <s....@gmail.com>
> napisał(a):
>
>> Fo jlink on maven jenkins (a last log [1]) I don't see toolchains ... and
>> on java 8 simple it tests are skipped ...
>>
>> Maybe instead complicate build configuration - drop unsupported java 8
>> from matrix.
>> I don't know this project, I may not see the reason for build it on java
>> 8 even then plugin require java 9+ for working
>>
>> I hope that most of projects can use common build steps. Of course we can
>> prepare more than one build template.
>>
>>
>> https://ci-maven.apache.org/job/Maven/job/maven-box/job/maven-jlink-plugin/job/master/112/execution/node/221/log/
>>
>> niedz., 19 wrz 2021 o 20:47 Benjamin Marwell <bm...@apache.org>
>> napisał(a):
>>
>>> That won't work for all plugins.
>>> The jlink plugin and others are using complicated setups so they can use
>>> toolchains on GitHub Actions. It's a little bit complicated there because
>>> the plugin does work with java 8 as long as a java 9+ is configured via
>>> toolchains.
>>>
>>> Please make sure those actions continue to work.
>>>
>>>
>>>
>>>
>>> On Sun, 19 Sep 2021, 20:22 Martin Kanters, <ma...@apache.org>
>>> wrote:
>>>
>>> > Sounds like a great idea!
>>> >
>>> > Martin
>>> >
>>> > Op zo 19 sep. 2021 om 00:26 schreef Tamás Cservenák <
>>> tamas@cservenak.net>:
>>> >
>>> > > +1 for global action
>>> > >
>>> > > T
>>> > >
>>> > > On Sat, Sep 18, 2021, 13:35 Slawomir Jaranowski <
>>> s.jaranowski@gmail.com>
>>> > > wrote:
>>> > >
>>> > > > Hi,
>>> > > >
>>> > > > Thanks for your response. I know that jenkins build is the master
>>> for
>>> > > > Apache projects,
>>> > > > but most of the projects have some GA workflows configuration which
>>> > many
>>> > > > times are different.
>>> > > > This situation generates more work for maintainer.
>>> > > >
>>> > > > Thanks to composite actions [1] we can create one global action
>>> which
>>> > has
>>> > > > defined all required steps and one action for providing
>>> configurations
>>> > > > values like jkd list,
>>> > > > both of these actions can be in one repository.
>>> > > >
>>> > > > In the rest of the project we can use those global actions, so when
>>> > next
>>> > > > time we want to change, e.g. jdk list (it changes every 6 month
>>> ;-) )
>>> > we
>>> > > > only change it in one place.
>>> > > > This approach can make less maintenance work in maven projects.
>>> > > >
>>> > > > If you are interested let me know, I can prepare some spikes for
>>> you
>>> > and
>>> > > > provide more details.
>>> > > >
>>> > > >
>>> > > > [1]
>>> > > >
>>> > > >
>>> > >
>>> >
>>> https://docs.github.com/en/actions/creating-actions/creating-a-composite-action
>>> > > >
>>> > > >
>>> > > > sob., 18 wrz 2021 o 08:27 Martin Kanters <martinkanters@apache.org
>>> >
>>> > > > napisał(a):
>>> > > >
>>> > > > > Hi Slawomir, sorry for the late reply.
>>> > > > >
>>> > > > > Great that you see the value of the workflows.
>>> > > > > I don't think there are any strict rules or guidelines around
>>> how the
>>> > > > > workflow should be configured exactly, but I think it makes
>>> sense to
>>> > > have
>>> > > > > them in place.
>>> > > > > Perhaps we should also look into a way of reusing workflows in
>>> all or
>>> > > > most
>>> > > > > of the projects (maven-core is a bit different).
>>> > > > >
>>> > > > > Just wanted to mention that for the Apache team the Apache
>>> Jenkins
>>> > > server
>>> > > > > is what matters most. GA are helpful for contributors and
>>> committers
>>> > > > > working via PRs, but in the end Apache Jenkins has to pass
>>> before a
>>> > > merge
>>> > > > > is allowed. Hence, I think we should go for a reasonable workflow
>>> > > > > configuration, it does not have to be more extensive than the
>>> Jenkins
>>> > > > > setup. Still, having macOS builds is very useful, Jenkins does
>>> not
>>> > have
>>> > > > > that AFAIK.
>>> > > > >
>>> > > > > Martin
>>> > > > >
>>> > > > >
>>> > > > >
>>> > > > >
>>> > > > > Op za 11 sep. 2021 om 20:43 schreef Slawomir Jaranowski <
>>> > > > > s.jaranowski@gmail.com>:
>>> > > > >
>>> > > > > > Hi,
>>> > > > > >
>>> > > > > > Many of maven, maven plugins projects have GutHub Action build
>>> > > > > configured.
>>> > > > > > It is very useful for contributors - we can verify PR early,
>>> > > especially
>>> > > > > on
>>> > > > > > many different operating systems - which can't be done
>>> locally, or
>>> > is
>>> > > > > more
>>> > > > > > complicated.
>>> > > > > >
>>> > > > > > Most of workflows have define build matrix like:
>>> > > > > >
>>> > > > > >   matrix:
>>> > > > > >         os: [ubuntu-latest, windows-latest, macOS-latest]
>>> > > > > >         java: [8, 11, 16, 17-ea]
>>> > > > > >
>>> > > > > > But some have:
>>> > > > > >
>>> > > > > >   matrix:
>>> > > > > >        os: [ubuntu-latest, windows-latest, macOS-latest]
>>> > > > > >        java: [8, 11, 16, 17-ea]
>>> > > > > >        jdk: [adopt, zulu]
>>> > > > > >
>>> > > > > >
>>> > > > > > Question:
>>> > > > > >
>>> > > > > > Are there some guidelines about how GitHub Action should be
>>> > > configured?
>>> > > > > > If no guidelines, which build matrix will be the most expected?
>>> > > > > >
>>> > > > > >  I ask in conjunction to
>>> > > > https://issues.apache.org/jira/browse/MDEP-768
>>> > > > > >
>>> > > > > >
>>> > > > > > --
>>> > > > > > Sławomir Jaranowski
>>> > > > > >
>>> > > > > > https://twitter.com/SlawekJaran
>>> > > > > > https://github.com/slawekjaranowski
>>> > > > > > https://linkedin.com/in/slawomirjaranowski
>>> > > > > >
>>> > > > >
>>> > > >
>>> > > >
>>> > > > --
>>> > > > Sławomir Jaranowski
>>> > > >
>>> > >
>>> >
>>>
>>
>>
>> --
>> Sławomir Jaranowski
>>
>
>
> --
> Sławomir Jaranowski
>


-- 
Sławomir Jaranowski