@mastra/mssql 1.2.1-alpha.0 → 1.2.1-alpha.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/CHANGELOG.md CHANGED
@@ -1,5 +1,14 @@
1
1
  # @mastra/mssql
2
2
 
3
+ ## 1.2.1-alpha.1
4
+
5
+ ### Patch Changes
6
+
7
+ - Added `getTraceLight` method to the observability storage, returning only lightweight span fields needed for timeline rendering. This avoids transferring heavy fields like `input`, `output`, `attributes`, and `metadata` when they are not needed. ([#15574](https://github.com/mastra-ai/mastra/pull/15574))
8
+
9
+ - Updated dependencies [[`20f59b8`](https://github.com/mastra-ai/mastra/commit/20f59b876cf91199efbc49a0e36b391240708f08), [`e2687a7`](https://github.com/mastra-ai/mastra/commit/e2687a7408790c384563816a9a28ed06735684c9), [`8f1b280`](https://github.com/mastra-ai/mastra/commit/8f1b280b7fe6999ec654f160cb69c1a8719e7a57), [`12df98c`](https://github.com/mastra-ai/mastra/commit/12df98c4904643d9481f5c78f3bed443725b4c96)]:
10
+ - @mastra/core@1.26.0-alpha.11
11
+
3
12
  ## 1.2.1-alpha.0
4
13
 
5
14
  ### Patch Changes
@@ -3,7 +3,7 @@ name: mastra-mssql
3
3
  description: Documentation for @mastra/mssql. Use when working with @mastra/mssql APIs, configuration, or implementation.
4
4
  metadata:
5
5
  package: "@mastra/mssql"
6
- version: "1.2.1-alpha.0"
6
+ version: "1.2.1-alpha.1"
7
7
  ---
8
8
 
9
9
  ## When to use
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "1.2.1-alpha.0",
2
+ "version": "1.2.1-alpha.1",
3
3
  "package": "@mastra/mssql",
4
4
  "exports": {},
5
5
  "modules": {}
package/dist/index.cjs CHANGED
@@ -2942,6 +2942,51 @@ var ObservabilityMSSQL = class _ObservabilityMSSQL extends storage.Observability
2942
2942
  );
2943
2943
  }
2944
2944
  }
2945
+ async getTraceLight(args) {
2946
+ const { traceId } = args;
2947
+ try {
2948
+ const tableName = getTableName2({
2949
+ indexName: storage.TABLE_SPANS,
2950
+ schemaName: getSchemaName2(this.schema)
2951
+ });
2952
+ const request = this.pool.request();
2953
+ request.input("traceId", traceId);
2954
+ const result = await request.query(
2955
+ `SELECT
2956
+ [traceId], [spanId], [parentSpanId], [name],
2957
+ [entityType], [entityId], [entityName],
2958
+ [spanType], [error], [isEvent],
2959
+ [startedAt], [endedAt], [createdAt], [updatedAt]
2960
+ FROM ${tableName}
2961
+ WHERE [traceId] = @traceId
2962
+ ORDER BY [startedAt] ASC`
2963
+ );
2964
+ if (!result.recordset || result.recordset.length === 0) {
2965
+ return null;
2966
+ }
2967
+ return {
2968
+ traceId,
2969
+ spans: result.recordset.map(
2970
+ (span) => transformFromSqlRow({
2971
+ tableName: storage.TABLE_SPANS,
2972
+ sqlRow: span
2973
+ })
2974
+ )
2975
+ };
2976
+ } catch (error$1) {
2977
+ throw new error.MastraError(
2978
+ {
2979
+ id: storage.createStorageErrorId("MSSQL", "GET_TRACE_LIGHT", "FAILED"),
2980
+ domain: error.ErrorDomain.STORAGE,
2981
+ category: error.ErrorCategory.USER,
2982
+ details: {
2983
+ traceId
2984
+ }
2985
+ },
2986
+ error$1
2987
+ );
2988
+ }
2989
+ }
2945
2990
  async getSpan(args) {
2946
2991
  const { traceId, spanId } = args;
2947
2992
  try {