@sqlbraid/core 0.1.0-rc.1 → 1.0.0
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/README.md +11 -27
- package/dist/driver.d.ts +16 -0
- package/dist/driver.d.ts.map +1 -0
- package/dist/driver.js +93 -0
- package/dist/driver.js.map +1 -0
- package/dist/index.d.ts +252 -13
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +677 -10
- package/dist/index.js.map +1 -1
- package/package.json +22 -18
package/README.md
CHANGED
|
@@ -1,36 +1,20 @@
|
|
|
1
1
|
# @sqlbraid/core
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
mapping, observers, transactions, and capability errors; it does not connect
|
|
6
|
-
to a database.
|
|
3
|
+
Public TypeScript contracts for SQLBraid templates, rendered statements,
|
|
4
|
+
execution boundaries, result mapping, and adapter capabilities.
|
|
7
5
|
|
|
8
6
|
```sh
|
|
9
7
|
npm install @sqlbraid/core
|
|
10
8
|
```
|
|
11
9
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
DriverRoutineResult,
|
|
16
|
-
QueryExecutor,
|
|
17
|
-
RenderedStatement,
|
|
18
|
-
RoutineCallResult,
|
|
19
|
-
} from "@sqlbraid/core";
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
An adapter implements `QueryExecutor.query`, `stream`, and `call` using a
|
|
23
|
-
`RenderedStatement`. The statement has SQL `segments` and value-only
|
|
24
|
-
`parameters`; its optional `nativeTemplate` preserves native tagged-template
|
|
25
|
-
transport when an adapter supports it. `bulk` and transaction methods are
|
|
26
|
-
optional executor capabilities. `Database` is the application-facing contract
|
|
27
|
-
implemented by the runtime package.
|
|
10
|
+
Use this low-level package when authoring an adapter or integration. It defines
|
|
11
|
+
contracts only and does not connect to a database or execute queries; use
|
|
12
|
+
`@sqlbraid/runtime` for application execution.
|
|
28
13
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
14
|
+
Driver authors can import `@sqlbraid/core/driver` for explicit cleanup scopes,
|
|
15
|
+
safe result-property definition, and savepoint-name validation. Cleanup scopes
|
|
16
|
+
run registered actions in LIFO order exactly once, preserve the primary failure,
|
|
17
|
+
aggregate cleanup failures under `BRAID_RESOURCE_CLEANUP`, and support disarm
|
|
18
|
+
after ownership transfer without forcing synchronous actions through Promises.
|
|
34
19
|
|
|
35
|
-
See the [SQLBraid documentation](https://clickin.github.io/SQLBraid/)
|
|
36
|
-
[routine guide](https://clickin.github.io/SQLBraid/concepts/routines/).
|
|
20
|
+
See the [SQLBraid documentation](https://clickin.github.io/SQLBraid/).
|
package/dist/driver.d.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
//#region src/driver.d.ts
|
|
2
|
+
export type CleanupAction = () => void | PromiseLike<void>;
|
|
3
|
+
export interface CleanupScope {
|
|
4
|
+
add(action: CleanupAction): void;
|
|
5
|
+
disarm(): void;
|
|
6
|
+
/**
|
|
7
|
+
* Runs cleanup once. Calls made again while asynchronous cleanup is pending
|
|
8
|
+
* return the same Promise; cleanup actions must not await this scope's run.
|
|
9
|
+
*/
|
|
10
|
+
run(primary?: unknown): void | Promise<void>;
|
|
11
|
+
}
|
|
12
|
+
export declare function createCleanupScope(): CleanupScope;
|
|
13
|
+
export declare function defineResultProperty(row: Record<string, unknown>, key: string, value: unknown): void;
|
|
14
|
+
export declare function assertSavepointName(name: string): string;
|
|
15
|
+
//#endregion
|
|
16
|
+
//# sourceMappingURL=driver.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"driver.d.ts","names":[],"sources":["../src/driver.ts"],"mappings":";YAAY,6BAA6B;iBAExB;EACf,IAAI,QAAQ;EACZ;;;;;EAKA,IAAI,2BAA2B;;wBA8DjB,sBAAsB;wBA8CtB,qBAAqB,KAAK,yBAAyB,aAAa;wBAShE,oBAAoB"}
|
package/dist/driver.js
ADDED
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
//#region src/driver.ts
|
|
2
|
+
const NO_PRIMARY = Symbol("sqlbraid.no-primary");
|
|
3
|
+
const RESOURCE_CLEANUP_CODE = "BRAID_RESOURCE_CLEANUP";
|
|
4
|
+
const SAVEPOINT_NAME = /^[A-Za-z_][A-Za-z0-9_]*$/u;
|
|
5
|
+
function resourceCleanupError(primary, failures) {
|
|
6
|
+
const hasPrimary = primary !== NO_PRIMARY;
|
|
7
|
+
const values = hasPrimary ? [primary, ...failures] : failures;
|
|
8
|
+
const error = values.length === 1 && !hasPrimary ? new Error("BRAID_RESOURCE_CLEANUP: resource cleanup failed.", { cause: failures[0] }) : new AggregateError(values, "BRAID_RESOURCE_CLEANUP: resource cleanup failed.", { cause: hasPrimary ? primary : failures[0] });
|
|
9
|
+
Object.defineProperty(error, "code", {
|
|
10
|
+
configurable: false,
|
|
11
|
+
enumerable: true,
|
|
12
|
+
value: RESOURCE_CLEANUP_CODE,
|
|
13
|
+
writable: false
|
|
14
|
+
});
|
|
15
|
+
return error;
|
|
16
|
+
}
|
|
17
|
+
function finish(primary, failures) {
|
|
18
|
+
if (failures.length === 0) {
|
|
19
|
+
if (primary !== NO_PRIMARY) throw primary;
|
|
20
|
+
return;
|
|
21
|
+
}
|
|
22
|
+
throw resourceCleanupError(primary, failures);
|
|
23
|
+
}
|
|
24
|
+
function isThenable(value) {
|
|
25
|
+
return typeof value === "object" && value !== null || typeof value === "function" ? typeof value.then === "function" : false;
|
|
26
|
+
}
|
|
27
|
+
async function finishAsync(current, pending, nextIndex, primary, failures) {
|
|
28
|
+
try {
|
|
29
|
+
await current;
|
|
30
|
+
} catch (error) {
|
|
31
|
+
failures.push(error);
|
|
32
|
+
}
|
|
33
|
+
for (let index = nextIndex; index < pending.length; index += 1) try {
|
|
34
|
+
await pending[index]();
|
|
35
|
+
} catch (error) {
|
|
36
|
+
failures.push(error);
|
|
37
|
+
}
|
|
38
|
+
finish(primary, failures);
|
|
39
|
+
}
|
|
40
|
+
function createCleanupScope() {
|
|
41
|
+
let actions = [];
|
|
42
|
+
let state = "open";
|
|
43
|
+
let inFlight;
|
|
44
|
+
return {
|
|
45
|
+
add(action) {
|
|
46
|
+
if (state !== "open") throw new Error("Cannot register cleanup after scope closure.");
|
|
47
|
+
if (typeof action !== "function") throw new TypeError("Cleanup action must be a function.");
|
|
48
|
+
actions.push(action);
|
|
49
|
+
},
|
|
50
|
+
disarm() {
|
|
51
|
+
if (state !== "open") return;
|
|
52
|
+
state = "disarmed";
|
|
53
|
+
actions = [];
|
|
54
|
+
},
|
|
55
|
+
run(primary) {
|
|
56
|
+
if (inFlight !== void 0) return inFlight;
|
|
57
|
+
if (state !== "open") return;
|
|
58
|
+
state = "running";
|
|
59
|
+
const pending = actions.reverse();
|
|
60
|
+
actions = [];
|
|
61
|
+
const failures = [];
|
|
62
|
+
const primaryValue = arguments.length === 0 ? NO_PRIMARY : primary;
|
|
63
|
+
for (let index = 0; index < pending.length; index += 1) try {
|
|
64
|
+
const result = pending[index]();
|
|
65
|
+
if (isThenable(result)) {
|
|
66
|
+
state = "closed";
|
|
67
|
+
inFlight = finishAsync(result, pending, index + 1, primaryValue, failures);
|
|
68
|
+
return inFlight;
|
|
69
|
+
}
|
|
70
|
+
} catch (error) {
|
|
71
|
+
failures.push(error);
|
|
72
|
+
}
|
|
73
|
+
state = "closed";
|
|
74
|
+
finish(primaryValue, failures);
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
function defineResultProperty(row, key, value) {
|
|
79
|
+
Object.defineProperty(row, key, {
|
|
80
|
+
configurable: true,
|
|
81
|
+
enumerable: true,
|
|
82
|
+
value,
|
|
83
|
+
writable: true
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
function assertSavepointName(name) {
|
|
87
|
+
if (typeof name !== "string" || !SAVEPOINT_NAME.test(name)) throw new TypeError("Invalid SQLBraid savepoint name.");
|
|
88
|
+
return name;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
//#endregion
|
|
92
|
+
export { assertSavepointName, createCleanupScope, defineResultProperty };
|
|
93
|
+
//# sourceMappingURL=driver.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"driver.js","names":[],"sources":["../src/driver.ts"],"sourcesContent":["export type CleanupAction = () => void | PromiseLike<void>;\n\nexport interface CleanupScope {\n add(action: CleanupAction): void;\n disarm(): void;\n /**\n * Runs cleanup once. Calls made again while asynchronous cleanup is pending\n * return the same Promise; cleanup actions must not await this scope's run.\n */\n run(primary?: unknown): void | Promise<void>;\n}\n\nconst NO_PRIMARY = Symbol(\"sqlbraid.no-primary\");\nconst RESOURCE_CLEANUP_CODE = \"BRAID_RESOURCE_CLEANUP\" as const;\nconst SAVEPOINT_NAME = /^[A-Za-z_][A-Za-z0-9_]*$/u;\n\nfunction resourceCleanupError(primary: unknown | typeof NO_PRIMARY, failures: readonly unknown[]): Error {\n const hasPrimary = primary !== NO_PRIMARY;\n const values = hasPrimary ? [primary, ...failures] : failures;\n const error =\n values.length === 1 && !hasPrimary\n ? new Error(\"BRAID_RESOURCE_CLEANUP: resource cleanup failed.\", { cause: failures[0] })\n : new AggregateError(values, \"BRAID_RESOURCE_CLEANUP: resource cleanup failed.\", {\n cause: hasPrimary ? primary : failures[0],\n });\n Object.defineProperty(error, \"code\", {\n configurable: false,\n enumerable: true,\n value: RESOURCE_CLEANUP_CODE,\n writable: false,\n });\n return error;\n}\n\nfunction finish(primary: unknown | typeof NO_PRIMARY, failures: readonly unknown[]): void {\n if (failures.length === 0) {\n if (primary !== NO_PRIMARY) throw primary;\n return;\n }\n throw resourceCleanupError(primary, failures);\n}\n\nfunction isThenable(value: unknown): value is PromiseLike<void> {\n return (typeof value === \"object\" && value !== null) || typeof value === \"function\"\n ? typeof (value as { readonly then?: unknown }).then === \"function\"\n : false;\n}\n\nasync function finishAsync(\n current: PromiseLike<void>,\n pending: readonly CleanupAction[],\n nextIndex: number,\n primary: unknown | typeof NO_PRIMARY,\n failures: unknown[],\n): Promise<void> {\n try {\n await current;\n } catch (error) {\n failures.push(error);\n }\n for (let index = nextIndex; index < pending.length; index += 1) {\n try {\n // oxlint-disable-next-line no-await-in-loop -- Cleanup must complete sequentially in LIFO order.\n await pending[index]!();\n } catch (error) {\n failures.push(error);\n }\n }\n finish(primary, failures);\n}\n\nexport function createCleanupScope(): CleanupScope {\n let actions: CleanupAction[] = [];\n let state: \"open\" | \"running\" | \"closed\" | \"disarmed\" = \"open\";\n let inFlight: Promise<void> | undefined;\n\n return {\n add(action: CleanupAction): void {\n if (state !== \"open\") throw new Error(\"Cannot register cleanup after scope closure.\");\n if (typeof action !== \"function\") throw new TypeError(\"Cleanup action must be a function.\");\n actions.push(action);\n },\n\n disarm(): void {\n if (state !== \"open\") return;\n state = \"disarmed\";\n actions = [];\n },\n\n run(primary?: unknown): void | Promise<void> {\n if (inFlight !== undefined) return inFlight;\n if (state !== \"open\") return;\n state = \"running\";\n // oxlint-disable-next-line unicorn/no-array-reverse -- Consume this owned action array in LIFO order without copying.\n const pending = actions.reverse();\n actions = [];\n const failures: unknown[] = [];\n const primaryValue = arguments.length === 0 ? NO_PRIMARY : primary;\n\n for (let index = 0; index < pending.length; index += 1) {\n try {\n const result = pending[index]!();\n if (isThenable(result)) {\n state = \"closed\";\n inFlight = finishAsync(result, pending, index + 1, primaryValue, failures);\n return inFlight;\n }\n } catch (error) {\n failures.push(error);\n }\n }\n state = \"closed\";\n finish(primaryValue, failures);\n },\n };\n}\n\nexport function defineResultProperty(row: Record<string, unknown>, key: string, value: unknown): void {\n Object.defineProperty(row, key, {\n configurable: true,\n enumerable: true,\n value,\n writable: true,\n });\n}\n\nexport function assertSavepointName(name: string): string {\n if (typeof name !== \"string\" || !SAVEPOINT_NAME.test(name)) {\n throw new TypeError(\"Invalid SQLBraid savepoint name.\");\n }\n return name;\n}\n"],"mappings":";AAYA,MAAM,aAAa,OAAO,qBAAqB;AAC/C,MAAM,wBAAwB;AAC9B,M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AI,UAAU,QAAQ;GACtB,QAAQ;GACR,UAAU,CAAC;EACb;EAEA,IAAI,SAAyC;GAC3C,IAAI,aAAa,QAAW,OAAO;GACnC,IAAI,UAAU,QAAQ;GACtB,QAAQ;GAER,MAAM,UAAU,QAAQ,QAAQ;GAChC,UAAU,CAAC;GACX,MAAM,WAAsB,CAAC;GAC7B,MAAM,eAAe,UAAU,WAAW,IAAI,aAAa;GAE3D,KAAK,IAAI,QAAQ,GAAG,QAAQ,QAAQ,QAAQ,SAAS,GACnD,IAAI;IACF,MAAM,SAAS,QAAQ,MAAM,CAAE;IAC/B,IAAI,WAAW,MAAM,GAAG;KACtB,QAAQ;KACR,WAAW,YAAY,QAAQ,SAAS,QAAQ,GAAG,cAAc,QAAQ;KACzE,OAAO;IACT;GACF,SAAS,OAAO;IACd,SAAS,KAAK,KAAK;GACrB;GAEF,QAAQ;GACR,OAAO,cAAc,QAAQ;EAC/B;CACF;AACF;AAEA,SAAgB,qBAAqB,KAA8B,KAAa,OAAsB;CACpG,OAAO,eAAe,KAAK,KAAK;EAC9B,cAAc;EACd,YAAY;EACZ;EACA,UAAU;CACZ,CAAC;AACH;AAEA,SAAgB,oBAAoB,MAAsB;CACxD,IAAI,OAAO,SAAS,YAAY,CAAC,eAAe,KAAK,IAAI,GACvD,MAAM,IAAI,UAAU,kCAAkC;CAExD,OAAO;AACT"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,198 @@
|
|
|
1
1
|
import { StandardSchemaV1, StandardSchemaV1 as StandardSchemaV1$1 } from "@standard-schema/spec";
|
|
2
|
+
//#region src/authoring-modules.d.ts
|
|
3
|
+
/** Data-only authoring identity shared by compiler, tooling, and editor consumers. */
|
|
4
|
+
type AuthoringModuleCatalogEntry = {
|
|
5
|
+
readonly moduleSpecifier: string;
|
|
6
|
+
readonly dialectId?: "postgres" | "mysql" | "mariadb" | "sqlite" | "oracle" | "mssql";
|
|
7
|
+
readonly helperFamily: "template" | "facade";
|
|
8
|
+
};
|
|
9
|
+
export declare const AUTHORING_MODULE_CATALOG: readonly AuthoringModuleCatalogEntry[];
|
|
10
|
+
//#endregion
|
|
11
|
+
//#region src/capabilities.d.ts
|
|
12
|
+
/**
|
|
13
|
+
* The machine-readable capability vocabulary shared by adapters, support data,
|
|
14
|
+
* and documentation. A capability's family describes what its status proves;
|
|
15
|
+
* representation and metadata evidence are not execution support aliases.
|
|
16
|
+
*/
|
|
17
|
+
type CapabilityFamily = "support" | "representation" | "metadata";
|
|
18
|
+
interface WellKnownCapability {
|
|
19
|
+
readonly id: string;
|
|
20
|
+
readonly family: CapabilityFamily;
|
|
21
|
+
}
|
|
22
|
+
declare const definitions: readonly [{
|
|
23
|
+
readonly id: "sql.native-transparency";
|
|
24
|
+
readonly family: "support";
|
|
25
|
+
}, {
|
|
26
|
+
readonly id: "sql.generated-structure";
|
|
27
|
+
readonly family: "support";
|
|
28
|
+
}, {
|
|
29
|
+
readonly id: "result.rows";
|
|
30
|
+
readonly family: "support";
|
|
31
|
+
}, {
|
|
32
|
+
readonly id: "result.command";
|
|
33
|
+
readonly family: "support";
|
|
34
|
+
}, {
|
|
35
|
+
readonly id: "result.multiple-sets";
|
|
36
|
+
readonly family: "support";
|
|
37
|
+
}, {
|
|
38
|
+
readonly id: "result.standard-schema";
|
|
39
|
+
readonly family: "support";
|
|
40
|
+
}, {
|
|
41
|
+
readonly id: "numeric.exact-integer";
|
|
42
|
+
readonly family: "representation";
|
|
43
|
+
}, {
|
|
44
|
+
readonly id: "numeric.exact-decimal";
|
|
45
|
+
readonly family: "representation";
|
|
46
|
+
}, {
|
|
47
|
+
readonly id: "numeric.approximate-float";
|
|
48
|
+
readonly family: "representation";
|
|
49
|
+
}, {
|
|
50
|
+
readonly id: "numeric.approximate-special";
|
|
51
|
+
readonly family: "representation";
|
|
52
|
+
}, {
|
|
53
|
+
readonly id: "numeric.bind-exact";
|
|
54
|
+
readonly family: "representation";
|
|
55
|
+
}, {
|
|
56
|
+
readonly id: "numeric.aggregate";
|
|
57
|
+
readonly family: "representation";
|
|
58
|
+
}, {
|
|
59
|
+
readonly id: "numeric.command-metadata";
|
|
60
|
+
readonly family: "representation";
|
|
61
|
+
}, {
|
|
62
|
+
readonly id: "numeric.special-values";
|
|
63
|
+
readonly family: "representation";
|
|
64
|
+
}, {
|
|
65
|
+
readonly id: "numeric.scale-greater-than-precision";
|
|
66
|
+
readonly family: "representation";
|
|
67
|
+
}, {
|
|
68
|
+
readonly id: "numeric.negative-scale";
|
|
69
|
+
readonly family: "representation";
|
|
70
|
+
}, {
|
|
71
|
+
readonly id: "data.json-parsed";
|
|
72
|
+
readonly family: "representation";
|
|
73
|
+
}, {
|
|
74
|
+
readonly id: "data.json-lossless-text";
|
|
75
|
+
readonly family: "representation";
|
|
76
|
+
}, {
|
|
77
|
+
readonly id: "data.sql-variant";
|
|
78
|
+
readonly family: "representation";
|
|
79
|
+
}, {
|
|
80
|
+
readonly id: "data.oracle-object";
|
|
81
|
+
readonly family: "representation";
|
|
82
|
+
}, {
|
|
83
|
+
readonly id: "data.oracle-collection";
|
|
84
|
+
readonly family: "representation";
|
|
85
|
+
}, {
|
|
86
|
+
readonly id: "data.vector";
|
|
87
|
+
readonly family: "representation";
|
|
88
|
+
}, {
|
|
89
|
+
readonly id: "data.binary";
|
|
90
|
+
readonly family: "representation";
|
|
91
|
+
}, {
|
|
92
|
+
readonly id: "data.uuid";
|
|
93
|
+
readonly family: "representation";
|
|
94
|
+
}, {
|
|
95
|
+
readonly id: "data.temporal-native";
|
|
96
|
+
readonly family: "representation";
|
|
97
|
+
}, {
|
|
98
|
+
readonly id: "data.temporal-lossless";
|
|
99
|
+
readonly family: "representation";
|
|
100
|
+
}, {
|
|
101
|
+
readonly id: "data.timezone";
|
|
102
|
+
readonly family: "representation";
|
|
103
|
+
}, {
|
|
104
|
+
readonly id: "metadata.command-safe";
|
|
105
|
+
readonly family: "metadata";
|
|
106
|
+
}, {
|
|
107
|
+
readonly id: "dml.insert-returning";
|
|
108
|
+
readonly family: "support";
|
|
109
|
+
}, {
|
|
110
|
+
readonly id: "dml.update-returning";
|
|
111
|
+
readonly family: "support";
|
|
112
|
+
}, {
|
|
113
|
+
readonly id: "dml.delete-returning";
|
|
114
|
+
readonly family: "support";
|
|
115
|
+
}, {
|
|
116
|
+
readonly id: "dml.merge-returning";
|
|
117
|
+
readonly family: "support";
|
|
118
|
+
}, {
|
|
119
|
+
readonly id: "dml.upsert-returning";
|
|
120
|
+
readonly family: "support";
|
|
121
|
+
}, {
|
|
122
|
+
readonly id: "session.pinned";
|
|
123
|
+
readonly family: "support";
|
|
124
|
+
}, {
|
|
125
|
+
readonly id: "statement.prepare";
|
|
126
|
+
readonly family: "support";
|
|
127
|
+
}, {
|
|
128
|
+
readonly id: "statement.cancel";
|
|
129
|
+
readonly family: "support";
|
|
130
|
+
}, {
|
|
131
|
+
readonly id: "statement.stream";
|
|
132
|
+
readonly family: "support";
|
|
133
|
+
}, {
|
|
134
|
+
readonly id: "statement.bulk";
|
|
135
|
+
readonly family: "support";
|
|
136
|
+
}, {
|
|
137
|
+
readonly id: "execution.bulk-fidelity";
|
|
138
|
+
readonly family: "support";
|
|
139
|
+
}, {
|
|
140
|
+
readonly id: "transaction";
|
|
141
|
+
readonly family: "support";
|
|
142
|
+
}, {
|
|
143
|
+
readonly id: "transaction.savepoint";
|
|
144
|
+
readonly family: "support";
|
|
145
|
+
}, {
|
|
146
|
+
readonly id: "transaction.read-only";
|
|
147
|
+
readonly family: "support";
|
|
148
|
+
}, {
|
|
149
|
+
readonly id: "transaction.isolation.read-uncommitted";
|
|
150
|
+
readonly family: "support";
|
|
151
|
+
}, {
|
|
152
|
+
readonly id: "transaction.isolation.read-committed";
|
|
153
|
+
readonly family: "support";
|
|
154
|
+
}, {
|
|
155
|
+
readonly id: "transaction.isolation.repeatable-read";
|
|
156
|
+
readonly family: "support";
|
|
157
|
+
}, {
|
|
158
|
+
readonly id: "transaction.isolation.serializable";
|
|
159
|
+
readonly family: "support";
|
|
160
|
+
}, {
|
|
161
|
+
readonly id: "routine.call";
|
|
162
|
+
readonly family: "support";
|
|
163
|
+
}, {
|
|
164
|
+
readonly id: "routine.out";
|
|
165
|
+
readonly family: "support";
|
|
166
|
+
}, {
|
|
167
|
+
readonly id: "routine.inout";
|
|
168
|
+
readonly family: "support";
|
|
169
|
+
}, {
|
|
170
|
+
readonly id: "routine.result-sets";
|
|
171
|
+
readonly family: "support";
|
|
172
|
+
}, {
|
|
173
|
+
readonly id: "routine.out-cursor";
|
|
174
|
+
readonly family: "support";
|
|
175
|
+
}, {
|
|
176
|
+
readonly id: "routine.return-value";
|
|
177
|
+
readonly family: "support";
|
|
178
|
+
}, {
|
|
179
|
+
readonly id: "metadata.identity";
|
|
180
|
+
readonly family: "metadata";
|
|
181
|
+
}, {
|
|
182
|
+
readonly id: "metadata.generated";
|
|
183
|
+
readonly family: "metadata";
|
|
184
|
+
}, {
|
|
185
|
+
readonly id: "metadata.routines";
|
|
186
|
+
readonly family: "metadata";
|
|
187
|
+
}, {
|
|
188
|
+
readonly id: "metadata.types";
|
|
189
|
+
readonly family: "metadata";
|
|
190
|
+
}];
|
|
191
|
+
export declare const WELL_KNOWN_CAPABILITIES: readonly WellKnownCapability[];
|
|
192
|
+
type WellKnownCapabilityId = (typeof definitions)[number]["id"];
|
|
193
|
+
export declare const WELL_KNOWN_CAPABILITY_IDS: readonly WellKnownCapabilityId[];
|
|
194
|
+
export declare function isWellKnownCapabilityId(value: string): value is WellKnownCapabilityId;
|
|
195
|
+
//#endregion
|
|
2
196
|
//#region src/index.d.ts
|
|
3
197
|
export declare const SQL_FRAGMENT: unique symbol;
|
|
4
198
|
declare const boundParameterBrand: unique symbol;
|
|
@@ -27,9 +221,29 @@ export interface ExactIntegerRange {
|
|
|
27
221
|
readonly max?: bigint;
|
|
28
222
|
}
|
|
29
223
|
export declare class ResultExactnessError extends Error {
|
|
30
|
-
readonly code
|
|
224
|
+
static readonly code: "BRAID_RESULT_EXACTNESS";
|
|
225
|
+
readonly code: "BRAID_RESULT_EXACTNESS";
|
|
31
226
|
constructor(message?: string);
|
|
32
227
|
}
|
|
228
|
+
export type PublicErrorCategory = "runtime" | "adapter" | "compiler";
|
|
229
|
+
export interface PublicErrorDefinition {
|
|
230
|
+
readonly code: string;
|
|
231
|
+
readonly category: PublicErrorCategory;
|
|
232
|
+
readonly owner: string;
|
|
233
|
+
/**
|
|
234
|
+
* UnsupportedFeatureError only: features for which this code is a public
|
|
235
|
+
* contract. Other public errors intentionally omit this metadata.
|
|
236
|
+
*/
|
|
237
|
+
readonly features?: readonly string[];
|
|
238
|
+
}
|
|
239
|
+
/**
|
|
240
|
+
* The intentionally small compatibility boundary for SQLBraid-owned errors.
|
|
241
|
+
*
|
|
242
|
+
* Keep this registry explicit. In particular, a BRAID_ token in a driver
|
|
243
|
+
* message or an internal compiler fallback is not public merely because it
|
|
244
|
+
* happens to use the project prefix.
|
|
245
|
+
*/
|
|
246
|
+
export declare const PUBLIC_ERROR_DEFINITIONS: readonly PublicErrorDefinition[];
|
|
33
247
|
export declare function decodeExactInteger(value: unknown, range?: ExactIntegerRange): bigint;
|
|
34
248
|
/**
|
|
35
249
|
* Normalize an exact integer at the raw SQLBraid boundary without changing
|
|
@@ -214,6 +428,10 @@ export declare function createStatementBindingDescription(statement: RenderedSta
|
|
|
214
428
|
export declare function createBulkBindingDescription(bulk: RenderedBulk, context: StatementBindingContext, options: StatementBindingDescriptionOptions): BulkBindingDescription;
|
|
215
429
|
export interface DialectLexicalProfile {
|
|
216
430
|
readonly lineCommentPrefixes: readonly string[];
|
|
431
|
+
/** Require whitespace/control after -- (MySQL/MariaDB). Defaults to false. */
|
|
432
|
+
readonly doubleDashRequiresWhitespace?: boolean;
|
|
433
|
+
/** Characters that terminate a line comment. Defaults to CR and LF. */
|
|
434
|
+
readonly lineCommentTerminators?: string;
|
|
217
435
|
readonly supportsNestedBlockComments?: boolean;
|
|
218
436
|
readonly supportsDollarQuotes?: boolean;
|
|
219
437
|
readonly supportsBacktickIdentifiers?: boolean;
|
|
@@ -352,6 +570,7 @@ export type QueryExecutionResult<Row = unknown> = RowsExecutionResult<Row> | Com
|
|
|
352
570
|
export interface ExecutionOptions {
|
|
353
571
|
readonly signal?: AbortSignal;
|
|
354
572
|
}
|
|
573
|
+
export type Awaitable<T> = T | PromiseLike<T>;
|
|
355
574
|
export interface RowValidationOptions<Row> extends ExecutionOptions {
|
|
356
575
|
readonly schema?: StandardSchemaV1$1<unknown, NoInfer<Row>>;
|
|
357
576
|
}
|
|
@@ -366,6 +585,13 @@ export declare class UnsupportedFeatureError extends Error {
|
|
|
366
585
|
readonly code: `BRAID_${string}`;
|
|
367
586
|
constructor(feature: string, code: `BRAID_${string}`, message: string, options?: ErrorOptions);
|
|
368
587
|
}
|
|
588
|
+
/** Return true only for a registered, semantically valid feature/code pair. */
|
|
589
|
+
export declare function isPublicUnsupportedFeatureError(error: unknown): error is UnsupportedFeatureError;
|
|
590
|
+
/** An adapter-owned input/transport failure that retains TypeError semantics. */
|
|
591
|
+
export declare class AdapterError extends TypeError {
|
|
592
|
+
readonly code: `BRAID_${string}`;
|
|
593
|
+
constructor(code: `BRAID_${string}`, message: string, options?: ErrorOptions);
|
|
594
|
+
}
|
|
369
595
|
export interface RoutineResultSet<Row = unknown> {
|
|
370
596
|
readonly rows: readonly Row[];
|
|
371
597
|
}
|
|
@@ -413,7 +639,8 @@ export type RoutineMappingLocation = {
|
|
|
413
639
|
};
|
|
414
640
|
export type DriverCapabilityErrorCode = "BRAID_STREAM_UNSUPPORTED" | "BRAID_CALL_UNSUPPORTED" | "BRAID_CALL_RESULT_SETS" | "BRAID_CALL_CURSOR_TX_REQUIRED" | "BRAID_CALL_OUT_UNSUPPORTED" | "BRAID_CALL_RETURN_UNSUPPORTED" | "BRAID_CALL_CURSOR_UNSUPPORTED" | "BRAID_RESOURCE_CLEANUP";
|
|
415
641
|
export declare class RoutineMappingError extends Error {
|
|
416
|
-
readonly code
|
|
642
|
+
static readonly code: "BRAID_CALL_MAP";
|
|
643
|
+
readonly code: "BRAID_CALL_MAP";
|
|
417
644
|
readonly location: RoutineMappingLocation;
|
|
418
645
|
constructor(message: string, location: RoutineMappingLocation, options?: {
|
|
419
646
|
readonly cause?: unknown;
|
|
@@ -430,16 +657,17 @@ export interface QueryExecutor {
|
|
|
430
657
|
readonly ownershipKey?: object;
|
|
431
658
|
readonly statementBinding: StatementBindingAdapter;
|
|
432
659
|
readonly environment?: DriverEnvironment;
|
|
433
|
-
query<Row>(rendered: RenderedStatement, binding?: StatementBindingDescription, options?: ExecutionOptions):
|
|
660
|
+
query<Row>(rendered: RenderedStatement, binding?: StatementBindingDescription, options?: ExecutionOptions): Awaitable<QueryExecutionResult<Row>>;
|
|
434
661
|
stream<Row>(rendered: RenderedStatement, binding?: StatementBindingDescription, options?: ExecutionOptions): AsyncIterable<Row>;
|
|
435
|
-
call(rendered: RenderedStatement, binding?: StatementBindingDescription, options?: ExecutionOptions):
|
|
436
|
-
bulk?(bulk: RenderedBulk, binding: BulkBindingDescription, options?: ExecutionOptions):
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
662
|
+
call(rendered: RenderedStatement, binding?: StatementBindingDescription, options?: ExecutionOptions): Awaitable<DriverRoutineResult>;
|
|
663
|
+
bulk?(bulk: RenderedBulk, binding: BulkBindingDescription, options?: ExecutionOptions): Awaitable<BulkExecutionResult>;
|
|
664
|
+
validateTransactionOptions?(options: TransactionOptions): void;
|
|
665
|
+
begin?(options?: TransactionOptions): Awaitable<void>;
|
|
666
|
+
commit?(): Awaitable<void>;
|
|
667
|
+
rollback?(): Awaitable<void>;
|
|
668
|
+
savepoint?(name: string): Awaitable<void>;
|
|
669
|
+
rollbackTo?(name: string): Awaitable<void>;
|
|
670
|
+
releaseSavepoint?(name: string): Awaitable<void>;
|
|
443
671
|
}
|
|
444
672
|
export interface ConnectionLease extends QueryExecutor {
|
|
445
673
|
release(options?: {
|
|
@@ -449,6 +677,7 @@ export interface ConnectionLease extends QueryExecutor {
|
|
|
449
677
|
export interface ConnectionProvider {
|
|
450
678
|
readonly statementBinding: StatementBindingAdapter;
|
|
451
679
|
readonly environment?: DriverEnvironment;
|
|
680
|
+
validateTransactionOptions?(options: TransactionOptions): void;
|
|
452
681
|
acquire(): Promise<ConnectionLease>;
|
|
453
682
|
}
|
|
454
683
|
export interface QueryExecutionPlan {
|
|
@@ -675,6 +904,11 @@ export interface DatabaseOptions {
|
|
|
675
904
|
readonly reuse?: RequestedReuse;
|
|
676
905
|
}
|
|
677
906
|
export type PreparableQuery = ExecutableQuery | CallQuery;
|
|
907
|
+
export type PreparedFactoryOptions = {
|
|
908
|
+
readonly input: "none";
|
|
909
|
+
} | {
|
|
910
|
+
readonly input: "required";
|
|
911
|
+
};
|
|
678
912
|
export type PreparedArguments<Input, Options> = [Input] extends [never] ? [options?: Options] : [input: Input, options?: Options];
|
|
679
913
|
export type PreparedQuery<Input, Q extends PreparableQuery> = {
|
|
680
914
|
readonly name: string;
|
|
@@ -699,8 +933,13 @@ export interface Database {
|
|
|
699
933
|
call<Result extends RoutineCallResult>(query: CallQuery<Result>, options?: ExecutionOptions): Promise<Result>;
|
|
700
934
|
batch<const Queries extends readonly ExecutableQuery[]>(queries: Queries, options?: ExecutionOptions): Promise<{ readonly [K in keyof Queries]: ExecutionResultOf<Queries[K]>; }>;
|
|
701
935
|
bulk<Input>(inputs: readonly Input[], factory: (input: Input, index: number) => CommandQuery, options?: ExecutionOptions): Promise<BulkResult>;
|
|
702
|
-
prepare<Factory extends () => PreparableQuery>(name: string, factory: Factory & (Parameters<Factory> extends [] ? unknown : never)
|
|
936
|
+
prepare<Factory extends () => PreparableQuery>(name: string, factory: Factory & (Parameters<Factory> extends [] ? unknown : never), options: {
|
|
937
|
+
readonly input: "none";
|
|
938
|
+
}): PreparedQuery<never, ReturnType<Factory>>;
|
|
703
939
|
prepare<Factory extends (input: never) => PreparableQuery>(name: string, factory: Factory & (Parameters<Factory> extends [unknown] ? unknown : never)): PreparedQuery<Parameters<Factory>[0], ReturnType<Factory>>;
|
|
940
|
+
prepare<Factory extends (input: never) => PreparableQuery>(name: string, factory: Factory & (number extends Parameters<Factory>["length"] ? unknown : Parameters<Factory>["length"] extends 0 | 1 ? unknown : never), options: {
|
|
941
|
+
readonly input: "required";
|
|
942
|
+
}): PreparedQuery<Parameters<Factory>[0], ReturnType<Factory>>;
|
|
704
943
|
stream<Row>(query: RowQuery<Row>, options?: StreamOptions<Row>): AsyncIterable<Row>;
|
|
705
944
|
session<T>(callback: (database: Database) => Promise<T>): Promise<T>;
|
|
706
945
|
tx<T>(callback: (database: Database) => Promise<T>): Promise<T>;
|
|
@@ -743,5 +982,5 @@ export declare class SqlRenderError extends Error {
|
|
|
743
982
|
constructor(code: string, message: string);
|
|
744
983
|
}
|
|
745
984
|
//#endregion
|
|
746
|
-
export type { StandardSchemaV1 };
|
|
985
|
+
export type { AuthoringModuleCatalogEntry, CapabilityFamily, StandardSchemaV1, WellKnownCapability, WellKnownCapabilityId };
|
|
747
986
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/index.ts"],"mappings":";;
|
|
1
|
+
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/authoring-modules.ts","../src/capabilities.ts","../src/index.ts"],"mappings":";;;KACY;WACD;WACA;WACA;;qBAGE,mCAAmC;;;;;;;;KCFpC;UAEK;WACN;WACA,QAAQ;;cAGb;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBA2DO,kCAAkC;KAInC,gCAAgC;qBAE/B,oCAAoC;wBAMjC,wBAAw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AC3B,WAAW;WACX,iBAAiB,UAAU,sBAAsB;WACjD,cAAc;WACd;WACA;WACA;WACA;WACA;;iBAGM;WACN;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,UAAU,SAAS;WACnB;WACA;;iBAGM;WACN;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;iBAGM;WACN;WACA;WACA;WACA;WACA;WACA;WACA,WAAW;WACX,iBAAiB,eAAe,UAAU,sBAAsB;;iBAG1D;WACN;WACA;WACA;WACA;WACA,eAAe;WACf;WACA;WACA;;YAGC;iBAgBK;WACN;WACA;WACA;WACA;WACA;WACA;WACA,OAAO;WACP;WACA;WACA;WACA;WACA;;iBAGM;WACN;WACA;WACA;WACA;WACA;aACE;aACA;aACA,YAAY;aACZ;;WAEF,2BAA2B;WAC3B,WAAW;WACX,iBAAiB,UAAU,sBAAsB;WACjD;WACA;WACA;WACA;WACA;;iBAGM;WACN;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;YAGC;iBAQK;WACN;WACA;WACA,OAAO;WACP;WACA;WACA;WACA;WACA;;YAGC,iBACR,kBACA,mBACA,mBACA,iBACA,kBACA,kBACA,mBACA,iBACA;iBAEa;EACf,QAAQ,OAAO,wBAAwB;;iBAGxB;WACN;WACA;WACA;WACA;;iBAGM;WACN;aAAqB;aAA0B;aAA2B;;WAC1E;aAAmB;aAAqB;aAA2B;;WACnE;aAAoB;aAAqB;;WACzC;aAAwB;aAAqB;;WAC7C,cAAc,SAAS,eAAe;WACtC;aACE;aACA;aACA;;;;iBAKI;WACN,UAAU;WACV,QAAQ;WACR;aAAwB;aAAqB;;WAC7C,cAAc;WACd;aACE,WAAW;aACX,OAAO;eACL;eACA;eACA,eAAe,SAAS,eAAe;;;;;iBAMrC;WACN;WACA;WACA;aAAqB;aAA0B;aAA0B;;WACzE;aAAmB;aAAqB;aAA0B;;WAClE;aAAoB;aAAqB;;WACzC;aAAuB;aAAqB;;WAC5C;aAAqB;;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