-
Notifications
You must be signed in to change notification settings - Fork 106
77 lines (65 loc) · 2.45 KB
/
test-java.yml
File metadata and controls
77 lines (65 loc) · 2.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
name: Test Java Sources
on:
workflow_call:
env:
RUSTC_WRAPPER: sccache
SCCACHE_CACHE_SIZE: ${{ vars.SCCACHE_CACHE_SIZE }}
SCCACHE_BUCKET: ${{ vars.SCCACHE_BUCKET }}
SCCACHE_ENDPOINT: ${{ vars.SCCACHE_ENDPOINT }}
SCCACHE_REGION: ${{ vars.SCCACHE_REGION }}
AWS_ACCESS_KEY_ID: "${{ secrets.CI_K8S_MINIO_ACCESS_KEY_ID }}"
AWS_SECRET_ACCESS_KEY: "${{ secrets.CI_K8S_MINIO_SECRET_ACCESS_KEY }}"
RUST_MIN_STACK: 8388608
# Limit number of parallel build jobs to avoid OOM in arm64 CI runners
CARGO_BUILD_JOBS: 24
jobs:
java-tests:
if: ${{ !contains(vars.CI_SKIP_JOBS, 'java-tests') }}
name: Execute Java Tests
strategy:
matrix:
include:
- runner: [k8s-runners-amd64]
- runner: [k8s-runners-arm64]
runs-on: ${{ matrix.runner }}
container:
image: ghcr.io/feldera/feldera-dev:sha-db53e1302c944e29edd6d2af516fff7032b90e3b
steps:
- name: Show Kubernetes node
if: always()
run: |
echo "K8S node: ${K8S_NODE_NAME}"
- name: Checkout repository
uses: actions/checkout@v6
- name: Cache Rust dependencies
uses: Swatinem/rust-cache@v2
- uses: actions/cache@v5
with:
path: |
/home/ubuntu/.gradle
./sql-to-dbsp-compiler/calcite
key: sql2dbsp-java-cache2-${{ runner.os }}-${{ hashFiles('sql-to-dbsp-compiler/calcite_version.env') }}
restore-keys: |
sql2dbsp-java-cache2-${{ runner.os }}-
# TODO: Avoid doing this twice and ideally download & reuse the JAR from build-java.yml workflow
- name: Run build.sh
run: ./build.sh
working-directory: ./sql-to-dbsp-compiler
if: ${{ vars.CI_DRY_RUN != 'true' }}
env:
CALCITE_BUILD_DIR: ./calcite
GRADLE_HOME: /home/ubuntu/.gradle
- name: Stop gradle daemon
run: gradle --stop
- name: Run mvn test
run: mvn test --no-transfer-progress -q -B -pl SQL-compiler -Dsurefire.failIfNoSpecifiedTests=false
working-directory: ./sql-to-dbsp-compiler
if: ${{ vars.CI_DRY_RUN != 'true' }}
- name: Run one quick SLT test
if: ${{ vars.CI_DRY_RUN != 'true' }}
run: mvn test --no-transfer-progress -q -B -Dsurefire.failIfNoSpecifiedTests=false -Dtest=RotateTests#quick
working-directory: ./sql-to-dbsp-compiler
- name: Print sccache stats
run: |
sccache --show-stats
if: ${{ vars.CI_DRY_RUN != 'true' }}