@mastra/clickhouse 1.26.0-alpha.1 → 1.26.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.
@@ -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.26.0-alpha.1"
6
+ version: "1.26.0-alpha.2"
7
7
  ---
8
8
 
9
9
  ## When to use
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "1.26.0-alpha.1",
2
+ "version": "1.26.0-alpha.2",
3
3
  "package": "@mastra/clickhouse",
4
4
  "exports": {},
5
5
  "modules": {}
package/dist/index.cjs CHANGED
@@ -2743,6 +2743,7 @@ CREATE TABLE IF NOT EXISTS ${TABLE_SPAN_EVENTS} (
2743
2743
  isEvent Bool DEFAULT false,
2744
2744
  startedAt DateTime64(3, 'UTC'),
2745
2745
  endedAt DateTime64(3, 'UTC'),
2746
+ timeToFirstChunkMs Nullable(Float64),
2746
2747
 
2747
2748
  -- Query-relevant flexible fields
2748
2749
  tags Array(LowCardinality(String)) DEFAULT [],
@@ -2816,6 +2817,7 @@ CREATE TABLE IF NOT EXISTS ${TABLE_TRACE_ROOTS} (
2816
2817
  isEvent Bool DEFAULT false,
2817
2818
  startedAt DateTime64(3, 'UTC'),
2818
2819
  endedAt DateTime64(3, 'UTC'),
2820
+ timeToFirstChunkMs Nullable(Float64),
2819
2821
 
2820
2822
  -- Query-relevant flexible fields
2821
2823
  tags Array(LowCardinality(String)) DEFAULT [],
@@ -2901,6 +2903,7 @@ CREATE TABLE IF NOT EXISTS ${TABLE_TRACE_BRANCHES} (
2901
2903
  isEvent Bool DEFAULT false,
2902
2904
  startedAt DateTime64(3, 'UTC'),
2903
2905
  endedAt DateTime64(3, 'UTC'),
2906
+ timeToFirstChunkMs Nullable(Float64),
2904
2907
 
2905
2908
  -- Query-relevant flexible fields
2906
2909
  tags Array(LowCardinality(String)) DEFAULT [],
@@ -3706,7 +3709,10 @@ const ALL_MIGRATIONS = [
3706
3709
  addBloomIndex(TABLE_METRIC_EVENTS, "idx_sessionId", "sessionId"),
3707
3710
  addBloomIndex(TABLE_METRIC_EVENTS, "idx_requestId", "requestId"),
3708
3711
  ...LOG_SKIP_INDEX_COLUMNS.map((column) => addBloomIndex(TABLE_LOG_EVENTS, `idx_${column}`, column)),
3709
- addBloomIndex(TABLE_DELETION_REQUESTS, "idx_predicateValues", "predicateValues")
3712
+ addBloomIndex(TABLE_DELETION_REQUESTS, "idx_predicateValues", "predicateValues"),
3713
+ addColumn(TABLE_TRACE_ROOTS, "timeToFirstChunkMs", "Nullable(Float64)"),
3714
+ addColumn(TABLE_TRACE_BRANCHES, "timeToFirstChunkMs", "Nullable(Float64)"),
3715
+ addColumn(TABLE_SPAN_EVENTS, "timeToFirstChunkMs", "Nullable(Float64)")
3710
3716
  ];
3711
3717
  const ALL_TABLE_NAMES = [
3712
3718
  TABLE_SPAN_EVENTS,
@@ -4155,6 +4161,7 @@ function spanRecordToRow(span) {
4155
4161
  isEvent: span.isEvent,
4156
4162
  startedAt: toISOString(span.startedAt),
4157
4163
  endedAt: toISOString(endedAt),
4164
+ timeToFirstChunkMs: span.timeToFirstChunkMs ?? null,
4158
4165
  tags: normalizeTags(span.tags),
4159
4166
  metadataSearch: buildMetadataSearch(metadata),
4160
4167
  metadataRaw: jsonEncode(metadata),