-
Notifications
You must be signed in to change notification settings - Fork 180
feat(ibis): Add Spark connector #1398
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
e00c1fa
spark connector
douenergy fcfa960
wren core
douenergy ec85e5b
CI
douenergy 0016323
fix ci
douenergy 2af27d2
spark ci again
douenergy f5c6be2
address comment
douenergy eb20b85
Merge branch 'main' into spark
douenergy 06e6447
poetry conflict
douenergy 27ec7f2
add spark test to readme
douenergy 20b5235
search all catalog
douenergy File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,104 @@ | ||
| name: ibis CI (spark) | ||
| permissions: | ||
| contents: read | ||
| pull-requests: write | ||
|
|
||
| on: | ||
| pull_request: | ||
|
|
||
| concurrency: | ||
| group: ${{ github.workflow }}-${{ github.event.number }} | ||
| cancel-in-progress: true | ||
|
|
||
| defaults: | ||
| run: | ||
| working-directory: ibis-server | ||
|
|
||
| jobs: | ||
| ci: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - name: Ruff check | ||
| uses: chartboost/ruff-action@v1 | ||
| with: | ||
| src: './ibis-server' | ||
| args: 'format --check' | ||
|
|
||
| - uses: actions/setup-java@v4 | ||
| with: | ||
| distribution: 'temurin' | ||
| java-version: '21' | ||
| cache: 'maven' | ||
|
|
||
| - name: Start Wren JAVA engine | ||
| working-directory: ./wren-core-legacy | ||
| run: | | ||
| mkdir etc | ||
| echo "node.environment=production" >> etc/config.properties | ||
| echo "wren.directory=./etc/mdl" >> etc/config.properties | ||
| echo "wren.experimental-enable-dynamic-fields=true" >> etc/config.properties | ||
| ./mvnw clean install -B -DskipTests -P exec-jar | ||
| java -Dconfig=etc/config.properties \ | ||
| --add-opens=java.base/java.nio=ALL-UNNAMED \ | ||
| -jar ./wren-server/target/wren-server-*-executable.jar & | ||
|
|
||
| - name: Start Spark cluster | ||
| working-directory: ./ibis-server/tests/routers/v3/connector/spark | ||
| run: | | ||
| docker compose up -d --build | ||
| echo "Waiting for Spark Connect to be ready..." | ||
| timeout 180 bash -c 'until docker logs spark-connect 2>&1 | grep -q "Spark Connect server started"; do echo "Waiting..."; sleep 5; done' || (echo "Timeout waiting for Spark"; docker compose logs; exit 1) | ||
| echo "Spark Connect is ready!" | ||
|
|
||
| - name: Verify Spark cluster status | ||
| run: | | ||
| docker ps | ||
| echo "Checking Spark Connect logs:" | ||
| docker logs spark-connect --tail 50 | ||
|
|
||
| - name: Install poetry | ||
| run: pipx install poetry | ||
|
|
||
| - uses: actions/setup-python@v5 | ||
| with: | ||
| python-version-file: ./ibis-server/pyproject.toml | ||
| cache: 'poetry' | ||
|
|
||
| - uses: extractions/setup-just@v2 | ||
|
|
||
| - name: Cache Cargo | ||
| uses: actions/cache@v4 | ||
| with: | ||
| path: | | ||
| ~/.cargo/bin/ | ||
| ~/.cargo/registry/index/ | ||
| ~/.cargo/registry/cache/ | ||
| ~/.cargo/git/db/ | ||
| wren-core-py/target/ | ||
| key: ${{ runner.os }}-cargo-${{ hashFiles('wren-core-py/Cargo.lock') }} | ||
|
|
||
| - name: Install dependencies | ||
| run: | | ||
| just install --with dev | ||
|
|
||
| - name: Run Spark tests | ||
| env: | ||
| WREN_ENGINE_ENDPOINT: http://localhost:8080 | ||
| run: poetry run pytest -m "spark" -v | ||
|
|
||
| - name: Show Spark logs on failure | ||
| if: failure() | ||
| run: | | ||
| echo "=== Spark Connect logs ===" | ||
| docker logs spark-connect | ||
| echo "=== Spark Master logs ===" | ||
| docker logs spark-master | ||
| echo "=== Spark Worker logs ===" | ||
| docker logs spark-worker | ||
|
|
||
| - name: Cleanup Spark cluster | ||
| if: always() | ||
| working-directory: ./ibis-server/tests/routers/v3/connector/spark | ||
| run: docker compose down -v |
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.