forked from trinodb/trino
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add GitHub Actions workflow to build repro-cassandra jar
- Loading branch information
Showing
1 changed file
with
61 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
name: Build trino-cassandra | ||
|
||
on: | ||
push: | ||
branches: | ||
- 'repro-*' | ||
|
||
env: | ||
# An envar that signals to tests we are executing in the CI environment | ||
CONTINUOUS_INTEGRATION: true | ||
MAVEN_OPTS: "-Xmx1024M -XX:+ExitOnOutOfMemoryError" | ||
MAVEN_INSTALL_OPTS: "-Xmx2G -XX:+ExitOnOutOfMemoryError" | ||
MAVEN_FAST_INSTALL: "-B -V --quiet -T C1 -DskipTests -Dair.check.skip-all -Dmaven.javadoc.skip=true" | ||
MAVEN_TEST: "-B -Dair.check.skip-all -Dmaven.javadoc.skip=true -DLogTestDurationListener.enabled=true --fail-at-end" | ||
RETRY: .github/bin/retry | ||
|
||
jobs: | ||
trino-cassandra: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
id-token: write | ||
contents: read | ||
steps: | ||
- uses: aws-actions/configure-aws-credentials@v4 | ||
with: | ||
aws-region: ap-northeast-1 | ||
role-to-assume: ${{ vars.ROLE_TO_ASSUME }} | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-java@v3 | ||
with: | ||
distribution: corretto | ||
java-version: 11 | ||
- name: Cache local Maven repository | ||
id: cache-maven | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.m2/repository | ||
key: ${{ runner.os }}-maven-2-${{ hashFiles('**/pom.xml') }} | ||
restore-keys: | | ||
${{ runner.os }}-maven-2- | ||
- name: Populate maven cache | ||
if: steps.cache-maven.outputs.cache-hit != 'true' | ||
run: ./mvnw de.qaware.maven:go-offline-maven-plugin:resolve-dependencies | ||
- name: Maven Install | ||
run: | | ||
export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}" | ||
./mvnw install ${MAVEN_FAST_INSTALL} -am -pl plugin/trino-cassandra | ||
- name: Upload trino-cassandra.jar to S3 | ||
run: | | ||
trino_cassandra_jar=trino-cassandra-$(yq .project.version pom.xml).jar | ||
aws s3api put-object \ | ||
--bucket ${{ vars.DEPLOY_S3_BUCKET }} \ | ||
--key "${{ vars.DEPLOY_S3_KEY_PREFIX }}/${{ github.ref_name }}/${{ github.run_number }}/${trino_cassandra_jar}" \ | ||
--body "./plugin/trino-cassandra/target/${trino_cassandra_jar}" | ||
- name: Upload trino-cassandra-services.jar | ||
run: | | ||
trino_cassandra_services_jar=trino-cassandra-$(yq .project.version pom.xml)-services.jar | ||
aws s3api put-object \ | ||
--bucket ${{ vars.DEPLOY_S3_BUCKET }} \ | ||
--key "${{ vars.DEPLOY_S3_KEY_PREFIX }}/${{ github.ref_name }}/${{ github.run_number }}/${trino_cassandra_services_jar}" \ | ||
--body "./plugin/trino-cassandra/target/${trino_cassandra_services_jar}" |