Taking advantage of GitHub Integrations

71 views
Skip to first unread message

Aaron Cline

unread,
Feb 16, 2025, 12:39:53 PMFeb 16
to Repo and Gerrit Discussion
The company I'm at has used Gerrit for quite some time now.  We have a pretty large monorepo and Gerrit handles it pretty well. Upgrades of Gerrit are usually pretty painless.  Overall its a good experience.  It's a good experience right up until we want to make our lives easier with a SaaS tool that usually only wants to work with PRs from GitHub/Gitlab/etc.  

We currently replicate our repo to a git provider as a searchable backup.  On that sync'd copy I can see basically all of the regular activity from Gerrit.  Merges (we use the cherry pick merge), new refs for master show as branches, our branches, are all visible.  

Even with this it hasn't always worked for us to take advantage of some of the cool tools out there at work with these SaaS git solutions.  Especially those that work on PRs.  Does anyone have any pointers for integrating better with a git SaaS so that we can take advantage of all of the integrations with tools that this providers have?  I'm very curious to know how others have tackled this problem and looked to improve the tooling available to them while still using Gerrit as your primary review tool and source of truth.

Thank you.

Aaron

Michael Nazzareno Trimarchi

unread,
Feb 16, 2025, 1:16:08 PMFeb 16
to Aaron Cline, Repo and Gerrit Discussion
Hi


Il dom 16 feb 2025, 18:39 'Aaron Cline' via Repo and Gerrit Discussion <repo-d...@googlegroups.com> ha scritto:
The company I'm at has used Gerrit for quite some time now.  We have a pretty large monorepo and Gerrit handles it pretty well. Upgrades of Gerrit are usually pretty painless.  Overall its a good experience.  It's a good experience right up until we want to make our lives easier with a SaaS tool that usually only wants to work with PRs from GitHub/Gitlab/etc.  

We are using Gerrit as daily basis and gitea as mirror. For CI all our process uses Jenkins and publish results to Gerrit. We have pretty much covers already those kind of projects:

- mobile apps
- Linux os
- micro services application for embedded system
- iot

You can find more on wiki.amarulasolutions.com

Differently from others we just use scripted pipeline and groovy libraries that abstract pipeline logic complexity. All the heavy task are running on slave other sh contexts. 

We have an internal docker registry but we can use external docker image using on the fly overlay that allow debian image to be compatible to our infrastructure. All the components follow always latest release and we constantly update our services and rerun unit testing on our groovy libraries. Recently
I'm experimenting act to run GitHub workflow in Jenkins. I did not find anything on cloud that make me think to switch.

Michael 


We currently replicate our repo to a git provider as a searchable backup.  On that sync'd copy I can see basically all of the regular activity from Gerrit.  Merges (we use the cherry pick merge), new refs for master show as branches, our branches, are all visible.  

Even with this it hasn't always worked for us to take advantage of some of the cool tools out there at work with these SaaS git solutions.  Especially those that work on PRs.  Does anyone have any pointers for integrating better with a git SaaS so that we can take advantage of all of the integrations with tools that this providers have?  I'm very

curious to know how others have tackled this problem and looked to improve the tooling available to them while still using Gerrit as your primary review tool and source of truth.



Thank you.

Aaron

--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/repo-discuss/7f9d829e-6e41-427f-b940-fa5433a871aan%40googlegroups.com.

Daniele Sassoli

unread,
Feb 16, 2025, 4:27:18 PMFeb 16
to Repo and Gerrit Discussion
Hi Aaron,

On Sunday, 16 February 2025 at 10:16:08 UTC-8 mic...@amarulasolutions.com wrote:
Hi


Il dom 16 feb 2025, 18:39 'Aaron Cline' via Repo and Gerrit Discussion <repo-d...@googlegroups.com> ha scritto:
The company I'm at has used Gerrit for quite some time now.  We have a pretty large monorepo and Gerrit handles it pretty well. Upgrades of Gerrit are usually pretty painless.  Overall its a good experience.  It's a good experience right up until we want to make our lives easier with a SaaS tool that usually only wants to work with PRs from GitHub/Gitlab/etc.
 
have you tried the github plugin? Allows you to replicat from Gerrit to GitHub and then I assume you'd be able to use the integration you want?
See [1] for an example of integrating Gerrit with GitHub actions.

[1] https://www.youtube.com/watch?v=2B2PZTZlPJg&t=190s 

Andrew Grimberg

unread,
Feb 18, 2025, 6:06:13 PMFeb 18
to Daniele Sassoli, Repo and Gerrit Discussion
My team supports Gerrit systems that can use GitHub Actions as well as
accept GitHub PRs as Gerrit changes. The second of these is very much
still a beta but it's possible as long as the Gerrit system is publicly
accessible.

Gerrit -> GitHub is achieved with [0] and GitHub PR -> Gerrit is
achieved with a workflow that uses [1]

A working verification workflow on GitHub can be seen at [2]

Additional and more complex examples can be seen in [3] and [4] and a
working implementation of of the PR -> Gerrit workflow can be seen at [5]

[0] https://github.com/lfit/releng-gerrit_to_platform
[1] https://github.com/lfit/github2gerrit
[2]
https://github.com/lfit/releng-gerrit_to_platform/blob/main/.github/workflows/gerrit-verify.yaml
[3] https://github.com/onap/ci-management/tree/master/.github/workflows
[4] https://github.com/onap/.github/tree/main/.github/workflows
[5]
https://github.com/opendaylight/releng-builder/blob/master/.github/workflows/call-composed-github2gerrit.yaml

-Andy-

On 2/16/25 13:27, Daniele Sassoli wrote:
> Hi Aaron,
>
> On Sunday, 16 February 2025 at 10:16:08 UTC-8
> mic...@amarulasolutions.com wrote:
>
> Hi
>
>
> Il dom 16 feb 2025, 18:39 'Aaron Cline' via Repo and Gerrit
> Discussion <repo-d...@googlegroups.com> ha scritto:
>
> The company I'm at has used Gerrit for quite some time now.  We
> have a pretty large monorepo and Gerrit handles it pretty well.
> Upgrades of Gerrit are usually pretty painless.  Overall its a
> good experience.  It's a good experience right up until we want
> to make our lives easier with a SaaS tool that usually only
> wants to work with PRs from GitHub/Gitlab/etc.
>
> have you tried the github plugin? Allows you to replicat from Gerrit to
> GitHub and then I assume you'd be able to use the integration you want?
> See [1] for an example of integrating Gerrit with GitHub actions.
>
> [1] https://www.youtube.com/watch?v=2B2PZTZlPJg&t=190s
>
>
> We are using Gerrit as daily basis and gitea as mirror. For CI all
> our process uses Jenkins and publish results to Gerrit. We have
> pretty much covers already those kind of projects:
>
> - mobile apps
> - Linux os
> - micro services application for embedded system
> - iot
>
> You can find more on wiki.amarulasolutions.com <http://
> fa5433a871aan%40googlegroups.com <https://groups.google.com/d/
> msgid/repo-discuss/7f9d829e-6e41-427f-b940-
> fa5433a871aan%40googlegroups.com?
> utm_medium=email&utm_source=footer>.
>
> --
> --
> To unsubscribe, email repo-discuss...@googlegroups.com
> More info at http://groups.google.com/group/repo-discuss?hl=en <http://
> groups.google.com/group/repo-discuss?hl=en>
>
> ---
> You received this message because you are subscribed to the Google
> Groups "Repo and Gerrit Discussion" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to repo-discuss...@googlegroups.com <mailto:repo-
> discuss+u...@googlegroups.com>.
> To view this discussion visit https://groups.google.com/d/msgid/repo-
> discuss/4fb780fb-50e6-4b54-b264-33ab445eb1dbn%40googlegroups.com
> <https://groups.google.com/d/msgid/repo-discuss/4fb780fb-50e6-4b54-
> b264-33ab445eb1dbn%40googlegroups.com?utm_medium=email&utm_source=footer>.

Daniele Sassoli

unread,
Feb 18, 2025, 6:23:11 PMFeb 18
to Repo and Gerrit Discussion
Hi Andrew

On Tuesday, 18 February 2025 at 15:06:13 UTC-8 grim...@gmail.com wrote:
My team supports Gerrit systems that can use GitHub Actions as well as
accept GitHub PRs as Gerrit changes. The second of these is very much
still a beta but it's possible as long as the Gerrit system is publicly
accessible.

Gerrit -> GitHub is achieved with [0] and GitHub PR -> Gerrit is
achieved with a workflow that uses [1]

A working verification workflow on GitHub can be seen at [2]

Additional and more complex examples can be seen in [3] and [4] and a
working implementation of of the PR -> Gerrit workflow can be seen at [5]
 
Thanks for sharing these; actually really interesting, I didn't know any of these plugins existed.
I see you're the contributor/maintainer of quite a few of these, so I hope you don't mind me asking a few questions.

What made you want to create a Gerrit -> GitHub integration when one already exists? [6]

I also find it super interesting that you had a need for a GitHub -> Gerrit integration, I'll be keeping an eye out to see how this plugin evolves.

I see GitLab is still not supported, we had problems integrating with GitLab too, I wonder if we could get together separately and see if we faced
the same challenges?

I see `releng` is embedded in the name of these plugins, any reason why they can't be used outside the scope of the releng project?

Finally, I think we've now lost track of the initial question, if you already have all of these plugins in place, what is it that you're looking for? Maybe being
more specific about the tools you're looking to integrate could help us give you a better answer.

Thanks,
Dani

[6] https://gerrit.googlesource.com/plugins/github 

Andrew Grimberg

unread,
Feb 19, 2025, 9:33:02 AMFeb 19
to Daniele Sassoli, Repo and Gerrit Discussion
On 2/18/25 15:23, Daniele Sassoli wrote:

--[snip]--

> Thanks for sharing these; actually really interesting, I didn't know any
> of these plugins existed.
> I see you're the contributor/maintainer of quite a few of these, so I
> hope you don't mind me asking a few questions.
>
> What made you want to create a Gerrit -> GitHub integration when one
> already exists? [6]

The plugin you reference doesn't support the use case we have of wanting
to use GitHub Actions as a CI system. The GitHub -> GitHub workflow was
created to deal with the lack of an automated method for properly
getting PRs into Gerrit and keeping them in sync if the PR is updated.

> I also find it super interesting that you had a need for a GitHub ->
> Gerrit integration, I'll be keeping an eye out to see how this plugin
> evolves.
>
> I see GitLab is still not supported, we had problems integrating with
> GitLab too, I wonder if we could get together separately and see if we faced
> the same challenges?

We haven't implemented GitLab, though there's some stubs in place for
it. A few issues architecturally is that GitLab doesn't support multiple
different workflows, they all have to be in a single pipeline file
unlike GH Actions so it makes it more difficult to do some of what we're
doing with the gerrit_to_platform setup. Secondly, GitLab also doesn't
support dot repositories (ala .github) so it's less easy to create a
well known "magic" repo for top level "required" workflows like we do
with GitHub.

Finally, we don't currently have any projects that are mirroring to
GitLab so it hasn't been a focus of the Linux Foundation's Release
Engineering team (which I head).

> I see `releng` is embedded in the name of these plugins, any reason why
> they can't be used outside the scope of the releng project?

gerrit_to_platform itself is available on PyPi as gerrit_to_platform.
The releng-gerrit_to_platform in the GitHub repo name is a consequence
of our mirroring from our Gerrit system [7]. We wrote this for the vast
number of Gerrit systems we support that presently use Jenkins as their
primary CI but want to start using GitHub Actions. I had announced the
initial release of gerrit_to_platform a couple years ago on the list

> Finally, I think we've now lost track of the initial question, if you
> already have all of these plugins in place, what is it that you're
> looking for? Maybe being
> more specific about the tools you're looking to integrate could help us
> give you a better answer.

I wasn't looking for anything. I was just adding options to the thread
around the idea of taking advantage of GitHub integrations with
repositories on Gerrit. It's doable, but you semi-sorta need to use
something like the github-to-gerrit to get the PR into Gerrit and the GH
integrations themselves can still run on the PR.

-Andy-

[7] https://gerrit.linuxfoundation.org/infra

> Thanks,
> Dani
>
> [6] https://gerrit.googlesource.com/plugins/github
>
>
>
> [0] https://github.com/lfit/releng-gerrit_to_platform <https://
> github.com/lfit/releng-gerrit_to_platform>
> [1] https://github.com/lfit/github2gerrit <https://github.com/lfit/
> github2gerrit>
> [2]
> https://github.com/lfit/releng-gerrit_to_platform/blob/main/.github/
> workflows/gerrit-verify.yaml <https://github.com/lfit/releng-
> gerrit_to_platform/blob/main/.github/workflows/gerrit-verify.yaml>
> [3] https://github.com/onap/ci-management/tree/master/.github/
> workflows <https://github.com/onap/ci-management/tree/
> master/.github/workflows>
> [4] https://github.com/onap/.github/tree/main/.github/workflows
> <https://github.com/onap/.github/tree/main/.github/workflows>
> [5]
> https://github.com/opendaylight/releng-builder/blob/master/.github/
> workflows/call-composed-github2gerrit.yaml <https://github.com/
> opendaylight/releng-builder/blob/master/.github/workflows/call-
> composed-github2gerrit.yaml>
>
> -Andy-
>
> On 2/16/25 13:27, Daniele Sassoli wrote:
> > Hi Aaron,
> >
> > On Sunday, 16 February 2025 at 10:16:08 UTC-8
> > mic...@amarulasolutions.com wrote:
> >
> > Hi
> >
> >
> > Il dom 16 feb 2025, 18:39 'Aaron Cline' via Repo and Gerrit
> > Discussion <repo-d...@googlegroups.com> ha scritto:
> >
> > The company I'm at has used Gerrit for quite some time now.  We
> > have a pretty large monorepo and Gerrit handles it pretty well.
> > Upgrades of Gerrit are usually pretty painless.  Overall its a
> > good experience.  It's a good experience right up until we want
> > to make our lives easier with a SaaS tool that usually only
> > wants to work with PRs from GitHub/Gitlab/etc.
> >
> > have you tried the github plugin? Allows you to replicat from
> Gerrit to
> > GitHub and then I assume you'd be able to use the integration you
> want?
> > See [1] for an example of integrating Gerrit with GitHub actions.
> >
> > [1] https://www.youtube.com/watch?v=2B2PZTZlPJg&t=190s <https://
> www.youtube.com/watch?v=2B2PZTZlPJg&t=190s>
> >
> >
> > We are using Gerrit as daily basis and gitea as mirror. For CI all
> > our process uses Jenkins and publish results to Gerrit. We have
> > pretty much covers already those kind of projects:
> >
> > - mobile apps
> > - Linux os
> > - micro services application for embedded system
> > - iot
> >
> > You can find more on wiki.amarulasolutions.com <http://
> wiki.amarulasolutions.com> <http://
> > wiki.amarulasolutions.com <http://wiki.amarulasolutions.com>>
> > <http://groups.google.com/group/repo-discuss?hl=en <http://
> groups.google.com/group/repo-discuss?hl=en>>
> >
> > ---
> > You received this message because you are subscribed to the
> > Google Groups "Repo and Gerrit Discussion" group.
> > To unsubscribe from this group and stop receiving emails from
> > it, send an email to repo-discuss...@googlegroups.com.
> > To view this discussion visit https://groups.google.com/d/msgid/
> <https://groups.google.com/d/msgid/>
> > repo-discuss/7f9d829e-6e41-427f-b940-
> > fa5433a871aan%40googlegroups.com <http://40googlegroups.com>
> <https://groups.google.com/d/ <https://groups.google.com/d/>
> > msgid/repo-discuss/7f9d829e-6e41-427f-b940-
> > fa5433a871aan%40googlegroups.com <http://40googlegroups.com>?
> > utm_medium=email&utm_source=footer>.
> >
> > --
> > --
> > To unsubscribe, email repo-discuss...@googlegroups.com
> > More info at http://groups.google.com/group/repo-discuss?hl=en
> <http://groups.google.com/group/repo-discuss?hl=en> <http://
> > groups.google.com/group/repo-discuss?hl=en <http://
> groups.google.com/group/repo-discuss?hl=en>>
> >
> > ---
> > You received this message because you are subscribed to the Google
> > Groups "Repo and Gerrit Discussion" group.
> > To unsubscribe from this group and stop receiving emails from it,
> send
> > an email to repo-discuss...@googlegroups.com <mailto:repo-
> > discuss+u...@googlegroups.com>.
> > To view this discussion visit https://groups.google.com/d/msgid/
> repo- <https://groups.google.com/d/msgid/repo->
> > discuss/4fb780fb-50e6-4b54-b264-33ab445eb1dbn%40googlegroups.com
> <http://40googlegroups.com>
> > <https://groups.google.com/d/msgid/repo-
> discuss/4fb780fb-50e6-4b54- <https://groups.google.com/d/msgid/repo-
> discuss/4fb780fb-50e6-4b54->
> > b264-33ab445eb1dbn%40googlegroups.com?
> utm_medium=email&utm_source=footer <http://40googlegroups.com?
> utm_medium=email&utm_source=footer>>.
>
> --
> --
> To unsubscribe, email repo-discuss...@googlegroups.com
> More info at http://groups.google.com/group/repo-discuss?hl=en <http://
> groups.google.com/group/repo-discuss?hl=en>
>
> ---
> You received this message because you are subscribed to the Google
> Groups "Repo and Gerrit Discussion" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to repo-discuss...@googlegroups.com <mailto:repo-
> discuss+u...@googlegroups.com>.
> To view this discussion visit https://groups.google.com/d/msgid/repo-
> discuss/347eda27-2d59-4a45-aa3a-a1f4cad59ce2n%40googlegroups.com
> <https://groups.google.com/d/msgid/repo-discuss/347eda27-2d59-4a45-aa3a-
> a1f4cad59ce2n%40googlegroups.com?utm_medium=email&utm_source=footer>.

Reply all
Reply to author
Forward
0 new messages