@prisma-next/core-control-plane 0.3.0-pr.80.1 → 0.3.0-pr.81.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/README.md +0 -27
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -9,7 +9,6 @@ This package provides the core domain logic for control plane operations (contra
|
|
|
9
9
|
## Responsibilities
|
|
10
10
|
|
|
11
11
|
- **Config Types**: Type definitions for Prisma Next configuration (`PrismaNextConfig`, `ControlFamilyDescriptor`, `ControlTargetDescriptor`, `ControlAdapterDescriptor`, `ControlDriverDescriptor`, `ControlExtensionDescriptor`)
|
|
12
|
-
- **ControlPlaneStack**: A struct bundling `target`, `adapter`, `driver`, and `extensionPacks` for passing to `family.create()`. Use `createControlPlaneStack()` to construct with sensible defaults.
|
|
13
12
|
- **Config Validation**: Pure validation logic for config structure (no file I/O)
|
|
14
13
|
- **Config Normalization**: `defineConfig()` function for normalizing config with defaults
|
|
15
14
|
- **Domain Actions**:
|
|
@@ -70,32 +69,6 @@ const config = defineConfig({
|
|
|
70
69
|
validateConfig(config);
|
|
71
70
|
```
|
|
72
71
|
|
|
73
|
-
### ControlPlaneStack
|
|
74
|
-
|
|
75
|
-
The `ControlPlaneStack` bundles component descriptors for passing to `family.create()`:
|
|
76
|
-
|
|
77
|
-
```typescript
|
|
78
|
-
import { createControlPlaneStack } from '@prisma-next/core-control-plane/stack';
|
|
79
|
-
import type { ControlPlaneStack } from '@prisma-next/core-control-plane/types';
|
|
80
|
-
|
|
81
|
-
// Create a stack with sensible defaults
|
|
82
|
-
const stack = createControlPlaneStack({
|
|
83
|
-
target: postgresTarget,
|
|
84
|
-
adapter: postgresAdapter,
|
|
85
|
-
driver: postgresDriver, // optional, defaults to undefined
|
|
86
|
-
extensionPacks: [pgvector], // optional, defaults to []
|
|
87
|
-
});
|
|
88
|
-
|
|
89
|
-
// Pass the stack to family.create()
|
|
90
|
-
const familyInstance = config.family.create(stack);
|
|
91
|
-
```
|
|
92
|
-
|
|
93
|
-
**Stack shape after construction:**
|
|
94
|
-
- `target`: Required target descriptor
|
|
95
|
-
- `adapter`: Required adapter descriptor
|
|
96
|
-
- `driver`: `ControlDriverDescriptor | undefined` (always present, may be `undefined`)
|
|
97
|
-
- `extensionPacks`: `readonly ControlExtensionDescriptor[]` (always an array, possibly empty)
|
|
98
|
-
|
|
99
72
|
### Verify Database
|
|
100
73
|
|
|
101
74
|
```typescript
|
package/package.json
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prisma-next/core-control-plane",
|
|
3
|
-
"version": "0.3.0-pr.
|
|
3
|
+
"version": "0.3.0-pr.81.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"description": "Control plane domain actions, config types, validation, and error factories for Prisma Next",
|
|
7
7
|
"dependencies": {
|
|
8
8
|
"arktype": "^2.1.26",
|
|
9
9
|
"prettier": "^3.3.3",
|
|
10
|
-
"@prisma-next/contract": "0.3.0-pr.
|
|
11
|
-
"@prisma-next/operations": "0.3.0-pr.
|
|
12
|
-
"@prisma-next/utils": "0.3.0-pr.
|
|
10
|
+
"@prisma-next/contract": "0.3.0-pr.81.1",
|
|
11
|
+
"@prisma-next/operations": "0.3.0-pr.81.1",
|
|
12
|
+
"@prisma-next/utils": "0.3.0-pr.81.1"
|
|
13
13
|
},
|
|
14
14
|
"devDependencies": {
|
|
15
15
|
"@vitest/coverage-v8": "4.0.16",
|