@prisma-next/adapter-postgres 0.1.0-pr.32.7 → 0.1.0-pr.32.9
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.
|
@@ -1,11 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
* Column type descriptor containing both codec ID and native type.
|
|
3
|
-
* Used when defining columns with descriptor objects instead of string IDs.
|
|
4
|
-
*/
|
|
5
|
-
type ColumnTypeDescriptor = {
|
|
6
|
-
readonly codecId: string;
|
|
7
|
-
readonly nativeType: string;
|
|
8
|
-
};
|
|
1
|
+
import { ColumnTypeDescriptor } from '@prisma-next/contract-authoring';
|
|
9
2
|
|
|
10
3
|
/**
|
|
11
4
|
* Column type descriptors for Postgres adapter.
|
|
@@ -1,93 +1,6 @@
|
|
|
1
|
+
import { ControlAdapterDescriptor } from '@prisma-next/core-control-plane/types';
|
|
1
2
|
import { SqlControlAdapter } from '@prisma-next/family-sql/control-adapter';
|
|
2
3
|
|
|
3
|
-
/**
|
|
4
|
-
* Specifies how to import TypeScript types from a package.
|
|
5
|
-
* Used in extension pack manifests to declare codec and operation type imports.
|
|
6
|
-
*/
|
|
7
|
-
interface TypesImportSpec {
|
|
8
|
-
readonly package: string;
|
|
9
|
-
readonly named: string;
|
|
10
|
-
readonly alias: string;
|
|
11
|
-
}
|
|
12
|
-
type ArgSpecManifest = {
|
|
13
|
-
readonly kind: 'typeId';
|
|
14
|
-
readonly type: string;
|
|
15
|
-
} | {
|
|
16
|
-
readonly kind: 'param';
|
|
17
|
-
} | {
|
|
18
|
-
readonly kind: 'literal';
|
|
19
|
-
};
|
|
20
|
-
type ReturnSpecManifest = {
|
|
21
|
-
readonly kind: 'typeId';
|
|
22
|
-
readonly type: string;
|
|
23
|
-
} | {
|
|
24
|
-
readonly kind: 'builtin';
|
|
25
|
-
readonly type: 'number' | 'boolean' | 'string';
|
|
26
|
-
};
|
|
27
|
-
interface LoweringSpecManifest {
|
|
28
|
-
readonly targetFamily: 'sql';
|
|
29
|
-
readonly strategy: 'infix' | 'function';
|
|
30
|
-
readonly template: string;
|
|
31
|
-
}
|
|
32
|
-
interface OperationManifest {
|
|
33
|
-
readonly for: string;
|
|
34
|
-
readonly method: string;
|
|
35
|
-
readonly args: ReadonlyArray<ArgSpecManifest>;
|
|
36
|
-
readonly returns: ReturnSpecManifest;
|
|
37
|
-
readonly lowering: LoweringSpecManifest;
|
|
38
|
-
readonly capabilities?: ReadonlyArray<string>;
|
|
39
|
-
}
|
|
40
|
-
interface ExtensionPackManifest {
|
|
41
|
-
readonly id: string;
|
|
42
|
-
readonly version: string;
|
|
43
|
-
readonly targets?: Record<string, {
|
|
44
|
-
readonly minVersion?: string;
|
|
45
|
-
}>;
|
|
46
|
-
readonly capabilities?: Record<string, unknown>;
|
|
47
|
-
readonly types?: {
|
|
48
|
-
readonly codecTypes?: {
|
|
49
|
-
readonly import: TypesImportSpec;
|
|
50
|
-
};
|
|
51
|
-
readonly operationTypes?: {
|
|
52
|
-
readonly import: TypesImportSpec;
|
|
53
|
-
};
|
|
54
|
-
readonly storage?: readonly {
|
|
55
|
-
readonly typeId: string;
|
|
56
|
-
readonly familyId: string;
|
|
57
|
-
readonly targetId: string;
|
|
58
|
-
readonly nativeType?: string;
|
|
59
|
-
}[];
|
|
60
|
-
};
|
|
61
|
-
readonly operations?: ReadonlyArray<OperationManifest>;
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
/**
|
|
65
|
-
* Base interface for control-plane adapter instances.
|
|
66
|
-
* Families extend this with family-specific adapter interfaces.
|
|
67
|
-
*
|
|
68
|
-
* @template TFamilyId - The family ID (e.g., 'sql', 'document')
|
|
69
|
-
* @template TTargetId - The target ID (e.g., 'postgres', 'mysql')
|
|
70
|
-
*/
|
|
71
|
-
interface ControlAdapterInstance<TFamilyId extends string = string, TTargetId extends string = string> {
|
|
72
|
-
readonly familyId: TFamilyId;
|
|
73
|
-
readonly targetId: TTargetId;
|
|
74
|
-
}
|
|
75
|
-
/**
|
|
76
|
-
* Descriptor for a control-plane adapter pack (e.g., Postgres adapter).
|
|
77
|
-
*
|
|
78
|
-
* @template TFamilyId - The family ID (e.g., 'sql', 'document')
|
|
79
|
-
* @template TTargetId - The target ID (e.g., 'postgres', 'mysql')
|
|
80
|
-
* @template TAdapterInstance - The adapter instance type
|
|
81
|
-
*/
|
|
82
|
-
interface ControlAdapterDescriptor<TFamilyId extends string, TTargetId extends string, TAdapterInstance extends ControlAdapterInstance<TFamilyId, TTargetId> = ControlAdapterInstance<TFamilyId, TTargetId>> {
|
|
83
|
-
readonly kind: 'adapter';
|
|
84
|
-
readonly id: string;
|
|
85
|
-
readonly familyId: TFamilyId;
|
|
86
|
-
readonly targetId: TTargetId;
|
|
87
|
-
readonly manifest: ExtensionPackManifest;
|
|
88
|
-
create(): TAdapterInstance;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
4
|
/**
|
|
92
5
|
* Postgres adapter descriptor for CLI config.
|
|
93
6
|
*/
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prisma-next/adapter-postgres",
|
|
3
|
-
"version": "0.1.0-pr.32.
|
|
3
|
+
"version": "0.1.0-pr.32.9",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"files": [
|
|
@@ -8,14 +8,17 @@
|
|
|
8
8
|
],
|
|
9
9
|
"dependencies": {
|
|
10
10
|
"arktype": "^2.0.0",
|
|
11
|
-
"@prisma-next/cli": "0.1.0-pr.32.
|
|
12
|
-
"@prisma-next/
|
|
13
|
-
"@prisma-next/
|
|
14
|
-
"@prisma-next/
|
|
15
|
-
"@prisma-next/
|
|
16
|
-
"@prisma-next/sql
|
|
17
|
-
"@prisma-next/sql-
|
|
18
|
-
"@prisma-next/sql-
|
|
11
|
+
"@prisma-next/cli": "0.1.0-pr.32.9",
|
|
12
|
+
"@prisma-next/contract": "0.1.0-pr.32.9",
|
|
13
|
+
"@prisma-next/contract-authoring": "0.1.0-pr.32.9",
|
|
14
|
+
"@prisma-next/core-control-plane": "0.1.0-pr.32.9",
|
|
15
|
+
"@prisma-next/core-execution-plane": "0.1.0-pr.32.9",
|
|
16
|
+
"@prisma-next/family-sql": "0.1.0-pr.32.9",
|
|
17
|
+
"@prisma-next/sql-contract-ts": "0.1.0-pr.32.9",
|
|
18
|
+
"@prisma-next/sql-contract": "0.1.0-pr.32.9",
|
|
19
|
+
"@prisma-next/sql-operations": "0.1.0-pr.32.9",
|
|
20
|
+
"@prisma-next/sql-relational-core": "0.1.0-pr.32.9",
|
|
21
|
+
"@prisma-next/sql-schema-ir": "0.1.0-pr.32.9"
|
|
19
22
|
},
|
|
20
23
|
"devDependencies": {
|
|
21
24
|
"tsup": "^8.3.0",
|