@mastra/clickhouse 1.21.0-alpha.1 → 1.21.0-alpha.2
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/docs/SKILL.md +1 -1
- package/dist/docs/assets/SOURCE_MAP.json +1 -1
- package/dist/index.cjs +10 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +10 -1
- package/dist/index.js.map +1 -1
- package/dist/storage/domains/observability/v-next/index.d.ts +1 -1
- package/dist/storage/domains/observability/v-next/index.d.ts.map +1 -1
- package/dist/storage/domains/observability/v-next/trace-query.d.ts.map +1 -1
- package/package.json +3 -3
package/dist/docs/SKILL.md
CHANGED
|
@@ -3,7 +3,7 @@ name: mastra-clickhouse
|
|
|
3
3
|
description: Documentation for @mastra/clickhouse. Use when working with @mastra/clickhouse APIs, configuration, or implementation.
|
|
4
4
|
metadata:
|
|
5
5
|
package: "@mastra/clickhouse"
|
|
6
|
-
version: "1.21.0-alpha.
|
|
6
|
+
version: "1.21.0-alpha.2"
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
## When to use
|
package/dist/index.cjs
CHANGED
|
@@ -6516,6 +6516,9 @@ async function getScorePercentiles(client, args) {
|
|
|
6516
6516
|
//#endregion
|
|
6517
6517
|
//#region src/storage/domains/observability/v-next/trace-query.ts
|
|
6518
6518
|
const TRACE_STATUS_SQL = `if(isNotNull(r.error), 'error', 'success')`;
|
|
6519
|
+
function durationMsSql(startedAt, endedAt) {
|
|
6520
|
+
return `dateDiff('millisecond', ${startedAt}, ${endedAt})`;
|
|
6521
|
+
}
|
|
6519
6522
|
const TRACE_FIELDS = {
|
|
6520
6523
|
traceId: {
|
|
6521
6524
|
sql: "r.traceId",
|
|
@@ -6537,6 +6540,10 @@ const TRACE_FIELDS = {
|
|
|
6537
6540
|
sql: "r.endedAt",
|
|
6538
6541
|
parameterType: "DateTime64(3, 'UTC')"
|
|
6539
6542
|
},
|
|
6543
|
+
durationMs: {
|
|
6544
|
+
sql: durationMsSql("r.startedAt", "r.endedAt"),
|
|
6545
|
+
parameterType: "Float64"
|
|
6546
|
+
},
|
|
6540
6547
|
entityName: {
|
|
6541
6548
|
sql: "r.entityName",
|
|
6542
6549
|
parameterType: "String"
|
|
@@ -6861,7 +6868,7 @@ function compileClickHouseTraceScope(selection, relationCollections, parameters,
|
|
|
6861
6868
|
if(JSONType(attributes, 'provider') = 'String', JSONExtractString(attributes, 'provider'), NULL) AS provider,
|
|
6862
6869
|
startedAt,
|
|
6863
6870
|
endedAt,
|
|
6864
|
-
|
|
6871
|
+
${durationMsSql("startedAt", "endedAt")} AS durationMs,
|
|
6865
6872
|
if(isNotNull(error), 'error', 'success') AS status,
|
|
6866
6873
|
error,
|
|
6867
6874
|
entityType,
|
|
@@ -8566,6 +8573,7 @@ var ObservabilityStorageClickhouseVNext = class extends _mastra_core_storage.Obs
|
|
|
8566
8573
|
"metrics",
|
|
8567
8574
|
"logs",
|
|
8568
8575
|
"trace-query",
|
|
8576
|
+
"trace-query-root-duration",
|
|
8569
8577
|
"trace-query-discovery",
|
|
8570
8578
|
"thread-query",
|
|
8571
8579
|
"trace-query-tenant-scope"
|
|
@@ -8575,6 +8583,7 @@ var ObservabilityStorageClickhouseVNext = class extends _mastra_core_storage.Obs
|
|
|
8575
8583
|
"logs",
|
|
8576
8584
|
"delta-polling",
|
|
8577
8585
|
"trace-query",
|
|
8586
|
+
"trace-query-root-duration",
|
|
8578
8587
|
"trace-query-discovery",
|
|
8579
8588
|
"thread-query",
|
|
8580
8589
|
"trace-query-tenant-scope"
|