Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .github/workflows/drivers-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,13 @@ jobs:
# secrets as job-level environment variables, then referencing the environment variables
# to conditionally run steps in the job.
DRIVERS_TESTS_ATHENA_CUBEJS_AWS_KEY: ${{ secrets.DRIVERS_TESTS_ATHENA_CUBEJS_AWS_KEY }}

# redshift Test Serverless Instance is so tiny that it can't serve a few test suites at once,
# so we constrain it to 1 test suite at time.
concurrency:
group: ${{ contains(matrix.database, 'redshift') && 'redshift-global' || format('drivers-tests-{0}-{1}', matrix.database, github.run_id) }}
cancel-in-progress: false

strategy:
matrix:
database:
Expand Down
9 changes: 3 additions & 6 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,11 +86,8 @@ jobs:
node-version: [22.x]
# Don't forget to update build-native-release
python-version: [3.11]
transpile-worker-threads: [false, true]
fail-fast: false

env:
CUBEJS_TRANSPILATION_WORKER_THREADS: ${{ matrix.transpile-worker-threads }}
steps:
- id: get-tag-out
run: echo "$OUT"
Expand Down Expand Up @@ -144,16 +141,16 @@ jobs:
- name: Lerna test
run: yarn lerna run --concurrency 1 --stream --no-prefix unit
- name: Fix lcov paths
if: (matrix.node-version == '22.x' && matrix.transpile-worker-threads == true)
if: (matrix.node-version == '22.x')
run: |
./.github/actions/codecov-fix.sh
- name: Combine all fixed LCOV files
if: (matrix.node-version == '22.x' && matrix.transpile-worker-threads == true)
if: (matrix.node-version == '22.x')
run: |
echo "" > ./combined-unit.lcov
find ./packages -type f -name lcov.fixed.info -exec cat {} + >> ./combined-unit.lcov || true
- name: Upload coverage artifact
if: (matrix.node-version == '22.x' && matrix.transpile-worker-threads == true)
if: (matrix.node-version == '22.x')
uses: actions/upload-artifact@v4
with:
name: coverage-unit
Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.

# [1.4.0](https://github.com/cube-js/cube/compare/v1.3.86...v1.4.0) (2025-10-29)

### Bug Fixes

- **cubesql:** Always repartition joins when right side has multiple partitions ([#10105](https://github.com/cube-js/cube/issues/10105)) ([ae32748](https://github.com/cube-js/cube/commit/ae327483caabba974e271fb52f4ccc5fd5fa5789))

## [1.3.86](https://github.com/cube-js/cube/compare/v1.3.85...v1.3.86) (2025-10-29)

### Features
Expand Down
3 changes: 0 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
![]()
<p align="center">
<a href="https://cube.registration.goldcast.io/events/a6a3b4b8-a99f-489a-b740-060182dbce7b"><img src="https://lgo0ecceic.ucarecd.net/cd698180-3d96-4644-9c9e-daf299ecf3ea/" alt="Agentic Analytics Summit" width="100%"></a>
</p>
<p align="center">
<a href="https://cube.dev?ref=github-readme"><img src="https://raw.githubusercontent.com/cube-js/cube/master/docs/content/cube-logo-with-bg.png" alt="Cube — Semantic Layer for Data Applications" width="300px"></a>
</p>
Expand Down
28 changes: 23 additions & 5 deletions docs/pages/product/apis-integrations/rest-api/query-format.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,31 @@ The default value is `false`.
- `offset`: The number of initial rows to be skipped for your query. The default
value is `0`.
- `order`: An object, where the keys are measures or dimensions to order by and
their corresponding values are either `asc` or `desc`. The order of the fields
to order on is based on the order of the keys in the object. If not provided,
[default ordering][ref-default-order] is applied. If an empty object (`[]`) is
provided, no ordering is applied.
their corresponding values are either `asc` or `desc`. For [time dimensions][ref-default-granularities],
a granularity can be optionally provided, e.g., `orders.created_at.month`.
The order of the fields to order on is based on the order of the keys in the object.
If not provided, the [default ordering][ref-default-order] is applied.
If an empty object (`[]`) is provided, no ordering is applied.
- `timezone`: A [time zone][ref-time-zone] for your query. You can set the
desired time zone in the [TZ Database Name](https://en.wikipedia.org/wiki/Tz_database)
format, e.g., `America/Los_Angeles`.
- `renewQuery`: If `renewQuery` is set to `true`, Cube will renew all
[`refreshKey`][ref-schema-ref-preaggs-refreshkey] for queries and query
results in the foreground. However, if the
[`refreshKey`][ref-schema-ref-preaggs-refreshkey] (or
[`refreshKey.every`][ref-schema-ref-preaggs-refreshkey-every]) doesn't
indicate that there's a need for an update this setting has no effect. The
default value is `false`.

<InfoBox>

Cube provides only eventual consistency guarantee. Using a small
[`refreshKey.every`][ref-schema-ref-preaggs-refreshkey-every] value together
with `renewQuery` to achieve immediate consistency can lead to endless
refresh loops and overall system instability.

</InfoBox>

- `ungrouped`: If set to `true`, Cube will run an [ungrouped
query][ref-ungrouped-query].
- `joinHints`: Query-time [join hints][ref-join-hints], provided as an array of
Expand Down Expand Up @@ -673,4 +691,4 @@ refer to its documentation for more examples.
[ref-default-granularities]: /product/data-modeling/concepts#time-dimensions
[ref-custom-granularities]: /product/data-modeling/reference/dimensions#granularities
[wiki-iso-8601]: https://en.wikipedia.org/wiki/ISO_8601
[ref-join-hints]: /product/data-modeling/concepts/working-with-joins#join-hints
[ref-join-hints]: /product/data-modeling/concepts/working-with-joins#join-hints
6 changes: 3 additions & 3 deletions docs/pages/product/caching/recipes/non-additivity.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,7 @@ cube(`users`, {

### Decomposing into a formula with additive measures

Non-additive `avg` measures can be rewritten as
[calculated measures](/product/data-modeling/reference/measures#calculated-measures)
Non-additive `avg` measures can be rewritten as [calculated measures][ref-calculated-measures]
that reference additive measures only. Then, this additive measures can be used
in pre-aggregations. Please note, however, that you shouldn't include `avg_age`
measure in your pre-aggregation as it renders it non-additive.
Expand Down Expand Up @@ -245,4 +244,5 @@ or run it with the `docker-compose up` command. You'll see the result, including
queried data, in the console.


[ref-percentile-recipe]: /product/data-modeling/recipes/percentiles
[ref-percentile-recipe]: /product/data-modeling/recipes/percentiles
[ref-calculated-measures]: /product/data-modeling/concepts/calculated-members#calculated-measures
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ docker run -it -p 4000:4000 --env-file=.env cube-jdk
| `CUBEJS_DB_NAME` | The name of the database to connect to | A valid database name | ✅ |
| `CUBEJS_DB_DATABRICKS_URL` | The URL for a JDBC connection | A valid JDBC URL | ✅ |
| `CUBEJS_DB_DATABRICKS_ACCEPT_POLICY` | Whether or not to accept the license terms for the Databricks JDBC driver | `true`, `false` | ✅ |
| `CUBEJS_DB_DATABRICKS_TOKEN` | The [personal access token][databricks-docs-pat] used to authenticate the Databricks connection | A valid token | ✅ |
| `CUBEJS_DB_DATABRICKS_OAUTH_CLIENT_ID` | The OAuth client ID for [service principal][ref-databricks-m2m-oauth] authentication | A valid client ID | ❌ |
| `CUBEJS_DB_DATABRICKS_OAUTH_CLIENT_SECRET` | The OAuth client secret for [service principal][ref-databricks-m2m-oauth] authentication | A valid client secret | ❌ |
| `CUBEJS_DB_DATABRICKS_TOKEN` | The [personal access token][databricks-docs-pat] used to authenticate the Databricks connection | A valid token | ❌ |
| `CUBEJS_DB_DATABRICKS_CATALOG` | The name of the [Databricks catalog][databricks-catalog] to connect to | A valid catalog name | ❌ |
| `CUBEJS_DB_EXPORT_BUCKET_MOUNT_DIR` | The path for the [Databricks DBFS mount][databricks-docs-dbfs] (Not needed if using Unity Catalog connection) | A valid mount path | ❌ |
| `CUBEJS_DB_MAX_POOL` | The maximum number of concurrent database connections to pool. Default is `8` | A valid number | ❌ |
Expand Down Expand Up @@ -201,3 +203,4 @@ bucket][self-preaggs-export-bucket] **must be** configured.
[databricks-docs-approx-agg-fns]: https://docs.databricks.com/en/sql/language-manual/functions/approx_count_distinct.html
[self-preaggs-simple]: #simple
[self-preaggs-export-bucket]: #export-bucket
[ref-databricks-m2m-oauth]: https://docs.databricks.com/aws/en/dev-tools/auth/oauth-m2m
4 changes: 2 additions & 2 deletions docs/pages/product/configuration/data-sources/duckdb.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ deployment][ref-demo-deployment] in Cube Cloud.
| `CUBEJS_DB_DUCKDB_S3_USE_SSL` | Use SSL for connection | A boolean | ❌ |
| `CUBEJS_DB_DUCKDB_S3_URL_STYLE` | To choose the S3 URL style(vhost or path) | `vhost` or `path` | ❌ |
| `CUBEJS_DB_DUCKDB_S3_SESSION_TOKEN` | The token for the S3 session | A valid Session Token | ❌ |
| `CUBEJS_DB_DUCKDB_EXTENSIONS` | A comma-separated list of DuckDB extensions to install and load | A comma-separated list of DuckDB extensions | ❌ |
| `CUBEJS_DB_DUCKDB_COMMUNITY_EXTENSIONS` | A comma-separated list of DuckDB community extensions to install and load | A comma-separated list of DuckDB community extensions | ❌ |
| `CUBEJS_DB_DUCKDB_EXTENSIONS` | A comma-separated list of DuckDB extensions to install and load | A comma-separated list of DuckDB extensions | ❌ |
| `CUBEJS_DB_DUCKDB_COMMUNITY_EXTENSIONS` | A comma-separated list of DuckDB community extensions to install and load | A comma-separated list of DuckDB community extensions | ❌ |
| `CUBEJS_DB_DUCKDB_S3_USE_CREDENTIAL_CHAIN` | A flag to use credentials chain for secrets for S3 connections | `true`, `false`. Defaults to `false` | ❌ |
| `CUBEJS_CONCURRENCY` | The number of [concurrent queries][ref-data-source-concurrency] to the data source | A valid number | ❌ |

Expand Down
1 change: 1 addition & 0 deletions docs/pages/product/configuration/data-sources/presto.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ CUBEJS_DB_SCHEMA=my_presto_schema
| `CUBEJS_DB_USER` | The username used to connect to the database | A valid database username | ✅ |
| `CUBEJS_DB_PASS` | The password used to connect to the database | A valid database password | ✅ |
| `CUBEJS_DB_PRESTO_CATALOG` | The catalog within Presto to connect to | A valid catalog name within a Presto database | ✅ |
| `CUBEJS_DB_PRESTO_AUTH_TOKEN` | The authentication token to use when connecting to Presto/Trino. It will be sent in the `Authorization` header. | A valid authentication token | ❌ |
| `CUBEJS_DB_SCHEMA` | The schema within the database to connect to | A valid schema name within a Presto database | ✅ |
| `CUBEJS_DB_SSL` | If `true`, enables SSL encryption for database connections from Cube | `true`, `false` | ❌ |
| `CUBEJS_DB_MAX_POOL` | The maximum number of concurrent database connections to pool. Default is `8` | A valid number | ❌ |
Expand Down
1 change: 1 addition & 0 deletions docs/pages/product/configuration/data-sources/trino.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ CUBEJS_DB_SCHEMA=my_trino_schema
| `CUBEJS_DB_USER` | The username used to connect to the database | A valid database username | ✅ |
| `CUBEJS_DB_PASS` | The password used to connect to the database | A valid database password | ✅ |
| `CUBEJS_DB_PRESTO_CATALOG` | The catalog within Presto to connect to | A valid catalog name within a Presto database | ✅ |
| `CUBEJS_DB_PRESTO_AUTH_TOKEN` | The authentication token to use when connecting to Presto/Trino. It will be sent in the `Authorization` header. | A valid authentication token | ❌ |
| `CUBEJS_DB_SCHEMA` | The schema within the database to connect to | A valid schema name within a Presto database | ✅ |
| `CUBEJS_DB_SSL` | If `true`, enables SSL encryption for database connections from Cube | `true`, `false` | ❌ |
| `CUBEJS_DB_MAX_POOL` | The maximum number of concurrent database connections to pool. Default is `8` | A valid number | ❌ |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,22 @@ The name of the [Databricks catalog][databricks-catalog] to connect to.

[databricks-catalog]: (https://docs.databricks.com/en/data-governance/unity-catalog/create-catalogs.html)

## `CUBEJS_DB_DATABRICKS_OAUTH_CLIENT_ID`

The OAuth client ID for [service principal][ref-databricks-m2m-oauth] authentication in Databricks.

| Possible Values | Default in Development | Default in Production |
| ---------------------- | ---------------------- | --------------------- |
| A valid client ID | N/A | N/A |

## `CUBEJS_DB_DATABRICKS_OAUTH_CLIENT_SECRET`

The OAuth client secret for [service principal][ref-databricks-m2m-oauth] authentication in Databricks.

| Possible Values | Default in Development | Default in Production |
| ---------------------- | ---------------------- | --------------------- |
| A valid client secret | N/A | N/A |

## `CUBEJS_DB_DATABRICKS_TOKEN`

The [personal access token][databricks-docs-pat] used to authenticate the
Expand Down Expand Up @@ -680,6 +696,14 @@ The catalog within Presto/Trino to connect to.
| --------------------------------------------------- | ---------------------- | --------------------- |
| A valid catalog name within a Presto/Trino database | N/A | N/A |

## `CUBEJS_DB_PRESTO_AUTH_TOKEN`

The authentication token to use when connecting to Presto/Trino. It will be sent in the `Authorization` header.

| Possible Values | Default in Development | Default in Production |
| --------------- | ---------------------- | --------------------- |
| A valid authentication token | N/A | N/A |

## `CUBEJS_DB_QUERY_TIMEOUT`

The timeout value for any queries made to the database by Cube.
Expand Down Expand Up @@ -742,6 +766,22 @@ username/password, or `SNOWFLAKE_JWT` with key pairs.
| ---------------------------- | ---------------------- | --------------------- |
| `SNOWFLAKE`, `SNOWFLAKE_JWT` | `SNOWFLAKE` | `SNOWFLAKE` |

## `CUBEJS_DB_SNOWFLAKE_OAUTH_TOKEN`

The OAuth token to use with Snowflake.

| Possible Values | Default in Development | Default in Production |
| ------------------------------ | ---------------------- | --------------------- |
| A valid OAuth token | N/A | N/A |

## `CUBEJS_DB_SNOWFLAKE_OAUTH_TOKEN_PATH`

The path to the file containing the OAuth token for Snowflake.

| Possible Values | Default in Development | Default in Production |
| ------------------------------ | ---------------------- | --------------------- |
| A valid OAuth token | N/A | N/A |

## `CUBEJS_DB_SNOWFLAKE_CLIENT_SESSION_KEEP_ALIVE`

If `true`, [keep the Snowflake connection alive
Expand Down Expand Up @@ -1405,7 +1445,7 @@ code in worker threads.

| Possible Values | Default in Development | Default in Production |
| --------------- | ---------------------- | --------------------- |
| `true`, `false` | `false` | `false` |
| `true`, `false` | `true` | `true` |

<ReferenceBox>

Expand Down Expand Up @@ -1837,6 +1877,7 @@ The port for a Cube deployment to listen to API connections on.
[ref-dataviz-tools]: /product/configuration/visualization-tools
[ref-context-to-app-id]: /product/configuration/reference/config#context_to_app_id
[ref-environments]: /product/workspace/environments
[ref-databricks-m2m-oauth]: https://docs.databricks.com/aws/en/dev-tools/auth/oauth-m2m
[ref-mdx-api]: /product/apis-integrations/mdx-api
[ref-mdx-api-locale]: /product/apis-integrations/mdx-api#measure-format
[ref-time-dimensions]: /product/data-modeling/reference/dimensions#time
9 changes: 7 additions & 2 deletions docs/pages/product/data-modeling/concepts.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ metrics-first approaches.
_Cubes_ represent datasets in Cube and are conceptually similar to [views in
SQL][wiki-view-sql]. Cubes are usually declared in separate files with one
cube per file. Typically, a cube points to a single table in
your database using the [`sql_table` property][ref-schema-ref-sql-table]:
your [data source][ref-data-sources] using the [`sql_table` property][ref-schema-ref-sql-table]:

<CodeTabs>

Expand Down Expand Up @@ -104,6 +104,9 @@ Cubes and their members can be further referenced by [views](#views).

Note that cubes support [extension][ref-extending-cubes],
[polymorphism][ref-polymorphic-cubes], and [data blending][ref-data-blending].
Custom calendars, such as retail calendars, can be implemented using [calendar
cubes][ref-calendar-cubes].

Cubes can be defined statically and you can also build [dynamic data
models][ref-dynamic-data-models].

Expand Down Expand Up @@ -850,4 +853,6 @@ See the reference documentaton for the full list of pre-aggregation
[ref-custom-calendar-recipe]: /product/data-modeling/recipes/custom-calendar
[ref-cube-with-dbt]: /product/data-modeling/recipes/dbt
[ref-apis-support]: /product/apis-integrations#data-modeling
[ref-viz-tools]: /product/configuration/visualization-tools
[ref-viz-tools]: /product/configuration/visualization-tools
[ref-data-sources]: /product/configuration/data-sources
[ref-calendar-cubes]: /product/data-modeling/concepts/calendar-cubes
3 changes: 2 additions & 1 deletion docs/pages/product/data-modeling/concepts/_meta.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ module.exports = {
"calculated-members": "Calculated members",
"multi-stage-calculations": "Multi-stage calculations",
"working-with-joins": "Joins between cubes",
"calendar-cubes": "Calendar cubes",
"code-reusability-extending-cubes": "Extension",
"polymorphic-cubes": "Polymorphic cubes",
"data-blending": "Data blending"
}
}
Loading
Loading