@mastra/mssql 1.0.0-beta.0 → 1.0.0-beta.10
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 +455 -0
- package/README.md +9 -0
- package/dist/docs/README.md +31 -0
- package/dist/docs/SKILL.md +32 -0
- package/dist/docs/SOURCE_MAP.json +6 -0
- package/dist/docs/storage/01-reference.md +141 -0
- package/dist/index.cjs +2521 -2071
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +2518 -2072
- package/dist/index.js.map +1 -1
- package/dist/storage/{domains/operations → db}/index.d.ts +73 -15
- package/dist/storage/db/index.d.ts.map +1 -0
- package/dist/storage/db/utils.d.ts +21 -0
- package/dist/storage/db/utils.d.ts.map +1 -0
- package/dist/storage/domains/memory/index.d.ts +25 -10
- package/dist/storage/domains/memory/index.d.ts.map +1 -1
- package/dist/storage/domains/observability/index.d.ts +32 -30
- package/dist/storage/domains/observability/index.d.ts.map +1 -1
- package/dist/storage/domains/scores/index.d.ts +30 -26
- package/dist/storage/domains/scores/index.d.ts.map +1 -1
- package/dist/storage/domains/utils.d.ts +2 -2
- package/dist/storage/domains/utils.d.ts.map +1 -1
- package/dist/storage/domains/workflows/index.d.ts +32 -17
- package/dist/storage/domains/workflows/index.d.ts.map +1 -1
- package/dist/storage/index.d.ts +114 -204
- package/dist/storage/index.d.ts.map +1 -1
- package/package.json +10 -8
- package/dist/storage/domains/operations/index.d.ts.map +0 -1
package/dist/storage/index.d.ts
CHANGED
|
@@ -1,17 +1,98 @@
|
|
|
1
|
-
import type { MastraMessageContentV2, MastraDBMessage } from '@mastra/core/agent';
|
|
2
|
-
import type { ScoreRowData, ScoringSource } from '@mastra/core/evals';
|
|
3
|
-
import type { StorageThreadType } from '@mastra/core/memory';
|
|
4
1
|
import { MastraStorage } from '@mastra/core/storage';
|
|
5
|
-
|
|
6
|
-
content: MastraMessageContentV2;
|
|
7
|
-
};
|
|
8
|
-
import type { PaginationInfo, StorageColumn, StorageResourceType, TABLE_NAMES, WorkflowRun, WorkflowRuns, StoragePagination, StorageDomains, SpanRecord, TraceRecord, TracesPaginatedArg, UpdateSpanRecord, CreateIndexOptions, IndexInfo, StorageIndexStats, StorageListWorkflowRunsInput } from '@mastra/core/storage';
|
|
9
|
-
import type { StepResult, WorkflowRunState } from '@mastra/core/workflows';
|
|
2
|
+
import type { StorageDomains, CreateIndexOptions } from '@mastra/core/storage';
|
|
10
3
|
import sql from 'mssql';
|
|
4
|
+
import { MemoryMSSQL } from './domains/memory/index.js';
|
|
5
|
+
import { ObservabilityMSSQL } from './domains/observability/index.js';
|
|
6
|
+
import { ScoresMSSQL } from './domains/scores/index.js';
|
|
7
|
+
import { WorkflowsMSSQL } from './domains/workflows/index.js';
|
|
8
|
+
export { MemoryMSSQL, ObservabilityMSSQL, ScoresMSSQL, WorkflowsMSSQL };
|
|
9
|
+
export type { MssqlDomainConfig } from './db/index.js';
|
|
10
|
+
/**
|
|
11
|
+
* MSSQL configuration type.
|
|
12
|
+
*
|
|
13
|
+
* Accepts either:
|
|
14
|
+
* - A pre-configured connection pool: `{ id, pool, schemaName? }`
|
|
15
|
+
* - Connection string: `{ id, connectionString, ... }`
|
|
16
|
+
* - Server/port config: `{ id, server, port, database, user, password, ... }`
|
|
17
|
+
*/
|
|
11
18
|
export type MSSQLConfigType = {
|
|
12
19
|
id: string;
|
|
13
20
|
schemaName?: string;
|
|
21
|
+
/**
|
|
22
|
+
* When true, automatic initialization (table creation/migrations) is disabled.
|
|
23
|
+
* This is useful for CI/CD pipelines where you want to:
|
|
24
|
+
* 1. Run migrations explicitly during deployment (not at runtime)
|
|
25
|
+
* 2. Use different credentials for schema changes vs runtime operations
|
|
26
|
+
*
|
|
27
|
+
* When disableInit is true:
|
|
28
|
+
* - The storage will not automatically create/alter tables on first use
|
|
29
|
+
* - You must call `storage.init()` explicitly in your CI/CD scripts
|
|
30
|
+
*
|
|
31
|
+
* @example
|
|
32
|
+
* // In CI/CD script:
|
|
33
|
+
* const storage = new MSSQLStore({ ...config, disableInit: false });
|
|
34
|
+
* await storage.init(); // Explicitly run migrations
|
|
35
|
+
*
|
|
36
|
+
* // In runtime application:
|
|
37
|
+
* const storage = new MSSQLStore({ ...config, disableInit: true });
|
|
38
|
+
* // No auto-init, tables must already exist
|
|
39
|
+
*/
|
|
40
|
+
disableInit?: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* When true, default indexes will not be created during initialization.
|
|
43
|
+
* This is useful when:
|
|
44
|
+
* 1. You want to manage indexes separately or use custom indexes only
|
|
45
|
+
* 2. Default indexes don't match your query patterns
|
|
46
|
+
* 3. You want to reduce initialization time in development
|
|
47
|
+
*
|
|
48
|
+
* @default false
|
|
49
|
+
*/
|
|
50
|
+
skipDefaultIndexes?: boolean;
|
|
51
|
+
/**
|
|
52
|
+
* Custom indexes to create during initialization.
|
|
53
|
+
* These indexes are created in addition to default indexes (unless skipDefaultIndexes is true).
|
|
54
|
+
*
|
|
55
|
+
* Each index must specify which table it belongs to. The store will route each index
|
|
56
|
+
* to the appropriate domain based on the table name.
|
|
57
|
+
*
|
|
58
|
+
* @example
|
|
59
|
+
* ```typescript
|
|
60
|
+
* const store = new MSSQLStore({
|
|
61
|
+
* connectionString: '...',
|
|
62
|
+
* indexes: [
|
|
63
|
+
* { name: 'my_threads_type_idx', table: 'mastra_threads', columns: ['JSON_VALUE(metadata, \'$.type\')'] },
|
|
64
|
+
* ],
|
|
65
|
+
* });
|
|
66
|
+
* ```
|
|
67
|
+
*/
|
|
68
|
+
indexes?: CreateIndexOptions[];
|
|
14
69
|
} & ({
|
|
70
|
+
/**
|
|
71
|
+
* Pre-configured mssql ConnectionPool.
|
|
72
|
+
* Use this when you need to configure the pool before initialization,
|
|
73
|
+
* e.g., to add pool listeners or set connection-level settings.
|
|
74
|
+
*
|
|
75
|
+
* @example
|
|
76
|
+
* ```typescript
|
|
77
|
+
* import sql from 'mssql';
|
|
78
|
+
*
|
|
79
|
+
* const pool = new sql.ConnectionPool({
|
|
80
|
+
* server: 'localhost',
|
|
81
|
+
* database: 'mydb',
|
|
82
|
+
* user: 'user',
|
|
83
|
+
* password: 'password',
|
|
84
|
+
* });
|
|
85
|
+
*
|
|
86
|
+
* // Custom setup before using
|
|
87
|
+
* pool.on('connect', () => {
|
|
88
|
+
* console.log('Pool connected');
|
|
89
|
+
* });
|
|
90
|
+
*
|
|
91
|
+
* const store = new MSSQLStore({ id: 'my-store', pool });
|
|
92
|
+
* ```
|
|
93
|
+
*/
|
|
94
|
+
pool: sql.ConnectionPool;
|
|
95
|
+
} | {
|
|
15
96
|
server: string;
|
|
16
97
|
port: number;
|
|
17
98
|
database: string;
|
|
@@ -22,6 +103,28 @@ export type MSSQLConfigType = {
|
|
|
22
103
|
connectionString: string;
|
|
23
104
|
});
|
|
24
105
|
export type MSSQLConfig = MSSQLConfigType;
|
|
106
|
+
/**
|
|
107
|
+
* MSSQL storage adapter for Mastra.
|
|
108
|
+
*
|
|
109
|
+
* Access domain-specific storage via `getStore()`:
|
|
110
|
+
*
|
|
111
|
+
* @example
|
|
112
|
+
* ```typescript
|
|
113
|
+
* const storage = new MSSQLStore({ id: 'my-store', connectionString: '...' });
|
|
114
|
+
*
|
|
115
|
+
* // Access memory domain
|
|
116
|
+
* const memory = await storage.getStore('memory');
|
|
117
|
+
* await memory?.saveThread({ thread });
|
|
118
|
+
*
|
|
119
|
+
* // Access workflows domain
|
|
120
|
+
* const workflows = await storage.getStore('workflows');
|
|
121
|
+
* await workflows?.persistWorkflowSnapshot({ workflowName, runId, snapshot });
|
|
122
|
+
*
|
|
123
|
+
* // Access observability domain
|
|
124
|
+
* const observability = await storage.getStore('observability');
|
|
125
|
+
* await observability?.createSpan(span);
|
|
126
|
+
* ```
|
|
127
|
+
*/
|
|
25
128
|
export declare class MSSQLStore extends MastraStorage {
|
|
26
129
|
pool: sql.ConnectionPool;
|
|
27
130
|
private schema?;
|
|
@@ -30,204 +133,11 @@ export declare class MSSQLStore extends MastraStorage {
|
|
|
30
133
|
constructor(config: MSSQLConfigType);
|
|
31
134
|
init(): Promise<void>;
|
|
32
135
|
private _performInitializationAndStore;
|
|
33
|
-
get supports(): {
|
|
34
|
-
selectByIncludeResourceScope: boolean;
|
|
35
|
-
resourceWorkingMemory: boolean;
|
|
36
|
-
hasColumn: boolean;
|
|
37
|
-
createTable: boolean;
|
|
38
|
-
deleteMessages: boolean;
|
|
39
|
-
listScoresBySpan: boolean;
|
|
40
|
-
observabilityInstance: boolean;
|
|
41
|
-
indexManagement: boolean;
|
|
42
|
-
};
|
|
43
|
-
createTable({ tableName, schema, }: {
|
|
44
|
-
tableName: TABLE_NAMES;
|
|
45
|
-
schema: Record<string, StorageColumn>;
|
|
46
|
-
}): Promise<void>;
|
|
47
|
-
alterTable({ tableName, schema, ifNotExists, }: {
|
|
48
|
-
tableName: TABLE_NAMES;
|
|
49
|
-
schema: Record<string, StorageColumn>;
|
|
50
|
-
ifNotExists: string[];
|
|
51
|
-
}): Promise<void>;
|
|
52
|
-
clearTable({ tableName }: {
|
|
53
|
-
tableName: TABLE_NAMES;
|
|
54
|
-
}): Promise<void>;
|
|
55
|
-
dropTable({ tableName }: {
|
|
56
|
-
tableName: TABLE_NAMES;
|
|
57
|
-
}): Promise<void>;
|
|
58
|
-
insert({ tableName, record }: {
|
|
59
|
-
tableName: TABLE_NAMES;
|
|
60
|
-
record: Record<string, any>;
|
|
61
|
-
}): Promise<void>;
|
|
62
|
-
batchInsert({ tableName, records }: {
|
|
63
|
-
tableName: TABLE_NAMES;
|
|
64
|
-
records: Record<string, any>[];
|
|
65
|
-
}): Promise<void>;
|
|
66
|
-
load<R>({ tableName, keys }: {
|
|
67
|
-
tableName: TABLE_NAMES;
|
|
68
|
-
keys: Record<string, string>;
|
|
69
|
-
}): Promise<R | null>;
|
|
70
|
-
/**
|
|
71
|
-
* Memory
|
|
72
|
-
*/
|
|
73
|
-
getThreadById({ threadId }: {
|
|
74
|
-
threadId: string;
|
|
75
|
-
}): Promise<StorageThreadType | null>;
|
|
76
|
-
saveThread({ thread }: {
|
|
77
|
-
thread: StorageThreadType;
|
|
78
|
-
}): Promise<StorageThreadType>;
|
|
79
|
-
updateThread({ id, title, metadata, }: {
|
|
80
|
-
id: string;
|
|
81
|
-
title: string;
|
|
82
|
-
metadata: Record<string, unknown>;
|
|
83
|
-
}): Promise<StorageThreadType>;
|
|
84
|
-
deleteThread({ threadId }: {
|
|
85
|
-
threadId: string;
|
|
86
|
-
}): Promise<void>;
|
|
87
|
-
listMessagesById({ messageIds }: {
|
|
88
|
-
messageIds: string[];
|
|
89
|
-
}): Promise<{
|
|
90
|
-
messages: MastraDBMessage[];
|
|
91
|
-
}>;
|
|
92
|
-
saveMessages(args: {
|
|
93
|
-
messages: MastraDBMessage[];
|
|
94
|
-
}): Promise<{
|
|
95
|
-
messages: MastraDBMessage[];
|
|
96
|
-
}>;
|
|
97
|
-
updateMessages({ messages, }: {
|
|
98
|
-
messages: (Partial<Omit<MastraDBMessage, 'createdAt'>> & {
|
|
99
|
-
id: string;
|
|
100
|
-
content?: {
|
|
101
|
-
metadata?: MastraMessageContentV2['metadata'];
|
|
102
|
-
content?: MastraMessageContentV2['content'];
|
|
103
|
-
};
|
|
104
|
-
})[];
|
|
105
|
-
}): Promise<MastraDBMessage[]>;
|
|
106
|
-
deleteMessages(messageIds: string[]): Promise<void>;
|
|
107
|
-
getResourceById({ resourceId }: {
|
|
108
|
-
resourceId: string;
|
|
109
|
-
}): Promise<StorageResourceType | null>;
|
|
110
|
-
saveResource({ resource }: {
|
|
111
|
-
resource: StorageResourceType;
|
|
112
|
-
}): Promise<StorageResourceType>;
|
|
113
|
-
updateResource({ resourceId, workingMemory, metadata, }: {
|
|
114
|
-
resourceId: string;
|
|
115
|
-
workingMemory?: string;
|
|
116
|
-
metadata?: Record<string, unknown>;
|
|
117
|
-
}): Promise<StorageResourceType>;
|
|
118
136
|
/**
|
|
119
|
-
*
|
|
137
|
+
* Closes the MSSQL connection pool.
|
|
138
|
+
*
|
|
139
|
+
* This will close the connection pool, including pre-configured pools.
|
|
120
140
|
*/
|
|
121
|
-
updateWorkflowResults({ workflowName, runId, stepId, result, requestContext, }: {
|
|
122
|
-
workflowName: string;
|
|
123
|
-
runId: string;
|
|
124
|
-
stepId: string;
|
|
125
|
-
result: StepResult<any, any, any, any>;
|
|
126
|
-
requestContext: Record<string, any>;
|
|
127
|
-
}): Promise<Record<string, StepResult<any, any, any, any>>>;
|
|
128
|
-
updateWorkflowState({ workflowName, runId, opts, }: {
|
|
129
|
-
workflowName: string;
|
|
130
|
-
runId: string;
|
|
131
|
-
opts: {
|
|
132
|
-
status: string;
|
|
133
|
-
result?: StepResult<any, any, any, any>;
|
|
134
|
-
error?: string;
|
|
135
|
-
suspendedPaths?: Record<string, number[]>;
|
|
136
|
-
waitingPaths?: Record<string, number[]>;
|
|
137
|
-
};
|
|
138
|
-
}): Promise<WorkflowRunState | undefined>;
|
|
139
|
-
persistWorkflowSnapshot({ workflowName, runId, resourceId, snapshot, }: {
|
|
140
|
-
workflowName: string;
|
|
141
|
-
runId: string;
|
|
142
|
-
resourceId?: string;
|
|
143
|
-
snapshot: WorkflowRunState;
|
|
144
|
-
}): Promise<void>;
|
|
145
|
-
loadWorkflowSnapshot({ workflowName, runId, }: {
|
|
146
|
-
workflowName: string;
|
|
147
|
-
runId: string;
|
|
148
|
-
}): Promise<WorkflowRunState | null>;
|
|
149
|
-
listWorkflowRuns({ workflowName, fromDate, toDate, perPage, page, resourceId, }?: StorageListWorkflowRunsInput): Promise<WorkflowRuns>;
|
|
150
|
-
getWorkflowRunById({ runId, workflowName, }: {
|
|
151
|
-
runId: string;
|
|
152
|
-
workflowName?: string;
|
|
153
|
-
}): Promise<WorkflowRun | null>;
|
|
154
141
|
close(): Promise<void>;
|
|
155
|
-
/**
|
|
156
|
-
* Index Management
|
|
157
|
-
*/
|
|
158
|
-
createIndex(options: CreateIndexOptions): Promise<void>;
|
|
159
|
-
listIndexes(tableName?: string): Promise<IndexInfo[]>;
|
|
160
|
-
describeIndex(indexName: string): Promise<StorageIndexStats>;
|
|
161
|
-
dropIndex(indexName: string): Promise<void>;
|
|
162
|
-
/**
|
|
163
|
-
* Tracing / Observability
|
|
164
|
-
*/
|
|
165
|
-
private getObservabilityStore;
|
|
166
|
-
createSpan(span: SpanRecord): Promise<void>;
|
|
167
|
-
updateSpan({ spanId, traceId, updates, }: {
|
|
168
|
-
spanId: string;
|
|
169
|
-
traceId: string;
|
|
170
|
-
updates: Partial<UpdateSpanRecord>;
|
|
171
|
-
}): Promise<void>;
|
|
172
|
-
getTrace(traceId: string): Promise<TraceRecord | null>;
|
|
173
|
-
getTracesPaginated(args: TracesPaginatedArg): Promise<{
|
|
174
|
-
pagination: PaginationInfo;
|
|
175
|
-
spans: SpanRecord[];
|
|
176
|
-
}>;
|
|
177
|
-
batchCreateSpans(args: {
|
|
178
|
-
records: SpanRecord[];
|
|
179
|
-
}): Promise<void>;
|
|
180
|
-
batchUpdateSpans(args: {
|
|
181
|
-
records: {
|
|
182
|
-
traceId: string;
|
|
183
|
-
spanId: string;
|
|
184
|
-
updates: Partial<UpdateSpanRecord>;
|
|
185
|
-
}[];
|
|
186
|
-
}): Promise<void>;
|
|
187
|
-
batchDeleteTraces(args: {
|
|
188
|
-
traceIds: string[];
|
|
189
|
-
}): Promise<void>;
|
|
190
|
-
/**
|
|
191
|
-
* Scorers
|
|
192
|
-
*/
|
|
193
|
-
getScoreById({ id: _id }: {
|
|
194
|
-
id: string;
|
|
195
|
-
}): Promise<ScoreRowData | null>;
|
|
196
|
-
listScoresByScorerId({ scorerId: _scorerId, pagination: _pagination, entityId: _entityId, entityType: _entityType, source: _source, }: {
|
|
197
|
-
scorerId: string;
|
|
198
|
-
pagination: StoragePagination;
|
|
199
|
-
entityId?: string;
|
|
200
|
-
entityType?: string;
|
|
201
|
-
source?: ScoringSource;
|
|
202
|
-
}): Promise<{
|
|
203
|
-
pagination: PaginationInfo;
|
|
204
|
-
scores: ScoreRowData[];
|
|
205
|
-
}>;
|
|
206
|
-
saveScore(_score: ScoreRowData): Promise<{
|
|
207
|
-
score: ScoreRowData;
|
|
208
|
-
}>;
|
|
209
|
-
listScoresByRunId({ runId: _runId, pagination: _pagination, }: {
|
|
210
|
-
runId: string;
|
|
211
|
-
pagination: StoragePagination;
|
|
212
|
-
}): Promise<{
|
|
213
|
-
pagination: PaginationInfo;
|
|
214
|
-
scores: ScoreRowData[];
|
|
215
|
-
}>;
|
|
216
|
-
listScoresByEntityId({ entityId: _entityId, entityType: _entityType, pagination: _pagination, }: {
|
|
217
|
-
pagination: StoragePagination;
|
|
218
|
-
entityId: string;
|
|
219
|
-
entityType: string;
|
|
220
|
-
}): Promise<{
|
|
221
|
-
pagination: PaginationInfo;
|
|
222
|
-
scores: ScoreRowData[];
|
|
223
|
-
}>;
|
|
224
|
-
listScoresBySpan({ traceId, spanId, pagination: _pagination, }: {
|
|
225
|
-
traceId: string;
|
|
226
|
-
spanId: string;
|
|
227
|
-
pagination: StoragePagination;
|
|
228
|
-
}): Promise<{
|
|
229
|
-
pagination: PaginationInfo;
|
|
230
|
-
scores: ScoreRowData[];
|
|
231
|
-
}>;
|
|
232
142
|
}
|
|
233
143
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/storage/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/storage/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAwB,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAC3E,OAAO,KAAK,EAAE,cAAc,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE/E,OAAO,GAAG,MAAM,OAAO,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,WAAW,E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;;;OAIG;IACG,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC;CAG7B"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mastra/mssql",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.10",
|
|
4
4
|
"description": "MSSQL provider for Mastra - db storage capabilities",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -23,16 +23,17 @@
|
|
|
23
23
|
"mssql": "^11.0.1"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@microsoft/api-extractor": "^7.52.8",
|
|
27
26
|
"@types/mssql": "^9.1.8",
|
|
28
|
-
"@types/node": "
|
|
27
|
+
"@types/node": "22.13.17",
|
|
28
|
+
"@vitest/coverage-v8": "4.0.12",
|
|
29
|
+
"@vitest/ui": "4.0.12",
|
|
29
30
|
"eslint": "^9.37.0",
|
|
30
31
|
"tsup": "^8.5.0",
|
|
31
|
-
"typescript": "^5.
|
|
32
|
-
"vitest": "
|
|
33
|
-
"@internal/lint": "0.0.53",
|
|
32
|
+
"typescript": "^5.9.3",
|
|
33
|
+
"vitest": "4.0.16",
|
|
34
34
|
"@internal/storage-test-utils": "0.0.49",
|
|
35
|
-
"@mastra/core": "1.0.0-beta.
|
|
35
|
+
"@mastra/core": "1.0.0-beta.20",
|
|
36
|
+
"@internal/lint": "0.0.53",
|
|
36
37
|
"@internal/types-builder": "0.0.28"
|
|
37
38
|
},
|
|
38
39
|
"peerDependencies": {
|
|
@@ -55,7 +56,8 @@
|
|
|
55
56
|
"node": ">=22.13.0"
|
|
56
57
|
},
|
|
57
58
|
"scripts": {
|
|
58
|
-
"build": "tsup --silent --config tsup.config.ts",
|
|
59
|
+
"build:lib": "tsup --silent --config tsup.config.ts",
|
|
60
|
+
"build:docs": "pnpx tsx ../../scripts/generate-package-docs.ts stores/mssql",
|
|
59
61
|
"build:watch": "tsup --watch --silent --config tsup.config.ts",
|
|
60
62
|
"pretest": "docker compose up -d && (for i in $(seq 1 30); do docker compose ps | grep mssql && break || sleep 1; done) && (for i in $(seq 1 30); do docker inspect --format='{{.State.Health.Status}}' $(docker compose ps -q mssql) | grep healthy && break || sleep 2; done)",
|
|
61
63
|
"test": "vitest run",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/storage/domains/operations/index.ts"],"names":[],"mappings":"AACA,OAAO,EACL,eAAe,EAQhB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,KAAK,EACV,aAAa,EACb,WAAW,EACX,kBAAkB,EAClB,SAAS,EACT,iBAAiB,EAClB,MAAM,sBAAsB,CAAC;AAE9B,OAAO,GAAG,MAAM,OAAO,CAAC;AAIxB,YAAY,EAAE,kBAAkB,EAAE,SAAS,EAAE,iBAAiB,EAAE,CAAC;AAEjE,qBAAa,oBAAqB,SAAQ,eAAe;IAChD,IAAI,EAAE,GAAG,CAAC,cAAc,CAAC;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC;IAC3B,OAAO,CAAC,kBAAkB,CAA8B;IACxD,OAAO,CAAC,mBAAmB,CAAkC;IAE7D,SAAS,CAAC,UAAU,CAAC,IAAI,EAAE,aAAa,CAAC,MAAM,CAAC,EAAE,YAAY,UAAQ,EAAE,eAAe,UAAQ,GAAG,MAAM;gBAmC5F,EAAE,IAAI,EAAE,UAAU,EAAE,EAAE;QAAE,IAAI,EAAE,GAAG,CAAC,cAAc,CAAC;QAAC,UAAU,CAAC,EAAE,MAAM,CAAA;KAAE;IAM7E,SAAS,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;YAalD,WAAW;IA2CnB,MAAM,CAAC,EACX,SAAS,EACT,MAAM,EACN,WAAW,GACZ,EAAE;QACD,SAAS,EAAE,WAAW,CAAC;QACvB,MAAM,EAAE,MAAM,CAAC,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