Skip to content

Commit a0a0352

Browse files
authored
Merge branch 'SQLMesh:main' into main
2 parents 7d78e60 + fa46264 commit a0a0352

43 files changed

Lines changed: 10668 additions & 97 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/scripts/wait-for-db.sh

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,37 @@ spark_ready() {
5050
probe_port 15002
5151
}
5252

53+
starrocks_ready() {
54+
probe_port 9030
55+
56+
echo "Checking for 1 alive StarRocks backends..."
57+
sleep 5
58+
59+
while true; do
60+
echo "Checking StarRocks backends..."
61+
ALIVE_BACKENDS=$(docker exec -i starrocks-fe mysql -h127.0.0.1 -P9030 -uroot -e "show backends \G" | grep -c "^ *Alive: true *$")
62+
63+
# fallback value if failed to get number
64+
if ! [[ "$ALIVE_BACKENDS" =~ ^[0-9]+$ ]]; then
65+
echo "WARN: Unable to parse number of alive backends, got: '$ALIVE_BACKENDS'"
66+
ALIVE_BACKENDS=0
67+
fi
68+
69+
echo "Found $ALIVE_BACKENDS alive backends"
70+
71+
if [ "$ALIVE_BACKENDS" -ge 1 ]; then
72+
echo "StarRocks has 1 or more alive backends"
73+
break
74+
fi
75+
76+
echo "Waiting for more backends to become alive..."
77+
sleep 5
78+
done
79+
80+
# set default replication num to 1 (there is only one be in the docker compose file)
81+
docker exec -i starrocks-fe mysql -h127.0.0.1 -P9030 -uroot -e "ADMIN SET frontend config ('default_replication_num' = '1');"
82+
}
83+
5384
trino_ready() {
5485
# Trino has a built-in healthcheck script, just call that
5586
docker compose -f tests/core/engine_adapter/integration/docker/compose.trino.yaml exec trino /bin/bash -c '/usr/lib/trino/bin/health-check'

.github/workflows/pr.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@ jobs:
252252
fail-fast: false
253253
matrix:
254254
engine:
255-
[duckdb, postgres, mysql, mssql, trino, spark, clickhouse, risingwave]
255+
[duckdb, postgres, mysql, mssql, trino, spark, clickhouse, risingwave, starrocks]
256256
env:
257257
PYTEST_XDIST_AUTO_NUM_WORKERS: 2
258258
SQLMESH__DISABLE_ANONYMIZED_ANALYTICS: '1'

.readthedocs.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ build:
66
python: "3.10"
77
jobs:
88
pre_build:
9-
- pip install -e ".[athena,azuresql,bigframes,bigquery,clickhouse,databricks,dbt,dlt,gcppostgres,github,llm,mssql,mysql,mwaa,postgres,redshift,slack,snowflake,trino,web,risingwave]"
9+
- pip install -e ".[athena,azuresql,bigframes,bigquery,clickhouse,databricks,dbt,dlt,gcppostgres,github,llm,mssql,mysql,mwaa,postgres,redshift,slack,snowflake,starrocks,trino,web,risingwave]"
1010
- make api-docs
1111

1212
mkdocs:

Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,9 @@ trino-test: engine-trino-up
212212
risingwave-test: engine-risingwave-up
213213
pytest -n auto -m "risingwave" --reruns 3 --junitxml=test-results/junit-risingwave.xml
214214

215+
starrocks-test: engine-starrocks-up
216+
pytest -n auto -m "starrocks" --reruns 3 --junitxml=test-results/junit-starrocks.xml
217+
215218
#################
216219
# Cloud Engines #
217220
#################

docs/guides/configuration.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -920,6 +920,7 @@ These pages describe the connection configuration options for each execution eng
920920
* [GCP Postgres](../integrations/engines/gcp-postgres.md)
921921
* [Redshift](../integrations/engines/redshift.md)
922922
* [Snowflake](../integrations/engines/snowflake.md)
923+
* [StarRocks](../integrations/engines/starrocks.md)
923924
* [Spark](../integrations/engines/spark.md)
924925
* [Trino](../integrations/engines/trino.md)
925926

@@ -952,6 +953,7 @@ Unsupported state engines, even for development:
952953

953954
* [ClickHouse](../integrations/engines/clickhouse.md)
954955
* [Spark](../integrations/engines/spark.md)
956+
* [StarRocks](../integrations/engines/starrocks.md)
955957
* [Trino](../integrations/engines/trino.md)
956958

957959
This example gateway configuration uses Snowflake for the data warehouse connection and Postgres for the state backend connection:

docs/guides/connections.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,4 +90,5 @@ default_gateway: local_db
9090
* [Redshift](../integrations/engines/redshift.md)
9191
* [Snowflake](../integrations/engines/snowflake.md)
9292
* [Spark](../integrations/engines/spark.md)
93+
* [StarRocks](../integrations/engines/starrocks.md)
9394
* [Trino](../integrations/engines/trino.md)

0 commit comments

Comments
 (0)