Skip to content

Commit

Permalink
chore: use java 17 and 6G max heap on workflows (#524)
Browse files Browse the repository at this point in the history
### Summary

Newer versions of Android Gradle Plugin requires Java 17 to work. We
were using Java 11 on workflows. Upgraded them to use Java 17.
I've also noticed sometimes runners fails due to 2G max heap. I've set
max heap to 6G.

### Test plan

Android related CI needs to pass.
  • Loading branch information
atlj authored Feb 2, 2024
1 parent 62ef8c2 commit 3621257
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/build-templates.yml
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ jobs:
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '11'
java-version: '17'

- name: Finalize Android SDK
if: env.android_build == 1 && env.turbo_cache_hit_android != 1
Expand All @@ -226,6 +226,8 @@ jobs:
${{ runner.os }}-gradle-
- name: Build example (Android)
env:
JAVA_OPTS: "-XX:MaxHeapSize=6g"
if: env.android_build == 1
working-directory: ${{ env.work_dir }}
run: |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ jobs:
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '11'
java-version: '17'

- name: Finalize Android SDK
if: env.turbo_cache_hit != 1
Expand All @@ -99,6 +99,8 @@ jobs:
${{ runner.os }}-gradle-
- name: Build example for Android
env:
JAVA_OPTS: "-XX:MaxHeapSize=6g"
run: |
yarn turbo run build:android --cache-dir="${{ env.TURBO_CACHE_DIR }}"
Expand Down

0 comments on commit 3621257

Please sign in to comment.