@vizzly/semantic-layer-public 0.0.243 → 0.0.244
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.
|
@@ -205,7 +205,8 @@ const configSchema = (fullObj, options) => joi_1.default.object({
|
|
|
205
205
|
sqlViews: joi_1.default.object()
|
|
206
206
|
.pattern(joi_1.default.string(), joi_1.default.object({ name: joi_1.default.string().required(), sql: joi_1.default.string().allow('').required() }))
|
|
207
207
|
.optional(),
|
|
208
|
-
runOptions: joi_1.default.object().optional()
|
|
208
|
+
runOptions: joi_1.default.object().optional(),
|
|
209
|
+
queryRoutingRules: joi_1.default.array().items(joi_1.default.object()).optional()
|
|
209
210
|
});
|
|
210
211
|
exports.bigQuerySchema = configSchema({}, { onlyClients: ['bigquery'] });
|
|
211
212
|
exports.postgresSchema = configSchema({}, { onlyClients: ['postgres'] });
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PartialBy } from '@vizzly/api-client';
|
|
2
|
-
import { Client, NormalizedDataType, SQLQuery, AnyConnection } from '@vizzly/sqlbuilder-public';
|
|
2
|
+
import { Client, NormalizedDataType, SQLQuery, AnyConnection, DataSetType } from '@vizzly/sqlbuilder-public';
|
|
3
3
|
import { SQLOperator } from '@vizzly/sqlbuilder-public';
|
|
4
4
|
export declare namespace nSemanticLayer {
|
|
5
5
|
export namespace Result {
|
|
@@ -80,7 +80,7 @@ export declare namespace nSemanticLayer {
|
|
|
80
80
|
/** Fields in the data set... */
|
|
81
81
|
fields: (AddressField | SQLField)[];
|
|
82
82
|
/** What joins are needed on underlying tables to make the right fields available? */
|
|
83
|
-
joins
|
|
83
|
+
joins: JoinOn[];
|
|
84
84
|
/** permanent filters */
|
|
85
85
|
permanentFilters?: SQLQuery['filter'];
|
|
86
86
|
};
|
|
@@ -112,9 +112,21 @@ export declare namespace nSemanticLayer {
|
|
|
112
112
|
sql: string;
|
|
113
113
|
name: string;
|
|
114
114
|
};
|
|
115
|
+
export type QueryRoutingRuleCheckId = 'can_use_pre_aggregated_data';
|
|
116
|
+
export type QueryRoutingRule = {
|
|
117
|
+
onlyIf: {
|
|
118
|
+
check: QueryRoutingRuleCheckId;
|
|
119
|
+
targetDataSetId: string;
|
|
120
|
+
};
|
|
121
|
+
changes: {
|
|
122
|
+
fields: DataSetType['fields'];
|
|
123
|
+
runOptions?: Config['runOptions'];
|
|
124
|
+
};
|
|
125
|
+
};
|
|
115
126
|
export type Config = {
|
|
116
127
|
version: 1;
|
|
117
128
|
dataSets: DataSet[];
|
|
129
|
+
queryRoutingRules?: Array<QueryRoutingRule>;
|
|
118
130
|
executableDashboardConfigForPDF: string | null;
|
|
119
131
|
publicKeys: string[];
|
|
120
132
|
sqlViews: SqlViewStore;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vizzly/semantic-layer-public",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.244",
|
|
4
4
|
"source": "src/index.ts",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -21,10 +21,10 @@
|
|
|
21
21
|
"jest": "^29.7.0",
|
|
22
22
|
"ts-jest": "^29.1.2",
|
|
23
23
|
"typescript": "^5.4.5",
|
|
24
|
-
"@vizzly/sqlbuilder-public": "^0.1.
|
|
24
|
+
"@vizzly/sqlbuilder-public": "^0.1.80"
|
|
25
25
|
},
|
|
26
26
|
"peerDependencies": {
|
|
27
|
-
"@vizzly/sqlbuilder-public": ">=0.1.
|
|
27
|
+
"@vizzly/sqlbuilder-public": ">=0.1.80",
|
|
28
28
|
"@vizzly/joi": "^17.11.0"
|
|
29
29
|
}
|
|
30
30
|
}
|