@hypequery/clickhouse 2.9.1 → 2.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/datasets.d.ts.map +1 -1
- package/dist/datasets.js +5 -3
- package/package.json +3 -3
package/dist/datasets.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"datasets.d.ts","sourceRoot":"","sources":["../src/datasets.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,EAGL,KAAK,eAAe,EAGrB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AACxE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAEtE,0HAA0H;AAC1H,MAAM,MAAM,mBAAmB,GAAG,wBAAwB,CAAC;AAsd3D;;;;;;;;;;;;GAYG;AACH,wBAAgB,aAAa,CAAC,MAAM,SAAS,gBAAgB,CAAC,MAAM,CAAC,EACnE,MAAM,EAAE,mBAAmB,GAC1B,eAAe,
|
|
1
|
+
{"version":3,"file":"datasets.d.ts","sourceRoot":"","sources":["../src/datasets.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,EAGL,KAAK,eAAe,EAGrB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AACxE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAEtE,0HAA0H;AAC1H,MAAM,MAAM,mBAAmB,GAAG,wBAAwB,CAAC;AAsd3D;;;;;;;;;;;;GAYG;AACH,wBAAgB,aAAa,CAAC,MAAM,SAAS,gBAAgB,CAAC,MAAM,CAAC,EACnE,MAAM,EAAE,mBAAmB,GAC1B,eAAe,CA0DjB"}
|
package/dist/datasets.js
CHANGED
|
@@ -448,13 +448,13 @@ export function createBackend(config) {
|
|
|
448
448
|
/**
|
|
449
449
|
* Execute a semantic plan and return results
|
|
450
450
|
*/
|
|
451
|
-
async execute(plan) {
|
|
451
|
+
async execute(plan, options) {
|
|
452
452
|
const start = Date.now();
|
|
453
453
|
if (plan.kind === 'aggregate') {
|
|
454
454
|
// Base metrics: use query builder for full safety
|
|
455
455
|
const query = buildAggregateQuery(queryBuilder, plan);
|
|
456
456
|
const { sql } = query.toSQLWithParams();
|
|
457
|
-
const data = await query.execute();
|
|
457
|
+
const data = await query.execute({ abortSignal: options?.abortSignal });
|
|
458
458
|
return {
|
|
459
459
|
data,
|
|
460
460
|
meta: {
|
|
@@ -466,7 +466,9 @@ export function createBackend(config) {
|
|
|
466
466
|
}
|
|
467
467
|
// Derived metrics: CTE query with formulas
|
|
468
468
|
const { sql, parameters } = buildDerivedSQL(queryBuilder, plan);
|
|
469
|
-
const data = await queryBuilder.rawQuery(sql, parameters
|
|
469
|
+
const data = await queryBuilder.rawQuery(sql, parameters, {
|
|
470
|
+
abortSignal: options?.abortSignal,
|
|
471
|
+
});
|
|
470
472
|
const tenant = plan.input.kind === 'aggregate' && plan.input.tenant?.operator === 'eq'
|
|
471
473
|
? plan.input.tenant.value
|
|
472
474
|
: undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hypequery/clickhouse",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.10.1",
|
|
4
4
|
"description": "Type-safe ClickHouse query builder and schema generator for TypeScript analytics",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"clickhouse",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"dependencies": {
|
|
49
49
|
"@clickhouse/client": "^1.18.3",
|
|
50
50
|
"dotenv": "^16.0.0",
|
|
51
|
-
"@hypequery/protocol": "0.
|
|
51
|
+
"@hypequery/protocol": "0.13.0"
|
|
52
52
|
},
|
|
53
53
|
"peerDependencies": {
|
|
54
54
|
"@clickhouse/client-web": "^0.2.0 || ^1.0.0",
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
"typescript": "^5.7.3",
|
|
75
75
|
"@vitest/coverage-v8": "^3.2.6",
|
|
76
76
|
"vitest": "^3.2.6",
|
|
77
|
-
"@hypequery/datasets": "0.
|
|
77
|
+
"@hypequery/datasets": "0.15.0"
|
|
78
78
|
},
|
|
79
79
|
"ts-node": {
|
|
80
80
|
"esm": true,
|