Support attaching delta tables as catalogs #69
Workflow file for this run
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
name: Local functional tests | |
on: [push, pull_request,repository_dispatch] | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.head_ref || '' }}-${{ github.base_ref || '' }}-${{ github.ref != 'refs/heads/main' || github.sha }} | |
cancel-in-progress: true | |
defaults: | |
run: | |
shell: bash | |
env: | |
BASE_BRANCH: ${{ github.base_ref || (endsWith(github.ref, '_feature') && 'feature' || 'main') }} | |
jobs: | |
azurite-tests-linux: | |
name: Azurite (local azure test server) tests (Linux) | |
runs-on: ubuntu-latest | |
container: 'quay.io/pypa/manylinux2014_x86_64' | |
env: | |
VCPKG_TARGET_TRIPLET: 'x64-linux' | |
GEN: Ninja | |
VCPKG_TOOLCHAIN_PATH: ${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake | |
AZURE_STORAGE_CONNECTION_STRING: 'DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;QueueEndpoint=http://127.0.0.1:10001/devstoreaccount1;TableEndpoint=http://127.0.0.1:10002/devstoreaccount1;' | |
AZURE_STORAGE_ACCOUNT: devstoreaccount1 | |
ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION: true | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
submodules: 'true' | |
- name: install Azure test service | |
run: | | |
yum install -y nodejs npm | |
npm install -g azurite | |
echo -e "[azure-cli]\nname=Azure CLI\nbaseurl=https://packages.microsoft.com/yumrepos/azure-cli\nenabled=1\ngpgcheck=1\ngpgkey=https://packages.microsoft.com/keys/microsoft.asc" | tee /etc/yum.repos.d/azure-cli.repo | |
yum install -y azure-cli | |
- name: Setup ManyLinux2014 | |
run: | | |
./duckdb/scripts/setup_manylinux2014.sh general aws-cli ccache ssh python_alias openssl | |
- name: Setup Rust for manylinux (dtolnay/rust-toolchain doesn't work due to curl being old here) | |
run: | | |
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y | |
echo "$HOME/.cargo/bin" >> $GITHUB_PATH | |
- name: Setup vcpkg | |
uses: lukka/[email protected] | |
with: | |
vcpkgGitCommitId: a1a1cbc975abf909a6c8985a6a2b8fe20bbd9bd6 | |
- name: Handle OpenSSL dependency for rust build | |
run: | | |
echo "OPENSSL_ROOT_DIR=`pwd`/build/release/vcpkg_installed/x64-linux" >> $GITHUB_ENV | |
echo "OPENSSL_DIR=`pwd`/build/release/vcpkg_installed/x64-linux" >> $GITHUB_ENV | |
echo "OPENSSL_USE_STATIC_LIBS=true" >> $GITHUB_ENV | |
# Build extension | |
- name: Build extension | |
env: | |
GEN: ninja | |
run: | | |
make release | |
- name: Launch & populate Azure test service | |
run: | | |
azurite > azurite_log.txt 2>&1 & | |
sleep 10 | |
./scripts/upload_test_files_to_azurite.sh | |
- name: Test extension | |
run: | | |
make test | |
- name: Azure test server log | |
if: always() | |
shell: bash | |
run: | | |
echo "## azurite" | |
cat azurite_log.txt | |
minio-tests-linux: | |
name: Minio (local S3 test server) tests (Linux) | |
runs-on: ubuntu-latest | |
env: | |
S3_TEST_SERVER_AVAILABLE: 1 | |
GEN: ninja | |
VCPKG_TARGET_TRIPLET: x64-linux | |
VCPKG_TOOLCHAIN_PATH: ${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
submodules: 'true' | |
- name: Checkout DuckDB to version | |
if: ${{ matrix.duckdb_version != '<submodule_version>'}} | |
run: | | |
cd duckdb | |
git checkout ${{ matrix.duckdb_version }} | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.11' | |
- name: Install Ninja | |
shell: bash | |
run: sudo apt-get update -y -qq && sudo apt-get install -y -qq ninja-build | |
- name: Setup Ccache | |
uses: hendrikmuhs/ccache-action@main | |
with: | |
key: ${{ github.job }} | |
- name: Setup vcpkg | |
uses: lukka/[email protected] | |
with: | |
vcpkgGitCommitId: a1a1cbc975abf909a6c8985a6a2b8fe20bbd9bd6 | |
- name: Configure OpenSSL for Rust | |
run: | | |
echo "OPENSSL_ROOT_DIR=`pwd`/build/release/vcpkg_installed/x64-linux" >> $GITHUB_ENV | |
echo "OPENSSL_DIR=`pwd`/build/release/vcpkg_installed/x64-linux" >> $GITHUB_ENV | |
echo "OPENSSL_USE_STATIC_LIBS=true" >> $GITHUB_ENV | |
- name: Build | |
shell: bash | |
run: make | |
- name: Start S3/HTTP test server | |
shell: bash | |
run: | | |
cd duckdb | |
mkdir data/attach_test | |
touch data/attach_test/attach.db | |
sudo ./scripts/install_s3_test_server.sh | |
source ./scripts/run_s3_test_server.sh | |
sleep 30 | |
- name: Write AWS credentials file | |
shell: bash | |
run: | | |
./scripts/create_minio_credential_file.sh | |
- name: Copy files to minio | |
shell: bash | |
env: | |
DUCKDB_MINIO_TEST_SERVER_AVAILABLE: 1 | |
AWS_ACCESS_KEY_ID: minio_duckdb_user | |
AWS_SECRET_ACCESS_KEY: minio_duckdb_user_password | |
AWS_DEFAULT_REGION: eu-west-1 | |
AWS_ENDPOINT: duckdb-minio.com:9000 | |
run: | | |
./scripts/upload_test_files_to_minio.sh | |
- name: Test | |
shell: bash | |
run: | | |
make test | |
- name: Run Env tests | |
shell: bash | |
env: | |
DUCKDB_MINIO_TEST_SERVER_AVAILABLE: 1 | |
AWS_ACCESS_KEY_ID: minio_duckdb_user | |
AWS_SECRET_ACCESS_KEY: minio_duckdb_user_password | |
AWS_DEFAULT_REGION: eu-west-1 | |
AWS_ENDPOINT: duckdb-minio.com:9000 | |
run: | | |
./build/release/test/unittest "*/test/sql/cloud/minio_local/*" | |
generated-tests-linux: | |
name: Generated Tests (Linux) | |
runs-on: ubuntu-latest | |
env: | |
GEN: ninja | |
VCPKG_TOOLCHAIN_PATH: ${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
submodules: 'true' | |
- name: Install | |
shell: bash | |
run: sudo apt-get update -y -qq && sudo apt-get install -y -qq ninja-build | |
- name: Setup Ccache | |
uses: hendrikmuhs/ccache-action@main | |
with: | |
key: ${{ github.job }} | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11' | |
- name: Setup vcpkg | |
uses: lukka/[email protected] | |
with: | |
vcpkgGitCommitId: a1a1cbc975abf909a6c8985a6a2b8fe20bbd9bd6 | |
- name: Configure OpenSSL for Rust | |
run: | | |
echo "OPENSSL_ROOT_DIR=`pwd`/build/release/vcpkg_installed/x64-linux" >> $GITHUB_ENV | |
echo "OPENSSL_DIR=`pwd`/build/release/vcpkg_installed/x64-linux" >> $GITHUB_ENV | |
echo "OPENSSL_USE_STATIC_LIBS=true" >> $GITHUB_ENV | |
- name: Build | |
shell: bash | |
run: make generate-data | |
- name: Test | |
shell: bash | |
run: | | |
GENERATED_DATA_AVAILABLE=1 make test | |
regression-test-benchmark-runner: | |
name: Performance Regression Tests | |
runs-on: ubuntu-latest | |
env: | |
GEN: ninja | |
BUILD_BENCHMARK: 1 | |
VCPKG_TARGET_TRIPLET: x64-linux | |
VCPKG_TOOLCHAIN_PATH: ${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
submodules: 'true' | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
- name: Install | |
shell: bash | |
run: sudo apt-get update -y -qq && sudo apt-get install -y -qq ninja-build && pip install requests | |
- name: Setup Ccache | |
uses: hendrikmuhs/ccache-action@main | |
with: | |
key: ${{ github.job }} | |
- name: Setup vcpkg | |
uses: lukka/[email protected] | |
with: | |
vcpkgGitCommitId: a1a1cbc975abf909a6c8985a6a2b8fe20bbd9bd6 | |
- name: Configure OpenSSL for Rust | |
run: | | |
echo "OPENSSL_ROOT_DIR=`pwd`/build/release/vcpkg_installed/x64-linux" >> $GITHUB_ENV | |
echo "OPENSSL_DIR=`pwd`/build/release/vcpkg_installed/x64-linux" >> $GITHUB_ENV | |
echo "OPENSSL_USE_STATIC_LIBS=true" >> $GITHUB_ENV | |
- name: Build current release | |
shell: bash | |
run: | | |
make | |
rm -rf build/release/rust | |
- name: Build ${{ env.BASE_BRANCH }} branch | |
shell: bash | |
run: | | |
git clone --branch ${{ env.BASE_BRANCH }} https://github.com/duckdb/duckdb_delta.git --depth=1 | |
cd duckdb_delta | |
git submodule init | |
git submodule update | |
make | |
rm -rf build/release/rust | |
- name: Generate test data | |
shell: bash | |
run: make generate-data | |
- name: Regression Test TPC-H | |
if: always() | |
shell: bash | |
run: | | |
python3 ./duckdb/scripts/regression_test_runner.py --old=duckdb_delta/build/release/benchmark/benchmark_runner --new=build/release/benchmark/benchmark_runner --benchmarks=.github/regression/tpch_sf1_local.csv --verbose --threads=2 --root-dir=. | |
- name: Regression Test TPC-DS | |
if: always() | |
shell: bash | |
run: | | |
python ./duckdb/scripts/regression_test_runner.py --old=duckdb_delta/build/release/benchmark/benchmark_runner --new=build/release/benchmark/benchmark_runner --benchmarks=.github/regression/tpcds_sf1_local.csv --verbose --threads=2 --root-dir=. | |
- name: Regression Test Micro | |
if: always() | |
shell: bash | |
run: | | |
python ./duckdb/scripts/regression_test_runner.py --old=duckdb_delta/build/release/benchmark/benchmark_runner --new=build/release/benchmark/benchmark_runner --benchmarks=.github/regression/micro.csv --verbose --threads=2 --root-dir=. | |
- name: Test benchmark makefile | |
shell: bash | |
run: | | |
make bench-run-tpch-sf1 | |
make bench-run-tpcds-sf1 |