Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
8284389: Improve stability of GHA Pre-submit testing by caching cygwi…
…n installer

Reviewed-by: shade
  • Loading branch information
RealCLanger committed Apr 7, 2022
1 parent d5cd4a3 commit 61fcf2f
Showing 1 changed file with 39 additions and 6 deletions.
45 changes: 39 additions & 6 deletions .github/workflows/submit.yml
Expand Up @@ -894,6 +894,19 @@ jobs:
BOOT_JDK_SHA256: "${{ fromJson(needs.prerequisites.outputs.dependencies).WINDOWS_X64_BOOT_JDK_SHA256 }}"

steps:
- name: Restore cygwin installer from cache
id: cygwin-installer
uses: actions/cache@v2
with:
path: ~/cygwin/setup-x86_64.exe
key: cygwin-installer

- name: Download cygwin installer
run: |
New-Item -Force -ItemType directory -Path "$HOME\cygwin"
& curl -L "https://www.cygwin.com/setup-x86_64.exe" -o "$HOME/cygwin/setup-x86_64.exe"
if: steps.cygwin-installer.outputs.cache-hit != 'true'

- name: Restore cygwin packages from cache
id: cygwin
uses: actions/cache@v2
Expand All @@ -903,8 +916,6 @@ jobs:

- name: Install cygwin
run: |
New-Item -Force -ItemType directory -Path "$HOME\cygwin"
& curl -L "https://www.cygwin.com/setup-x86_64.exe" -o "$HOME/cygwin/setup-x86_64.exe"
Start-Process -FilePath "$HOME\cygwin\setup-x86_64.exe" -ArgumentList "--quiet-mode --packages cygwin=3.2.0-1,autoconf,make,zip,unzip --root $HOME\cygwin\cygwin64 --local-package-dir $HOME\cygwin\packages --site http://mirrors.kernel.org/sourceware/cygwin --no-desktop --no-shortcuts --no-startmenu --no-admin" -Wait -NoNewWindow
- name: Checkout the source
Expand Down Expand Up @@ -982,6 +993,19 @@ jobs:
BOOT_JDK_SHA256: "${{ fromJson(needs.prerequisites.outputs.dependencies).WINDOWS_X64_BOOT_JDK_SHA256 }}"

steps:
- name: Restore cygwin installer from cache
id: cygwin-installer
uses: actions/cache@v2
with:
path: ~/cygwin/setup-x86_64.exe
key: cygwin-installer

- name: Download cygwin installer
run: |
New-Item -Force -ItemType directory -Path "$HOME\cygwin"
& curl -L "https://www.cygwin.com/setup-x86_64.exe" -o "$HOME/cygwin/setup-x86_64.exe"
if: steps.cygwin-installer.outputs.cache-hit != 'true'

- name: Restore cygwin packages from cache
id: cygwin
uses: actions/cache@v2
Expand All @@ -991,8 +1015,6 @@ jobs:

- name: Install cygwin
run: |
New-Item -Force -ItemType directory -Path "$HOME\cygwin"
& curl -L "https://www.cygwin.com/setup-x86_64.exe" -o "$HOME/cygwin/setup-x86_64.exe"
Start-Process -FilePath "$HOME\cygwin\setup-x86_64.exe" -ArgumentList "--quiet-mode --packages cygwin=3.2.0-1,autoconf,make,zip,unzip --root $HOME\cygwin\cygwin64 --local-package-dir $HOME\cygwin\packages --site http://mirrors.kernel.org/sourceware/cygwin --no-desktop --no-shortcuts --no-startmenu --no-admin" -Wait -NoNewWindow
- name: Checkout the source
Expand Down Expand Up @@ -1153,6 +1175,19 @@ jobs:
Get-ChildItem "$HOME\bootjdk\$env:BOOT_JDK_VERSION\*\*" | Move-Item -Destination "$HOME\bootjdk\$env:BOOT_JDK_VERSION"
if: steps.bootjdk.outputs.cache-hit != 'true'

- name: Restore cygwin installer from cache
id: cygwin-installer
uses: actions/cache@v2
with:
path: ~/cygwin/setup-x86_64.exe
key: cygwin-installer

- name: Download cygwin installer
run: |
New-Item -Force -ItemType directory -Path "$HOME\cygwin"
& curl -L "https://www.cygwin.com/setup-x86_64.exe" -o "$HOME/cygwin/setup-x86_64.exe"
if: steps.cygwin-installer.outputs.cache-hit != 'true'

- name: Restore cygwin packages from cache
id: cygwin
uses: actions/cache@v2
Expand All @@ -1162,8 +1197,6 @@ jobs:

- name: Install cygwin
run: |
New-Item -Force -ItemType directory -Path "$HOME\cygwin"
& curl -L "https://www.cygwin.com/setup-x86_64.exe" -o "$HOME/cygwin/setup-x86_64.exe"
Start-Process -FilePath "$HOME\cygwin\setup-x86_64.exe" -ArgumentList "--quiet-mode --packages cygwin=3.2.0-1,autoconf,make,zip,unzip --root $HOME\cygwin\cygwin64 --local-package-dir $HOME\cygwin\packages --site http://mirrors.kernel.org/sourceware/cygwin --no-desktop --no-shortcuts --no-startmenu --no-admin" -Wait -NoNewWindow
- name: Restore jtreg artifact
Expand Down

7 comments on commit 61fcf2f

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

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

@RealCLanger
Copy link
Contributor Author

Choose a reason for hiding this comment

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

/backport jdk18u

@openjdk
Copy link

@openjdk openjdk bot commented on 61fcf2f Apr 7, 2022

Choose a reason for hiding this comment

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

@RealCLanger the backport was successfully created on the branch RealCLanger-backport-61fcf2f6 in my personal fork of openjdk/jdk18u. To create a pull request with this backport targeting openjdk/jdk18u:master, just click the following link:

➡️ Create pull request

The title of the pull request is automatically filled in correctly and below you find a suggestion for the pull request body:

Hi all,

This pull request contains a backport of commit 61fcf2f6 from the openjdk/jdk repository.

The commit being backported was authored by Christoph Langer on 7 Apr 2022 and was reviewed by Aleksey Shipilev.

Thanks!

If you need to update the source branch of the pull then run the following commands in a local clone of your personal fork of openjdk/jdk18u:

$ git fetch https://github.com/openjdk-bots/jdk18u RealCLanger-backport-61fcf2f6:RealCLanger-backport-61fcf2f6
$ git checkout RealCLanger-backport-61fcf2f6
# make changes
$ git add paths/to/changed/files
$ git commit --message 'Describe additional changes made'
$ git push https://github.com/openjdk-bots/jdk18u RealCLanger-backport-61fcf2f6

@RealCLanger
Copy link
Contributor Author

Choose a reason for hiding this comment

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

/backport jdk17u-dev

@openjdk
Copy link

@openjdk openjdk bot commented on 61fcf2f Apr 7, 2022

Choose a reason for hiding this comment

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

@RealCLanger the backport was successfully created on the branch RealCLanger-backport-61fcf2f6 in my personal fork of openjdk/jdk17u-dev. To create a pull request with this backport targeting openjdk/jdk17u-dev:master, just click the following link:

➡️ Create pull request

The title of the pull request is automatically filled in correctly and below you find a suggestion for the pull request body:

Hi all,

This pull request contains a backport of commit 61fcf2f6 from the openjdk/jdk repository.

The commit being backported was authored by Christoph Langer on 7 Apr 2022 and was reviewed by Aleksey Shipilev.

Thanks!

If you need to update the source branch of the pull then run the following commands in a local clone of your personal fork of openjdk/jdk17u-dev:

$ git fetch https://github.com/openjdk-bots/jdk17u-dev RealCLanger-backport-61fcf2f6:RealCLanger-backport-61fcf2f6
$ git checkout RealCLanger-backport-61fcf2f6
# make changes
$ git add paths/to/changed/files
$ git commit --message 'Describe additional changes made'
$ git push https://github.com/openjdk-bots/jdk17u-dev RealCLanger-backport-61fcf2f6

@RealCLanger
Copy link
Contributor Author

Choose a reason for hiding this comment

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

/backport jdk11u-dev

@openjdk
Copy link

@openjdk openjdk bot commented on 61fcf2f Apr 7, 2022

Choose a reason for hiding this comment

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

@RealCLanger Could not automatically backport 61fcf2f6 to openjdk/jdk11u-dev due to conflicts in the following files:

  • .github/workflows/submit.yml

To manually resolve these conflicts run the following commands in your personal fork of openjdk/jdk11u-dev:

$ git checkout -b RealCLanger-backport-61fcf2f6
$ git fetch --no-tags https://git.openjdk.java.net/jdk 61fcf2f67ff16bee92a5279e7bcacc79fc8f37ad
$ git cherry-pick --no-commit 61fcf2f67ff16bee92a5279e7bcacc79fc8f37ad
$ # Resolve conflicts
$ git add files/with/resolved/conflicts
$ git commit -m 'Backport 61fcf2f67ff16bee92a5279e7bcacc79fc8f37ad'

Once you have resolved the conflicts as explained above continue with creating a pull request towards the openjdk/jdk11u-dev with the title Backport 61fcf2f67ff16bee92a5279e7bcacc79fc8f37ad.

Please sign in to comment.