Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

8324723: GHA: Upgrade some actions to avoid deprecated Node 16 #546

Closed
wants to merge 4 commits into from

Conversation

gdams
Copy link
Member

@gdams gdams commented Jul 12, 2024

This backport is written from scratch, as GHA workflows in jdk8u differ significantly from newer jdk versions.

This will remove all warnings about deprecated Node.js versions


Progress

  • Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • JDK-8324723 needs maintainer approval
  • JDK-8315863 needs maintainer approval
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue

Issues

  • JDK-8324723: GHA: Upgrade some actions to avoid deprecated Node 16 (Enhancement - P4 - Approved)
  • JDK-8315863: [GHA] Update checkout action to use v4 (Enhancement - P4 - Approved)

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk8u-dev.git pull/546/head:pull/546
$ git checkout pull/546

Update a local copy of the PR:
$ git checkout pull/546
$ git pull https://git.openjdk.org/jdk8u-dev.git pull/546/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 546

View PR using the GUI difftool:
$ git pr show -t 546

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk8u-dev/pull/546.diff

Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Jul 12, 2024

👋 Welcome back gdams! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@gdams
Copy link
Member Author

gdams commented Jul 12, 2024

/issue add 8315863

@openjdk
Copy link

openjdk bot commented Jul 12, 2024

@gdams This change now passes all automated pre-integration checks.

After integration, the commit message for the final commit will be:

8324723: GHA: Upgrade some actions to avoid deprecated Node 16
8315863: [GHA] Update checkout action to use v4

Reviewed-by: sgehwolf, zzambers
Backport-of: f2565a6c6f26e84d8e5eede39c0f3a50be5d579f

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 18 new commits pushed to the master branch:

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

As you do not have Committer status in this project an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@jerboaa, @zzambers) but any other Committer may sponsor as well.

➡️ To flag this PR as ready for integration with the above commit message, type /integrate in a new comment. (Afterwards, your sponsor types /sponsor in a new comment to perform the integration).

@openjdk openjdk bot changed the title Backport f2565a6c6f26e84d8e5eede39c0f3a50be5d579f 8324723: GHA: Upgrade some actions to avoid deprecated Node 16 Jul 12, 2024
@openjdk
Copy link

openjdk bot commented Jul 12, 2024

This backport pull request has now been updated with issue from the original commit.

@openjdk openjdk bot added the backport label Jul 12, 2024
@openjdk openjdk bot added the rfr Pull request is ready for review label Jul 12, 2024
@openjdk
Copy link

openjdk bot commented Jul 12, 2024

@gdams
Adding additional issue to issue list: 8315863: [GHA] Update checkout action to use v4.

@mlbridge
Copy link

mlbridge bot commented Jul 12, 2024

Webrevs

Copy link
Contributor

@jerboaa jerboaa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks for fixing.

@openjdk
Copy link

openjdk bot commented Jul 16, 2024

⚠️ @gdams This change is now ready for you to apply for maintainer approval. This can be done directly in each associated issue or by using the /approval command.

@zzambers
Copy link
Contributor

I remember I was looking a bit into this in the past. And there were some problems with actions/upload-artifact@v4, as there seem to be some braking change in v4 (from v3).

See errors in sumary (annotations):

Failed to CreateArtifact: Received non-retryable error: Failed request: (409) Conflict: an artifact with this name already exists on the workflow run

It seems to have effect on produced artifacts (bottom of the page), compare with e.g.:
https://github.com/zzambers/jdk8u-dev/actions/runs/9858657012

With existing actions it produces just one test-results artifact, which is relatively small (<200MiB), while with updated
actions there are some additional (leftover?) artifacts and test-results is huge (1.49GiB).

Looking at contents of test-results with updated actions, it's is wrong. It does not contain results of all tests, as it should, and wrongly contains built jdk binaries...

However I haven't looked into detail, why that is. Or how difficult would it be to fix this.

@zzambers
Copy link
Contributor

zzambers commented Jul 22, 2024

It seems, there were some significant changes in artifact actions v4. (causing compatibility problems with previous versions)

I took a deeper look and there are actually 2 issues here:

1. Upload of test results

  • artifact name is not specified (in upload-artifact) for test results uploads -> default artifact name ("artifact") is then used
  • upload-artifact v4 can no longer upload multiple times (append) to the same artifact -> error messages, missing archives with results
  • can be easily fixed by explicitly specifying artifact name for testresults

2. Artifact removal does not work

  • current code, to remove unnecessary artifacts, no longer works with artifacts uploaded by upload-artifact@v4
  • also affects newer jdks, I have crated bug and fix (see JDK-8336928)

@gdams
Copy link
Member Author

gdams commented Jul 30, 2024

  • JDK-8336928

Sorry for the delay, I've applied the fixes @zzambers

@zzambers
Copy link
Contributor

zzambers commented Jul 30, 2024

  • JDK-8336928

Sorry for the delay, I've applied the fixes @zzambers

Thanks, looks good. (no more problems with uploading archives with test results)

There should then be followup backport of JDK-8336928 to also fix problem with removing unnecessary artifacts (when uploaded by newer actions), but unfortunately, I am still waiting for review for that fix. :(

@gdams gdams requested a review from jerboaa July 30, 2024 12:35
@gdams
Copy link
Member Author

gdams commented Jul 30, 2024

@jerboaa I need to request another review please

.github/workflows/submit.yml Outdated Show resolved Hide resolved
Copy link
Contributor

@jerboaa jerboaa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems fine. I'll rely on @zzambers for checking this doesn't break any other things.

@gdams
Copy link
Member Author

gdams commented Aug 12, 2024

/approval request backport to dodge GHA dependencies deprecations. GHA works without problems in target repo.

@openjdk
Copy link

openjdk bot commented Aug 12, 2024

@gdams
8324723: The approval request has been created successfully.
8315863: The approval request has been created successfully.

@openjdk openjdk bot added the approval label Aug 12, 2024
@jerboaa
Copy link
Contributor

jerboaa commented Aug 13, 2024

/approve yes

@openjdk
Copy link

openjdk bot commented Aug 13, 2024

@jerboaa
8324723: The approval request has been approved.
8315863: The approval request has been approved.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Aug 13, 2024
@openjdk openjdk bot removed the approval label Aug 13, 2024
@gdams
Copy link
Member Author

gdams commented Aug 13, 2024

/integrate

@openjdk openjdk bot added the sponsor Pull request is ready to be sponsored label Aug 13, 2024
@openjdk
Copy link

openjdk bot commented Aug 13, 2024

@gdams
Your change (at version efe7e7a) is now ready to be sponsored by a Committer.

@gdams
Copy link
Member Author

gdams commented Aug 13, 2024

@gdams Your change (at version efe7e7a) is now ready to be sponsored by a Committer.

I am a committer 🤷🏼

/sponsor

@openjdk
Copy link

openjdk bot commented Aug 13, 2024

@gdams Only Committers are allowed to sponsor changes.

@gdams
Copy link
Member Author

gdams commented Aug 13, 2024

@gdams Only Committers are allowed to sponsor changes.

bot seems broken, @jerboaa would you mind doing the honours?

@jerboaa
Copy link
Contributor

jerboaa commented Aug 13, 2024

@gdams Only Committers are allowed to sponsor changes.

bot seems broken, @jerboaa would you mind doing the honours?

Looking at the census you'll find that you are an jdk-updates project committer. This is project JDK 8 Update Releases. So the bot has it correct. I'll sponsor it.

@jerboaa
Copy link
Contributor

jerboaa commented Aug 13, 2024

GHA failures are unrelated to this patch.

/sponsor

@openjdk
Copy link

openjdk bot commented Aug 13, 2024

Going to push as commit 047b08a.
Since your change was applied there have been 18 commits pushed to the master branch:

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated Pull request has been integrated label Aug 13, 2024
@openjdk openjdk bot closed this Aug 13, 2024
@openjdk openjdk bot removed ready Pull request is ready to be integrated rfr Pull request is ready for review sponsor Pull request is ready to be sponsored labels Aug 13, 2024
@openjdk
Copy link

openjdk bot commented Aug 13, 2024

@jerboaa @gdams Pushed as commit 047b08a.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@gdams gdams deleted the actions branch August 13, 2024 20:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport integrated Pull request has been integrated
Development

Successfully merging this pull request may close these issues.

3 participants