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

Use a single definition of the supported JDK versions #715

Merged
merged 2 commits into from
Jan 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion .github/workflows/build-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,17 @@ jobs:
${{ env.docker_log_file_oss }}
${{ env.docker_log_file_ee }}

jdks:
uses: ./.github/workflows/get-supported-jdks.yaml

build-pr-custom-jdk:
runs-on: ubuntu-latest
needs: jdks
name: Build with jdk-${{ matrix.jdk }}
strategy:
fail-fast: false
matrix:
jdk: [ '17', '21' ]
jdk: ${{ fromJSON(needs.jdks.outputs.jdks) }}
steps:
- name: Checkout Code
uses: actions/checkout@v4
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/ee-nlc-snapshot-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,16 @@ env:
test_container_name_ee: hazelcast-ee-test

jobs:
jdks:
uses: ./.github/workflows/get-supported-jdks.yaml

push:
runs-on: ubuntu-latest
needs: jdks
strategy:
fail-fast: false
matrix:
jdk: [ '17', '21' ]
jdk: ${{ fromJSON(needs.jdks.outputs.jdks) }}
env:
HZ_VERSION : ${{ github.event.inputs.HZ_VERSION }}
NLC_REPOSITORY: ${{ secrets.NLC_REPOSITORY }}
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/ee-nlc-tag-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,16 @@ env:
test_container_name_ee: hazelcast-ee-test

jobs:
jdks:
uses: ./.github/workflows/get-supported-jdks.yaml

push:
runs-on: ubuntu-latest
needs: jdks
strategy:
fail-fast: false
matrix:
jdk: [ '17', '21' ]
jdk: ${{ fromJSON(needs.jdks.outputs.jdks) }}
env:
NLC_REPOSITORY: ${{ secrets.NLC_REPOSITORY }}
NLC_REPO_USERNAME: ${{ secrets.NLC_REPO_USERNAME }}
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/ee_latest_snapshot_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,15 @@ env:
test_container_name_ee: hazelcast-ee-test

jobs:
jdks:
uses: ./.github/workflows/get-supported-jdks.yaml

push:
runs-on: ubuntu-latest
needs: jdks
strategy:
matrix:
jdk: [ '17', '21' ]
jdk: ${{ fromJSON(needs.jdks.outputs.jdks) }}
variant: [ 'slim','' ]
include:
- variant: slim
Expand Down
15 changes: 15 additions & 0 deletions .github/workflows/get-supported-jdks.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Get supported JDKs

on:
workflow_call:
outputs:
jdks:
value: ${{ jobs.get-supported-jdks.outputs.jdks }}

jobs:
get-supported-jdks:
runs-on: ubuntu-latest
outputs:
jdks: "['17', '21']"
steps:
- run: exit 0
6 changes: 5 additions & 1 deletion .github/workflows/oss_latest_snapshot_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,16 @@ env:
test_container_name_oss: hazelcast-oss-test

jobs:
jdks:
uses: ./.github/workflows/get-supported-jdks.yaml

push:
runs-on: ubuntu-latest
needs: jdks
strategy:
fail-fast: false
matrix:
jdk: [ '17', '21' ]
jdk: ${{ fromJSON(needs.jdks.outputs.jdks) }}
variant: [ 'slim','' ]
include:
- variant: slim
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/tag_image_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,15 @@ env:
test_container_name_ee: hazelcast-ee-test

jobs:
jdks:
uses: ./.github/workflows/get-supported-jdks.yaml

push:
runs-on: ubuntu-latest
needs: jdks
strategy:
matrix:
jdk: [ '17', '21' ]
jdk: ${{ fromJSON(needs.jdks.outputs.jdks) }}
variant: [ 'slim','' ]
include:
- variant: slim
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/tag_image_push_rhel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ on:
description: 'Version of the docker image e.g. 5.1.1, 5.1.1-1, defaults to HZ_VERSION'
required: false
jobs:
jdks:
uses: ./.github/workflows/get-supported-jdks.yaml

build:
defaults:
run:
Expand All @@ -34,10 +37,11 @@ jobs:
PROJECT_NAME: test-${{ github.run_id }}-${{ github.run_attempt }}-${{ matrix.jdk }}

runs-on: ubuntu-latest
needs: jdks
strategy:
fail-fast: false
matrix:
jdk: [ '17', '21' ]
jdk: ${{ fromJSON(needs.jdks.outputs.jdks) }}
steps:
- name: Set HZ version as environment variable
run: |
Expand Down