Skip to content

PHOENIX-7964: Wait for Phoenix system tables to initialize before sta… #115

PHOENIX-7964: Wait for Phoenix system tables to initialize before sta…

PHOENIX-7964: Wait for Phoenix system tables to initialize before sta… #115

Workflow file for this run

name: CI Build and Test
on:
push:
pull_request:
workflow_dispatch:
jobs:
build-and-test:
runs-on: ubuntu-latest
strategy:
matrix:
# PRs: JDK 8 only for fast feedback
# Push: JDK 8 + 21 to verify baseline and --add-opens flags
java: ${{ github.event_name == 'pull_request' && fromJSON('[8]') || fromJSON('[8, 21]') }}
fail-fast: false
# Increase timeout for long-running test suites
#timeout-minutes: 60
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@v4
with:
java-version: ${{ matrix.java }}
distribution: 'temurin'
cache: 'maven'
- name: Cache Maven dependencies
uses: actions/cache@v4
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Configure Maven
run: |
# Create Maven options file to set memory limits for builds
mkdir -p .mvn
echo "-Xms4g -Xmx4g -XX:MaxMetaspaceSize=512m -XX:+UseG1GC" > .mvn/jvm.config
# Set MAVEN_OPTS as backup
echo "MAVEN_OPTS=-Xms4g -Xmx4g -XX:MaxMetaspaceSize=512m -XX:+UseG1GC" >> $GITHUB_ENV
- name: Build with Maven (skip tests)
run: mvn clean install -DskipTests -B -V
env:
MAVEN_OPTS: "-Xms4g -Xmx4g -XX:MaxMetaspaceSize=512m -XX:+UseG1GC"
- name: Run tests with Maven
run: mvn clean verify -B -V
env:
MAVEN_OPTS: "-Xms4g -Xmx4g -XX:MaxMetaspaceSize=512m -XX:+UseG1GC"
- name: Upload Test Results
if: always()
uses: actions/upload-artifact@v4
with:
name: test-results-jdk${{ matrix.java }}
path: |
**/target/surefire-reports/*.xml
**/target/surefire-reports/*.txt
**/target/failsafe-reports/*.xml
**/target/failsafe-reports/*.txt
retention-days: 5
- name: Upload Test Logs
if: failure()
uses: actions/upload-artifact@v4
with:
name: test-logs-jdk${{ matrix.java }}
path: |
**/target/surefire-reports/*.txt
**/target/failsafe-reports/*.txt
**/logs/*.log
retention-days: 5
- name: Publish Test Report
if: failure()
uses: mikepenz/action-junit-report@v4
env:
NODE_OPTIONS: '--max-old-space-size=12288'
with:
report_paths: '**/target/*-reports/TEST-*.xml'
check_name: Test Results (JDK ${{ matrix.java }})
fail_on_failure: true
require_tests: true
- name: Upload Build Artifacts
if: success()
uses: actions/upload-artifact@v4
with:
name: build-artifacts-jdk${{ matrix.java }}
path: |
phoenix-ddb-assembly/target/*.tar.gz
retention-days: 5