Repository navigation
109 lines (95 loc) · 3.94 KB
/
Copy pathintegration.yml
File metadata and controls
109 lines (95 loc) · 3.94 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
# © Copyright 2025, 2026 Query Farm LLC - https://query.farm
#
# Runs the canonical Query-farm/vgi integration sqllogictest suite against the
# C++ example worker across all three transports (subprocess / launcher / http),
# with the signed VGI extension users install from the community channel and the
# standalone haybarn-unittest runner. The harness is ci/run-integration.sh,
# ported from vgi-rust so every SDK is held to the same published artifact.
name: Integration suite
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
permissions:
contents: read
concurrency:
group: integration-${{ github.ref }}
cancel-in-progress: true
env:
# Track the shared suite directly. No pin: CI should expose any lag between
# this SDK and the published extension the day it appears.
VGI_REF: main
VCPKG_BINARY_SOURCES: "${{ secrets.R2_ACCESS_KEY_ID != '' && secrets.R2_SECRET_KEY_ID != '' && secrets.R2_ENDPOINT != '' && 'clear;x-aws,s3://query-farm-duckdb-vcpkg/,readwrite' || 'clear' }}"
AWS_ACCESS_KEY_ID: ${{ secrets.R2_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.R2_SECRET_KEY_ID }}
AWS_ENDPOINT_URL: ${{ secrets.R2_ENDPOINT }}
AWS_DEFAULT_REGION: auto
AWS_REQUEST_CHECKSUM_CALCULATION: when_required
AWS_RESPONSE_CHECKSUM_VALIDATION: when_required
jobs:
integration:
name: Linux / ${{ matrix.transport }}
runs-on: ubuntu-24.04
timeout-minutes: 90
strategy:
fail-fast: false
matrix:
transport: [stdio, launch, http]
steps:
- uses: actions/checkout@v4
- name: Check out vgi-rpc-cpp
uses: actions/checkout@v4
with:
repository: Query-farm/vgi-rpc-cpp
ref: v0.11.0
path: vgi-rpc-c++
- name: Check out the current vgi test suite
uses: actions/checkout@v4
with:
repository: Query-farm/vgi
ref: ${{ env.VGI_REF }}
path: vgi-upstream
- name: Clone and bootstrap vcpkg
run: |
git clone https://github.com/microsoft/vcpkg.git
git -C vcpkg checkout 2d32fae67c755b665794a0650f5d268979d7807f
./vcpkg/bootstrap-vcpkg.sh -disableMetrics
echo "VCPKG_ROOT=$(pwd)/vcpkg" >> $GITHUB_ENV
- name: Install autotools (libsodium)
run: sudo apt-get update && sudo apt-get install -y autoconf autoconf-archive automake libtool
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2
with:
key: integration-ubuntu-24.04
max-size: 500M
- name: Build example worker
run: |
cmake --preset release \
-DVGI_RPC_SOURCE_DIR=${{ github.workspace }}/vgi-rpc-c++ \
-DCMAKE_C_COMPILER_LAUNCHER=ccache \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
cmake --build build-release --target vgi-example-worker --parallel 2
- name: Resolve latest haybarn release
env:
GH_TOKEN: ${{ github.token }}
run: |
release="$(gh release view --repo Query-farm-haybarn/haybarn --json tagName --jq .tagName)"
echo "HAYBARN_RELEASE=$release" >> "$GITHUB_ENV"
- name: Download + extract haybarn-unittest
env:
GH_TOKEN: ${{ github.token }}
run: |
gh release download "$HAYBARN_RELEASE" --repo Query-farm-haybarn/haybarn \
--pattern 'haybarn_unittest-linux-amd64.zip' --output hb.zip --clobber
python3 -c "import zipfile; zipfile.ZipFile('hb.zip').extractall('hb')"
ut="$(find hb -type f -name 'haybarn-unittest' | head -1)"
chmod +x "$ut"
echo "HAYBARN_UNITTEST=$(cd "$(dirname "$ut")" && pwd)/$(basename "$ut")" >> "$GITHUB_ENV"
- name: Run integration suite (${{ matrix.transport }})
run: ci/run-integration.sh
env:
VGI_SRC: ${{ github.workspace }}/vgi-upstream
VGI_WORKER_BIN: ${{ github.workspace }}/build-release/example-worker/vgi-example-worker
TRANSPORT: ${{ matrix.transport }}