Skip to content

Commit

Permalink
CI: Add concurrency to CI-Mac/Win + newer-Java workflows (#7785)
Browse files Browse the repository at this point in the history
  • Loading branch information
snazy authored Dec 1, 2023
1 parent 26cb495 commit 931e937
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 1 deletion.
10 changes: 10 additions & 0 deletions .github/workflows/ci-mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,16 @@ on:
- cron: '0 4 * * 1-5'
workflow_dispatch:

# For the main branch: let all CI runs complete, one after the other. This has a couple advantages:
# * Site deployments happen in commit-order
# * Saved Gradle cache are persisted in commit-order
# * (Potentially) more GH runners available for PRs
concurrency:
# PRs: 1 CI run concurrently / older ones are cancelled
# main branch: 1 CI run concurrently / all commits / no cancellation
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}

jobs:
java:
name: Java/Gradle macOS
Expand Down
10 changes: 10 additions & 0 deletions .github/workflows/ci-win.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,16 @@ on:
- cron: '0 4 * * 1-5'
workflow_dispatch:

# For the main branch: let all CI runs complete, one after the other. This has a couple advantages:
# * Site deployments happen in commit-order
# * Saved Gradle cache are persisted in commit-order
# * (Potentially) more GH runners available for PRs
concurrency:
# PRs: 1 CI run concurrently / older ones are cancelled
# main branch: 1 CI run concurrently / all commits / no cancellation
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}

jobs:
java:
name: Java/Gradle Windows
Expand Down
11 changes: 10 additions & 1 deletion .github/workflows/newer-java.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,16 @@ on:
- cron: '0 4 * * 1-5'
workflow_dispatch:

# For the main branch: let all CI runs complete, one after the other. This has a couple advantages:
# * Site deployments happen in commit-order
# * Saved Gradle cache are persisted in commit-order
# * (Potentially) more GH runners available for PRs
concurrency:
# PRs: 1 CI run concurrently / older ones are cancelled
# main branch: 1 CI run concurrently / all commits / no cancellation
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}

jobs:
java:
name: Exercise Java version
Expand All @@ -17,7 +27,6 @@ jobs:
max-parallel: 1
matrix:
include:
- java-version: 17
- java-version: 21
env:
SPARK_LOCAL_IP: localhost
Expand Down

0 comments on commit 931e937

Please sign in to comment.