Skip to content

Commit e3e2076

Browse files
committed
ci: use ubuntu-arm on every PR/push, use macos at night
* Gives us a 10 minute CI system * Expand test coverage to "arm on linux", which is a real use-case * Replaces slowest runner (20 minutes) with fastest runner (5 minutes) * Still tests with macos-arm at night * Policeman Jenkins still tests macos many times a day (and more reliably)
1 parent c67f8d3 commit e3e2076

File tree

2 files changed

+57
-9
lines changed

2 files changed

+57
-9
lines changed

.github/workflows/run-checks-all.yml

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ jobs:
6969
strategy:
7070
matrix:
7171
# Operating systems to run on.
72-
os: [ ubuntu-latest, windows-latest, macos-latest ]
72+
os: [ ubuntu-latest, ubuntu-24.04-arm, windows-latest ]
7373
java: [ '25' ]
7474

7575
runs-on: ${{ matrix.os }}
@@ -87,14 +87,6 @@ jobs:
8787
- name: Configure tools
8888
uses: ./.github/actions/prepare-for-build
8989

90-
- name: Speedup MacOS runner
91-
if: ${{ runner.os == 'macOS' }}
92-
run: |
93-
mkdir /tmp/tmpfs
94-
sudo mount_tmpfs -o noowners -s 1g /tmp/tmpfs
95-
sudo sysctl debug.lowpri_throttle_enabled=0
96-
echo "tests.workDir=/tmp/tmpfs/lucene" >> build-options.local.properties
97-
9890
- name: Run gradle tests
9991
run: ./gradlew test "-Ptask.times=true" "-Pvalidation.errorprone=false"
10092
env:
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
name: "Run checks on MacOS: all modules"
2+
3+
on:
4+
workflow_dispatch:
5+
schedule:
6+
- cron: '44 1 * * *'
7+
8+
permissions: {}
9+
10+
env:
11+
DEVELOCITY_ACCESS_KEY: ${{ secrets.DEVELOCITY_ACCESS_KEY }}
12+
13+
# We split the workflow into two parallel jobs for efficiency:
14+
# one is running all validation checks without tests,
15+
# the other runs all tests without other validation checks.
16+
17+
jobs:
18+
# This runs all tests without any other validation checks.
19+
tests:
20+
name: tests (JDK ${{ matrix.java }} on ${{ matrix.os }})
21+
timeout-minutes: 30
22+
23+
strategy:
24+
matrix:
25+
# Operating systems to run on.
26+
os: [ macos-latest ]
27+
java: [ '25' ]
28+
29+
runs-on: ${{ matrix.os }}
30+
31+
steps:
32+
- name: Checkout repository
33+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
34+
with:
35+
persist-credentials: false
36+
37+
- name: Configure tools
38+
uses: ./.github/actions/prepare-for-build
39+
40+
- name: Speedup MacOS runner
41+
if: ${{ runner.os == 'macOS' }}
42+
run: |
43+
mkdir /tmp/tmpfs
44+
sudo mount_tmpfs -o noowners -s 1g /tmp/tmpfs
45+
sudo sysctl debug.lowpri_throttle_enabled=0
46+
echo "tests.workDir=/tmp/tmpfs/lucene" >> build-options.local.properties
47+
48+
- name: Run gradle tests
49+
run: ./gradlew test "-Ptask.times=true" "-Pvalidation.errorprone=false"
50+
env:
51+
# Set to the defaults to override the "CI"-based logic that would enable C2
52+
# we can't afford C2 on github runners.
53+
TEST_JVM_ARGS: "-XX:TieredStopAtLevel=1 -XX:+UseParallelGC -XX:ActiveProcessorCount=1"
54+
55+
- name: List automatically-initialized gradle.properties
56+
run: cat gradle.properties

0 commit comments

Comments
 (0)