[
https://issues.apache.org/jira/browse/FLINK-27075?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18095329#comment-18095329
]
Dale Lane commented on FLINK-27075:
-----------------------------------
[~mapohl] asked me to have a look at the current state of the Azure Pipeline
(AZP) and Github Actions (GHA) pipeline setup to see how close they are, and
what still needs doing to close out the migration that was started here. I'll
put an update here so it's visible to anyone else who is interested or
following.
They're very close and most things I checked line up identically already.
I found a few loose ends that I think are worth tweaking to get the Github
Actions pipeline setup more closely in line with the Azure setup, but I'm new
to both Azure pipelines and Github Actions so I'd like a sanity check that I'm
on the right track, please!
I've created some draft pull requests on my personal fork to show what I'm
thinking. If the general approach looks right, I'll tidy them up and open PRs
upstream for a proper review. A high-level "generally on the right track" steer
would be enough at this stage.
.
There are two things I found present in the AZP pipelines that seem to be
missing from the GHA setup:
*1.* The Azure pipeline has a baseline nightly build, with no logical
equivalent I could find in the Github Actions nightly build. I suggest adding
that, to bring them into parity.
Draft PR (on my personal fork - meant to be illustrative only):
[https://github.com/dalelane/flink/pull/3] - includes a link to a successful
Github Actions run
*2.* The Azure pipeline has a "docs_404_check" CI job that checks the docs site
is still build-able. The Github Actions workflows do have a workflow to build
the docs site, but it isn't run as part of CI. I suggest adding that, again
with the goal of getting GHA into parity with what's in AZP.
Draft PR (personal fork, illustrative):
[https://github.com/dalelane/flink/pull/2] - includes link to successful Github
Actions run
There are also some cleanup and improvement things I found that I think are
worth doing
*3.* The GHA pipelines reuse some scripts from `tools/azure-pipelines`. In the
interest of parity, that's great, but I think it's worth a small refactor to
move the ones that are no longer AZP-specific into `tools/ci` to reflect that
they're now shared, rather than AZP-only.
Draft PR: [https://github.com/dalelane/flink/pull/4] - with a link to an AZP
run to show doing this won't break the AZP pipeline
*4.* The AZP nightly build's reuse of the `create_binary_release.sh` script
(which I _think_ was written for the manual formal release process?) confused
me at first. The nightly build only seems to need some of it, and is ignoring
the error when the rest of it fails. I suggest tidying it up to make it
explicit what the nightly build actually needs, so we can start checking the
error code for failures that are actually unexpected. I included an example of
that in
[https://github.com/dalelane/flink/pull/1/changes/4576bba8d555b35c631ac8de47ee75e465b587dc]
Finally, there is the question of how to handle nightly snapshot releases,
which needs agreement on the general approach more than the specific
implementation:
*5.* The nightly scheduled AZP pipeline creates release binaries it uploads to
S3, and jars it pushes to Maven. Before we could migrate off of AZP, we would
need an equivalent nightly scheduled job in GHA. I have an example of this in
[https://github.com/dalelane/flink/pull/1/changes/e21cb564418c75eb6eb7c2e76ab2c385c45d31c9]
Draft PR (personal fork, illustrative):
[https://github.com/dalelane/flink/pull/1] - with link to a Github Actions run
I assume that we'll want to run AZP and GHA pipelines in parallel for a while,
so we can compare the nightly release builds. They can't both write binaries to
the same S3 destination without the second pipeline to run overwriting the
output from the first. To that end, I configured the GHA pipeline to upload the
binary artefacts to a "gha-trial" subfolder in the same bucket. This would give
us two copies of everything in S3, so we can compare them to validate the GHA
pipeline is truly at parity with the existing AZP one.
The way I did that is in
[https://github.com/dalelane/flink/pull/1/changes/f0aa4f6d23f768845a76e719a6e452df0fe8e86e]
I haven't done this for the nightly Maven snapshots, as they're timestamped and
can safely run in parallel.
Once all of the above is in place, I think we'd be ready to start comparing the
output from the AZP and GHA nightly and CI pipelines.
I suggest that to start with, I could do this manually - diffing the output
from a sampling of both pipelines over a series of days. I'm open to debate if
people feel a more automated check is needed, though.
*Next steps?* At a high-level, does this sound like the right direction? Any
objections to some/all of these being tidied up and prepared as proper upstream
pull-requests?
_Apologies for the over-long braindump - this has been lurking at the back of
my brain for a week now, so wanted to get it all written down!_
> Migrate CI from Azure to Github Actions
> ---------------------------------------
>
> Key: FLINK-27075
> URL: https://issues.apache.org/jira/browse/FLINK-27075
> Project: Flink
> Issue Type: Technical Debt
> Components: Build System / CI
> Reporter: Chesnay Schepler
> Assignee: Chesnay Schepler
> Priority: Major
> Labels: github-actions
>
> Current base commit:
> [master@011b6b44|https://github.com/apache/flink/commit/011b6b44] ([related
> AzureCI|https://dev.azure.com/apache-flink/apache-flink/_build/results?buildId=53624&view=logs&j=52b61abe-a3cc-5bde-cc35-1bbe89bb7df5&t=54421a62-0c80-5aad-3319-094ff69180bb&l=43193])
--
This message was sent by Atlassian Jira
(v8.20.10#820010)