@mastra/mssql 1.7.0-alpha.1 → 1.7.0-alpha.3
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 +30 -0
- package/dist/docs/SKILL.md +3 -3
- package/dist/docs/assets/SOURCE_MAP.json +1 -1
- package/dist/docs/references/{reference-storage-mssql.md → integrations-databases-mssql.md} +1 -1
- package/dist/index.cjs +5 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +5 -4
- package/dist/index.js.map +1 -1
- package/dist/storage/domains/memory/index.d.ts +3 -2
- package/dist/storage/domains/memory/index.d.ts.map +1 -1
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,35 @@
|
|
|
1
1
|
# @mastra/mssql
|
|
2
2
|
|
|
3
|
+
## 1.7.0-alpha.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Fixed a crash where updating a thread without a title (for example during observational memory buffering) could write a null title and violate the database's not-null constraint when running a newer @mastra/memory against an older storage package. Memory now checks whether the connected storage adapter supports partial thread updates and backfills the existing title for older adapters, so mixed-version deployments keep working. See #21041 for the original title-clobbering fix this makes backward compatible. ([#21257](https://github.com/mastra-ai/mastra/pull/21257))
|
|
8
|
+
|
|
9
|
+
- Storage adapters now declare support for partial thread updates, letting newer @mastra/memory preserve existing thread titles instead of overwriting them, while remaining safe against older versions. ([#21257](https://github.com/mastra-ai/mastra/pull/21257))
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [[`dc4a25d`](https://github.com/mastra-ai/mastra/commit/dc4a25d41af4e2fe97a816070eaec6aa963ab53b), [`dc4a25d`](https://github.com/mastra-ai/mastra/commit/dc4a25d41af4e2fe97a816070eaec6aa963ab53b)]:
|
|
12
|
+
- @mastra/core@1.58.0-alpha.15
|
|
13
|
+
|
|
14
|
+
## 1.7.0-alpha.2
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- Fixed generated thread titles being clobbered during a turn ([#21041](https://github.com/mastra-ai/mastra/pull/21041))
|
|
19
|
+
|
|
20
|
+
`updateThread` required both `title` and `metadata`, so callers that only needed to
|
|
21
|
+
change metadata (message persistence, working memory, observational memory, channel
|
|
22
|
+
subscriptions) had to read the thread and pass its title back. When title generation
|
|
23
|
+
finished between that read and the write, the freshly generated title was overwritten
|
|
24
|
+
with the stale one.
|
|
25
|
+
|
|
26
|
+
`title` and `metadata` are now independently optional: omitting one leaves that column
|
|
27
|
+
untouched. Callers that only change metadata no longer send a title, and message
|
|
28
|
+
persistence no longer rewrites a thread row it just read.
|
|
29
|
+
|
|
30
|
+
- Updated dependencies [[`1c75e32`](https://github.com/mastra-ai/mastra/commit/1c75e32f7fc0b9fb6f548b4407feaec8a1440212), [`c47165c`](https://github.com/mastra-ai/mastra/commit/c47165c983c87594c6952f1fd2fa51a90205034c), [`e08e789`](https://github.com/mastra-ai/mastra/commit/e08e789c1bf4cd2fe46363f7a4728536ceccc9bd), [`35cc901`](https://github.com/mastra-ai/mastra/commit/35cc90102cf834a84827acaf9eee0b6d6d1e2a3b), [`a8b4cf0`](https://github.com/mastra-ai/mastra/commit/a8b4cf02823cffebc4751a53337dfacf097c1ae1), [`f33264f`](https://github.com/mastra-ai/mastra/commit/f33264f517ae603279afd5c4251e2b40f6dd3618), [`689f2c4`](https://github.com/mastra-ai/mastra/commit/689f2c4b6c0835fe455702b01d21daa8abcd9331), [`eeae63e`](https://github.com/mastra-ai/mastra/commit/eeae63e7fbe8e1f237adc69bca6e2ac13c5ca907), [`4c186a0`](https://github.com/mastra-ai/mastra/commit/4c186a017275f45e6ed4c09de0f89550e2d09e8c), [`b0fa077`](https://github.com/mastra-ai/mastra/commit/b0fa077bcbc9b08551846fe372a0d3d15b71ed72)]:
|
|
31
|
+
- @mastra/core@1.58.0-alpha.8
|
|
32
|
+
|
|
3
33
|
## 1.7.0-alpha.1
|
|
4
34
|
|
|
5
35
|
### Patch Changes
|
package/dist/docs/SKILL.md
CHANGED
|
@@ -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.7.0-alpha.
|
|
6
|
+
version: "1.7.0-alpha.3"
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
## When to use
|
|
@@ -14,9 +14,9 @@ Use this skill whenever you are working with @mastra/mssql to obtain the domain-
|
|
|
14
14
|
|
|
15
15
|
Read the individual reference documents for detailed explanations and code examples.
|
|
16
16
|
|
|
17
|
-
###
|
|
17
|
+
### Integrations
|
|
18
18
|
|
|
19
|
-
- [
|
|
19
|
+
- [MSSQL](references/integrations-databases-mssql.md) - Documentation for the MSSQL storage implementation in Mastra.
|
|
20
20
|
|
|
21
21
|
|
|
22
22
|
Read [assets/SOURCE_MAP.json](assets/SOURCE_MAP.json) for source code references.
|
package/dist/index.cjs
CHANGED
|
@@ -2114,6 +2114,7 @@ function buildMssqlMessageMetadataFilter(metadataFilter) {
|
|
|
2114
2114
|
};
|
|
2115
2115
|
}
|
|
2116
2116
|
var MemoryMSSQL = class MemoryMSSQL extends _mastra_core_storage.MemoryStorage {
|
|
2117
|
+
supportsPartialThreadUpdate = true;
|
|
2117
2118
|
pool;
|
|
2118
2119
|
schema;
|
|
2119
2120
|
db;
|
|
@@ -2416,7 +2417,7 @@ var MemoryMSSQL = class MemoryMSSQL extends _mastra_core_storage.MemoryStorage {
|
|
|
2416
2417
|
text: `Thread ${id} not found`,
|
|
2417
2418
|
details: {
|
|
2418
2419
|
threadId: id,
|
|
2419
|
-
title
|
|
2420
|
+
title: title ?? null
|
|
2420
2421
|
}
|
|
2421
2422
|
});
|
|
2422
2423
|
const mergedMetadata = {
|
|
@@ -2435,7 +2436,7 @@ var MemoryMSSQL = class MemoryMSSQL extends _mastra_core_storage.MemoryStorage {
|
|
|
2435
2436
|
WHERE id = @id`;
|
|
2436
2437
|
const req = this.pool.request();
|
|
2437
2438
|
req.input("id", id);
|
|
2438
|
-
req.input("title", title);
|
|
2439
|
+
req.input("title", title ?? existingThread.title);
|
|
2439
2440
|
req.input("metadata", JSON.stringify(mergedMetadata));
|
|
2440
2441
|
req.input("updatedAt", /* @__PURE__ */ new Date());
|
|
2441
2442
|
const result = await req.query(sql);
|
|
@@ -2451,7 +2452,7 @@ var MemoryMSSQL = class MemoryMSSQL extends _mastra_core_storage.MemoryStorage {
|
|
|
2451
2452
|
text: `Thread ${id} not found after update`,
|
|
2452
2453
|
details: {
|
|
2453
2454
|
threadId: id,
|
|
2454
|
-
title
|
|
2455
|
+
title: title ?? null
|
|
2455
2456
|
}
|
|
2456
2457
|
});
|
|
2457
2458
|
return {
|
|
@@ -2467,7 +2468,7 @@ var MemoryMSSQL = class MemoryMSSQL extends _mastra_core_storage.MemoryStorage {
|
|
|
2467
2468
|
category: _mastra_core_error.ErrorCategory.THIRD_PARTY,
|
|
2468
2469
|
details: {
|
|
2469
2470
|
threadId: id,
|
|
2470
|
-
title
|
|
2471
|
+
title: title ?? null
|
|
2471
2472
|
}
|
|
2472
2473
|
}, error);
|
|
2473
2474
|
}
|