Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into bs/issue/GR-24708-dev
Browse files Browse the repository at this point in the history
boris-spas committed Oct 18, 2022
2 parents 1f56054 + e5119bb commit 6abb5ec
Showing 197 changed files with 3,735 additions and 1,332 deletions.
162 changes: 70 additions & 92 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -9,11 +9,15 @@ on:
- '.devcontainer/**'
- '.github/workflows/quarkus.yml'
- '**.md'
- '**.jsonnet'
- '**.libjsonnet'
pull_request:
paths-ignore:
- '.devcontainer/**'
- '.github/workflows/quarkus.yml'
- '**.md'
- '**.jsonnet'
- '**.libjsonnet'
# Enable manual dispatch of the workflow
# see https://docs.github.com/en/actions/managing-workflow-runs/manually-running-a-workflow
workflow_dispatch:
@@ -32,163 +36,137 @@ concurrency:
cancel-in-progress: ${{ github.event_name == 'pull_request' || github.repository != 'oracle/graal' }}

env:
LANG: en_US.UTF-8
MX_GIT_CACHE: refcache
MX_PYTHON: python3.8
JAVA_HOME: ${{ github.workspace }}/jdk
JDT: builtin
LANG: en_US.UTF-8
MX_GATE_OPTS: "--strict-mode"
MX_GIT_CACHE: refcache
MX_PATH: ${{ github.workspace }}/mx
MX_PYTHON: python3.8

permissions:
contents: read # to fetch code (actions/checkout)

jobs:
build-graalvm:
name: ${{ matrix.env.JDK }} ${{ matrix.env.GATE }} ${{ matrix.env.PRIMARY }} ${{ matrix.env.WITHOUT_VCS }}
name: ${{ matrix.env.PRIMARY }} ${{ matrix.env.GATE }} JDK${{ matrix.env.JDK_VERSION }} ${{ matrix.env.WITHOUT_VCS }}
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
include:
# /compiler
- env:
JDK: "labsjdk-ce-17"
GATE: "style,fullbuild"
PRIMARY: "substratevm"
JDK_VERSION: "19"
GATE: "style,fullbuild,test"
PRIMARY: "compiler"
- env:
JDK: "labsjdk-ce-17"
GATE: "build,test"
JDK_VERSION: "19"
GATE: "build,bootstraplite"
PRIMARY: "compiler"
# /espresso
- env:
JDK: "labsjdk-ce-17"
JDK_VERSION: "17" # espresso does not support JDK19 yet
GATE: "style,fullbuild"
PRIMARY: "espresso"
# /substratevm
- env:
JDK_VERSION: "19"
GATE: "style,fullbuild"
PRIMARY: "substratevm"
- env:
JDK_VERSION: "19"
GATE: "build,test,helloworld"
PRIMARY: "substratevm"
- env:
JDK: "labsjdk-ce-17"
JDK_VERSION: "19"
GATE: "build,test,helloworld_debug"
PRIMARY: "substratevm"
- env:
JDK: "labsjdk-ce-17"
GATE: "build,bootstraplite"
PRIMARY: "compiler"
JDK_VERSION: "19"
GATE: "build,debuginfotest"
PRIMARY: "substratevm"
- env:
JDK: "labsjdk-ce-17"
JDK_VERSION: "19"
GATE: "hellomodule"
PRIMARY: "substratevm"
# /sulong
- env:
JDK_VERSION: "19"
GATE: "style,fullbuild,sulongBasic"
MX_GATE_OPTS: "--strict-mode --no-warning-as-error" # sulong throws deprecation warnings
PRIMARY: "sulong"
# /vm
- env:
JDK: "labsjdk-ce-17"
JDK_VERSION: "19"
GATE: "build,sulong"
MX_GATE_OPTS: "--strict-mode --no-warning-as-error" # sulong throws deprecation warnings
PRIMARY: "vm"
DYNAMIC_IMPORTS: "/sulong,/substratevm"
DISABLE_POLYGLOT: true
DISABLE_LIBPOLYGLOT: true
- env:
JDK: "labsjdk-ce-17"
GATE: "build,debuginfotest"
PRIMARY: "substratevm"
- env:
JDK: "labsjdk-ce-11"
GATE: "build,debuginfotest"
PRIMARY: "substratevm"
- env:
JDK: "labsjdk-ce-11"
GATE: "hellomodule"
PRIMARY: "substratevm"
- env:
JDK: "labsjdk-ce-11"
GATE: "style,fullbuild"
PRIMARY: "compiler"
- env:
JDK: "labsjdk-ce-11"
GATE: "build,test"
PRIMARY: "compiler"
- env:
JDK: "labsjdk-ce-11"
GATE: "build,bootstraplite"
PRIMARY: "compiler"
- env:
JDK: "labsjdk-ce-11"
JDK_VERSION: "17"
GATE: "build"
PRIMARY: "vm"
DYNAMIC_IMPORTS: "/tools,/substratevm,/sulong"
NATIVE_IMAGES: "polyglot"
WITHOUT_VCS: true
- env:
JDK: "labsjdk-ce-17"
GATE: "style,fullbuild"
PRIMARY: "espresso"
steps:
- uses: actions/checkout@v2
- name: Checkout oracle/graal
uses: actions/checkout@v3
with:
fetch-depth: 1
ref: ${{ github.ref }} # Lock ref to current branch to avoid fetching others
fetch-depth: "${{ contains(matrix.env.GATE, 'style') && '0' || '1' }}" # The style gate needs the full commit history for checking copyright years
- name: Determine mx version
run: echo "MX_VERSION=$(cat common.json | jq -r '.mx_version')" >> ${GITHUB_ENV}
- uses: actions/checkout@v2
run: echo "MX_VERSION=$(jq -r '.mx_version' common.json)" >> ${GITHUB_ENV}
- name: Checkout graalvm/mx
uses: actions/checkout@v3
with:
repository: graalvm/mx.git
fetch-depth: 1
ref: ${{ env.MX_VERSION }}
fetch-depth: 1
path: ${{ env.MX_PATH }}
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.8'
- uses: actions/cache@v1
- name: Update mx cache
uses: actions/cache@v3
with:
path: ~/.mx
key: ${{ runner.os }}-mx-${{ hashFiles('**/suite.py') }}
restore-keys: ${{ runner.os }}-mx-
- name: Get JDK
- name: Fetch LabsJDK
env: ${{ matrix.env }}
run: |
mkdir jdk-dl
${MX_PATH}/mx --java-home= fetch-jdk --jdk-id ${JDK} --to jdk-dl --alias ${JAVA_HOME}
${MX_PATH}/mx --java-home= fetch-jdk --jdk-id labsjdk-ce-${JDK_VERSION} --to jdk-dl --alias ${JAVA_HOME}
- name: Update dependency cache
if: ${{ contains(matrix.env.GATE, 'debug') || contains(matrix.env.GATE, 'style') }}
run: sudo apt update
- name: Debug dependencies
- name: Install debug dependencies
if: ${{ contains(matrix.env.GATE, 'debug') }}
run: sudo apt install gdb
- name: Style dependencies
- name: Install style dependencies
if: ${{ contains(matrix.env.GATE, 'style') }}
run: |
sudo apt install python3-pip python-setuptools
cat common.json |
jq -r '.deps.common.packages | to_entries[] | select(.key | startswith("pip:")) | (.key | split(":")[1]) + .value' |
jq -r '.deps.common.packages | to_entries[] | select(.key | startswith("pip:")) | (.key | split(":")[1]) + .value' common.json |
xargs sudo pip install
${MX_PYTHON} -m pip install jsonschema==4.6.1
- name: Download Eclipse
if: ${{ contains(matrix.env.GATE, 'style') }}
run: |
ECLIPSE_TAR=eclipse.tar.gz
ECLIPSE_ORG_VERSION=$(jq -r '.downloads.eclipse.eclipse_org.version' common.json)
ECLIPSE_ORG_TIMESTAMP=$(jq -r '.downloads.eclipse.eclipse_org.timestamp' common.json)
wget --no-verbose https://archive.eclipse.org/eclipse/downloads/drops4/R-${ECLIPSE_ORG_VERSION}-${ECLIPSE_ORG_TIMESTAMP}/eclipse-SDK-${ECLIPSE_ORG_VERSION}-linux-gtk-x86_64.tar.gz -O $ECLIPSE_TAR
tar -xzf ${ECLIPSE_TAR}
echo "ECLIPSE_EXE=${PWD}/eclipse/eclipse" >> $GITHUB_ENV
- name: Remove .git directory
if: ${{ matrix.env.WITHOUT_VCS }}
run: rm -rf .git
- name: Build GraalVM and run gate
env: ${{ matrix.env }}
run: |
if [[ ${GATE} == *style* ]]
then
export ECLIPSE_TAR=eclipse.tar.gz
ECLIPSE_ORG_VERSION=$(cat common.json | jq -r '.downloads.eclipse.eclipse_org.version')
ECLIPSE_ORG_TIMESTAMP=$(cat common.json | jq -r '.downloads.eclipse.eclipse_org.timestamp')
wget --no-verbose https://archive.eclipse.org/eclipse/downloads/drops4/R-${ECLIPSE_ORG_VERSION}-${ECLIPSE_ORG_TIMESTAMP}/eclipse-SDK-${ECLIPSE_ORG_VERSION}-linux-gtk-x86_64.tar.gz -O $ECLIPSE_TAR
tar -xzf ${ECLIPSE_TAR}
export ECLIPSE_EXE=${PWD}/eclipse/eclipse
# the style gate needs the full commit history for checking copyright years
git fetch --unshallow
fi
echo ${JAVA_HOME}
${JAVA_HOME}/bin/java -version
if [[ ${WITHOUT_VCS} ]]
then
rm -rf .git
fi
exit_code=0
${MX_PATH}/mx --primary-suite-path ${PRIMARY} --J @"-Xmx2g" --java-home=${JAVA_HOME} gate --strict-mode --tags ${GATE} || exit_code=$?
if [[ -n "${GHA_EXPECTED_FAILURE}" ]]
then
if [[ ${exit_code} -eq 0 ]]
then
echo "Gate passed but was marked as expected failure."
exit 25
fi
else
exit ${exit_code}
fi
run: ${MX_PATH}/mx --primary-suite-path ${PRIMARY} --java-home=${JAVA_HOME} gate ${MX_GATE_OPTS} --tags ${GATE}
47 changes: 24 additions & 23 deletions .github/workflows/quarkus.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Nightly quarkus tests
name: Nightly Quarkus Tests

on:
push:
@@ -11,67 +11,68 @@ on:
- cron: '0 3 * * *'

env:
# Workaround testsuite locale issue
LANG: en_US.UTF-8
DB_USER: hibernate_orm_test
DB_PASSWORD: hibernate_orm_test
DB_NAME: hibernate_orm_test
COMMON_MAVEN_ARGS: "-e -B --settings .github/mvn-settings.xml --fail-at-end"
NATIVE_TEST_MAVEN_ARGS: "-Dtest-containers -Dstart-containers -Dquarkus.native.native-image-xmx=5g -Dnative -Dnative.surefire.skip -Dformat.skip -Dno-descriptor-tests install -DskipDocs"
DB_NAME: hibernate_orm_test
DB_PASSWORD: hibernate_orm_test
DB_USER: hibernate_orm_test
GRAALVM_HOME: ${{ github.workspace }}/graalvm
JAVA_HOME: ${{ github.workspace }}/jdk
LANG: en_US.UTF-8 # Workaround testsuite locale issue
MX_GIT_CACHE: refcache
MX_PYTHON: python3.9
MX_PATH: ${{ github.workspace }}/mx
JAVA_HOME: ${{ github.workspace }}/jdk
MX_PYTHON: python3.8
NATIVE_TEST_MAVEN_ARGS: "-Dtest-containers -Dstart-containers -Dquarkus.native.native-image-xmx=5g -Dnative -Dnative.surefire.skip -Dformat.skip -Dno-descriptor-tests install -DskipDocs"
QUARKUS_PATH: ${{ github.workspace }}/quarkus
GRAALVM_HOME: ${{ github.workspace }}/graalvm

permissions: {}
jobs:
build-quarkus-and-graalvm:
permissions:
contents: read # to fetch code (actions/checkout)

name: Nightly quarkus and GraalVM build
name: Nightly Quarkus and GraalVM build
runs-on: ubuntu-20.04
outputs:
matrix: ${{ steps.read.outputs.matrix }}
steps:
- uses: actions/checkout@v2
- name: Checkout oracle/graal
uses: actions/checkout@v3
with:
fetch-depth: 1
- uses: actions/checkout@v2
- name: Checkout graalvm/mx
uses: actions/checkout@v3
with:
repository: graalvm/mx.git
fetch-depth: 1
ref: master
path: ${{ env.MX_PATH }}
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Get latest quarkus release
python-version: '3.8'
- name: Get latest Quarkus release
run: |
export QUARKUS_VERSION=main #$(curl https://repo1.maven.org/maven2/io/quarkus/quarkus-bom/maven-metadata.xml | awk -F"[<>]" '/latest/ {print $3}')
echo Getting Quarkus $QUARKUS_VERSION
curl --output quarkus.tgz -sL https://api.github.com/repos/quarkusio/quarkus/tarball/$QUARKUS_VERSION
mkdir ${QUARKUS_PATH}
tar xf quarkus.tgz -C ${QUARKUS_PATH} --strip-components=1
- uses: actions/cache@v1
- uses: actions/cache@v3
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- uses: actions/cache@v1
- uses: actions/cache@v3
with:
path: ~/.mx
key: ${{ runner.os }}-mx-${{ hashFiles('**/suite.py') }}
restore-keys: |
${{ runner.os }}-mx-
- name: Get JDK
- name: Fetch LabsJDK
run: |
mkdir jdk-dl
${MX_PATH}/mx --java-home= fetch-jdk --jdk-id labsjdk-ce-11 --to jdk-dl --alias ${JAVA_HOME}
${MX_PATH}/mx --java-home= fetch-jdk --jdk-id labsjdk-ce-17 --to jdk-dl --alias ${JAVA_HOME}
- name: Build graalvm native-image
run: |
cd substratevm
@@ -86,7 +87,7 @@ jobs:
with:
name: graalvm
path: graalvm.tgz
- name: Build quarkus
- name: Build Quarkus
run: |
cd ${QUARKUS_PATH}
eval ./mvnw -e -B -Dquickly
@@ -95,7 +96,7 @@ jobs:
run: |
json=$(tr -d '\n' < ${QUARKUS_PATH}/.github/native-tests.json )
echo $json
echo "::set-output name=matrix::${json}"
echo "matrix=${json}" >> $GITHUB_OUTPUT
- name: Tar Maven Repo
shell: bash
run: tar -czvf maven-repo.tgz -C ~ .m2/repository
@@ -126,7 +127,7 @@ jobs:
if: startsWith(matrix.os-name, 'ubuntu')
shell: bash
run: tar -xzvf graalvm.tgz -C $(dirname ${GRAALVM_HOME})
- name: Get latest quarkus release
- name: Get latest Quarkus release
if: startsWith(matrix.os-name, 'ubuntu')
run: |
export QUARKUS_VERSION=main #$(curl https://repo1.maven.org/maven2/io/quarkus/quarkus-bom/maven-metadata.xml | awk -F"[<>]" '/latest/ {print $3}')
Loading

0 comments on commit 6abb5ec

Please sign in to comment.