Skip to content

Commit 65e8e43

Browse files
pdabre12Pratik Joseph Dabre
authored andcommitted
Add CI job
1 parent 598db00 commit 65e8e43

File tree

1 file changed

+116
-0
lines changed

1 file changed

+116
-0
lines changed

.github/workflows/arrow-flight-tests.yml

Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,46 @@ jobs:
5757
- name: Maven Tests
5858
run: ./mvnw test ${MAVEN_TEST} -pl ${{ matrix.modules }} -Dtest="*,!TestArrowFlightNativeQueries*"
5959

60+
arrowflight-shim-tests:
61+
runs-on: ubuntu-latest
62+
strategy:
63+
fail-fast: false
64+
matrix:
65+
java: [17.0.15]
66+
modules:
67+
- :presto-flight-shim # Only run tests for the `presto-flight-shim` module
68+
69+
timeout-minutes: 80
70+
concurrency:
71+
group: ${{ github.workflow }}-test-${{ matrix.modules }}-${{ github.event.pull_request.number }}-${{ matrix.java }}
72+
cancel-in-progress: true
73+
74+
steps:
75+
# Checkout the code only if there are changes in the relevant files
76+
- uses: actions/checkout@v4
77+
with:
78+
show-progress: false
79+
persist-credentials: false
80+
81+
# Set up Java and dependencies for the build environment
82+
- uses: actions/setup-java@v4
83+
with:
84+
distribution: temurin
85+
java-version: ${{ matrix.java }}
86+
cache: maven
87+
- name: Download nodejs to maven cache
88+
run: .github/bin/download_nodejs
89+
90+
# Install dependencies for the target module
91+
- name: Maven Install
92+
run: |
93+
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
94+
./mvnw install ${MAVEN_FAST_INSTALL} -e -am -pl ${{ matrix.modules }}
95+
96+
# Run Maven tests for the target module, excluding native tests
97+
- name: Maven Tests
98+
run: ./mvnw test ${MAVEN_TEST} -pl ${{ matrix.modules }} -Dtest="*,!TestArrowFederationNativeQueries*"
99+
60100
prestocpp-linux-build-for-test:
61101
runs-on: ubuntu-22.04
62102
container:
@@ -225,3 +265,79 @@ jobs:
225265
-DDATA_DIR=${RUNNER_TEMP} \
226266
-Duser.timezone=America/Bahia_Banderas \
227267
-T1C
268+
269+
arrowfederation-native-e2e-tests:
270+
needs: prestocpp-linux-build-for-test
271+
runs-on: ubuntu-22.04
272+
container:
273+
image: prestodb/presto-native-dependency:0.292-20250204112033-cf8ba84
274+
env:
275+
INSTALL_PREFIX: "${{ github.workspace }}/adapter-deps/install"
276+
strategy:
277+
fail-fast: false
278+
matrix:
279+
modules:
280+
- :presto-flight-shim # Only run tests for the `presto-flight-shim` module
281+
282+
timeout-minutes: 80
283+
concurrency:
284+
group: ${{ github.workflow }}-test-${{ matrix.modules }}-${{ github.event.pull_request.number }}
285+
cancel-in-progress: true
286+
287+
steps:
288+
- uses: actions/checkout@v4
289+
with:
290+
persist-credentials: false
291+
292+
- name: Fix git permissions
293+
# Usually actions/checkout does this but as we run in a container
294+
# it doesn't work
295+
run: git config --global --add safe.directory ${GITHUB_WORKSPACE}
296+
297+
- name: Download artifacts
298+
uses: actions/download-artifact@v4
299+
with:
300+
name: arrow-flight-presto-native-build
301+
path: presto-native-execution/_build/release/presto_cpp/main
302+
303+
- name: Download Arrow Flight install artifacts
304+
uses: actions/download-artifact@v4
305+
with:
306+
name: arrow-flight-install
307+
path: ${{ env.INSTALL_PREFIX }}/lib64
308+
309+
# Permissions are lost when uploading. Details here: https://github.com/actions/upload-artifact/issues/38
310+
- name: Restore execute permissions and library path
311+
run: |
312+
chmod +x ${GITHUB_WORKSPACE}/presto-native-execution/_build/release/presto_cpp/main/presto_server
313+
# Ensure transitive dependency libboost-iostreams is found.
314+
ldconfig /usr/local/lib
315+
316+
- name: Install OpenJDK8
317+
uses: actions/setup-java@v4
318+
with:
319+
distribution: temurin
320+
java-version: 17.0.15
321+
cache: maven
322+
- name: Download nodejs to maven cache
323+
run: .github/bin/download_nodejs
324+
325+
- name: Maven install
326+
env:
327+
# Use different Maven options to install.
328+
MAVEN_OPTS: -Xmx2G -XX:+ExitOnOutOfMemoryError
329+
run: |
330+
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}"
331+
./mvnw install ${MAVEN_FAST_INSTALL} -am -pl ${{ matrix.modules }}
332+
333+
- name: Run arrowflight native e2e tests
334+
run: |
335+
export PRESTO_SERVER_PATH="${GITHUB_WORKSPACE}/presto-native-execution/_build/release/presto_cpp/main/presto_server"
336+
mvn test \
337+
${MAVEN_TEST} \
338+
-pl ${{ matrix.modules }} \
339+
-Dtest="TestArrowFederationNativeQueries*" \
340+
-DPRESTO_SERVER=${PRESTO_SERVER_PATH} \
341+
-DDATA_DIR=${RUNNER_TEMP} \
342+
-Duser.timezone=America/Bahia_Banderas \
343+
-T1C

0 commit comments

Comments
 (0)