create-bcp-app 0.2.19 → 0.3.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 +110 -129
- package/package.json +1 -1
- package/template/README.md +118 -98
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@ npm run dev
|
|
|
10
10
|
|
|
11
11
|
## Project-local BCP CLI
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
Generated npm scripts use the local framework CLI:
|
|
14
14
|
|
|
15
15
|
```json
|
|
16
16
|
{
|
|
@@ -64,17 +64,17 @@ Select storage provider:
|
|
|
64
64
|
|
|
65
65
|
New projects include `bcp.project.json`.
|
|
66
66
|
|
|
67
|
-
Example for the `0.
|
|
67
|
+
Example for the `0.3.1` target:
|
|
68
68
|
|
|
69
69
|
```json
|
|
70
70
|
{
|
|
71
71
|
"schemaVersion": 1,
|
|
72
72
|
"framework": "bcp",
|
|
73
73
|
"projectName": "my-app",
|
|
74
|
-
"frameworkPackage": "npm:@chidchanun/bcp@0.
|
|
74
|
+
"frameworkPackage": "npm:@chidchanun/bcp@0.3.1",
|
|
75
75
|
"createdWith": {
|
|
76
76
|
"package": "create-bcp-app",
|
|
77
|
-
"version": "0.
|
|
77
|
+
"version": "0.3.1"
|
|
78
78
|
},
|
|
79
79
|
"packageManager": "npm",
|
|
80
80
|
"presets": {
|
|
@@ -88,181 +88,164 @@ Example for the `0.2.19` target:
|
|
|
88
88
|
|
|
89
89
|
This manifest records scaffold identity only. Do not place secrets in it.
|
|
90
90
|
|
|
91
|
-
##
|
|
92
|
-
|
|
93
|
-
Database choices add starter configuration and the matching driver:
|
|
94
|
-
|
|
95
|
-
- MySQL: `mysql2`
|
|
96
|
-
- PostgreSQL: `pg`
|
|
97
|
-
- SQLite: `better-sqlite3`
|
|
98
|
-
- MongoDB: `mongodb`
|
|
99
|
-
- None: no database dependency
|
|
91
|
+
## Application Platform
|
|
100
92
|
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
## Authentication and security
|
|
104
|
-
|
|
105
|
-
The JWT Cookie preset creates starter authentication code. BCP supports revocable session stores, permission/policy authorization, route guards and same-origin/CSRF helpers.
|
|
106
|
-
|
|
107
|
-
## Background jobs, workflows and events
|
|
93
|
+
Applications can centralize server infrastructure through `bcp/application`:
|
|
108
94
|
|
|
109
95
|
```ts
|
|
110
96
|
import {
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
97
|
+
createApp,
|
|
98
|
+
} from "bcp/application";
|
|
99
|
+
|
|
100
|
+
export const app =
|
|
101
|
+
createApp({
|
|
102
|
+
name: "my-app",
|
|
103
|
+
});
|
|
117
104
|
```
|
|
118
105
|
|
|
119
|
-
|
|
106
|
+
Existing BCP subsystem APIs remain independently usable.
|
|
120
107
|
|
|
121
|
-
##
|
|
108
|
+
## Dependency Injection & Service Container — 0.3.1+
|
|
109
|
+
|
|
110
|
+
Typed dependencies use `bcp/container`:
|
|
122
111
|
|
|
123
112
|
```ts
|
|
124
113
|
import {
|
|
125
|
-
|
|
126
|
-
|
|
114
|
+
createServiceToken,
|
|
115
|
+
provideFactory,
|
|
116
|
+
provideValue,
|
|
117
|
+
} from "bcp/container";
|
|
118
|
+
|
|
119
|
+
const configToken =
|
|
120
|
+
createServiceToken<{
|
|
121
|
+
apiUrl: string;
|
|
122
|
+
}>("config");
|
|
123
|
+
|
|
124
|
+
const repositoryToken =
|
|
125
|
+
createServiceToken<UserRepository>(
|
|
126
|
+
"user-repository"
|
|
127
|
+
);
|
|
127
128
|
|
|
128
|
-
export const
|
|
129
|
-
|
|
129
|
+
export const app =
|
|
130
|
+
createApp({
|
|
131
|
+
name: "my-app",
|
|
132
|
+
providers: [
|
|
133
|
+
provideValue(
|
|
134
|
+
configToken,
|
|
135
|
+
{
|
|
136
|
+
apiUrl: "https://api.example.com",
|
|
137
|
+
}
|
|
138
|
+
),
|
|
139
|
+
provideFactory(
|
|
140
|
+
repositoryToken,
|
|
141
|
+
[
|
|
142
|
+
configToken,
|
|
143
|
+
] as const,
|
|
144
|
+
(_context, [config]) =>
|
|
145
|
+
createRepository(
|
|
146
|
+
config.apiUrl
|
|
147
|
+
)
|
|
148
|
+
),
|
|
149
|
+
],
|
|
150
|
+
});
|
|
130
151
|
```
|
|
131
152
|
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
## Testing
|
|
135
|
-
|
|
136
|
-
`bcp/testing` provides request/route/page/auth/database/middleware/jobs/workflow/outbox/realtime test harnesses and does not require Jest or Vitest.
|
|
137
|
-
|
|
138
|
-
## Plugins
|
|
139
|
-
|
|
140
|
-
`bcp/plugins` provides dependency ordering, module composition, lifecycle hooks, config parsing, shared services and async hooks.
|
|
141
|
-
|
|
142
|
-
## Cache Platform v2
|
|
153
|
+
Resolve from server/application code:
|
|
143
154
|
|
|
144
155
|
```ts
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
export const cache =
|
|
150
|
-
createCacheStore();
|
|
156
|
+
const repository =
|
|
157
|
+
await app.container.resolve(
|
|
158
|
+
repositoryToken
|
|
159
|
+
);
|
|
151
160
|
```
|
|
152
161
|
|
|
153
|
-
|
|
162
|
+
Supported lifetimes:
|
|
154
163
|
|
|
155
|
-
|
|
164
|
+
```text
|
|
165
|
+
singleton
|
|
166
|
+
scoped
|
|
167
|
+
transient
|
|
168
|
+
```
|
|
156
169
|
|
|
157
|
-
|
|
158
|
-
import {
|
|
159
|
-
createTracer,
|
|
160
|
-
} from "bcp/observability";
|
|
170
|
+
For request/job/test boundaries:
|
|
161
171
|
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
172
|
+
```ts
|
|
173
|
+
const scope =
|
|
174
|
+
app.createScope({
|
|
175
|
+
name: "request:123",
|
|
165
176
|
});
|
|
166
177
|
```
|
|
167
178
|
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
## Deployment Platform v2 — 0.2.18+
|
|
171
|
-
|
|
172
|
-
Use `bcp/deployment` to coordinate application resources in production:
|
|
179
|
+
Testing overrides:
|
|
173
180
|
|
|
174
181
|
```ts
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
+
const testScope =
|
|
183
|
+
app.createScope({
|
|
184
|
+
name: "test",
|
|
185
|
+
overrides: [
|
|
186
|
+
provideValue(
|
|
187
|
+
mailerToken,
|
|
188
|
+
fakeMailer
|
|
189
|
+
),
|
|
190
|
+
],
|
|
182
191
|
});
|
|
183
192
|
```
|
|
184
193
|
|
|
185
|
-
|
|
194
|
+
DI is optional. Existing `app.services` and plugin service registries remain supported.
|
|
195
|
+
|
|
196
|
+
## Lifecycle resources
|
|
197
|
+
|
|
198
|
+
Long-running infrastructure still uses Deployment Platform resources:
|
|
186
199
|
|
|
187
200
|
```ts
|
|
188
|
-
|
|
201
|
+
app.addResource({
|
|
189
202
|
name: "database",
|
|
190
203
|
|
|
191
|
-
|
|
192
|
-
|
|
204
|
+
start() {
|
|
205
|
+
return database.connect();
|
|
193
206
|
},
|
|
194
207
|
|
|
195
208
|
ready() {
|
|
196
|
-
return
|
|
197
|
-
},
|
|
198
|
-
|
|
199
|
-
async stop() {
|
|
200
|
-
await db.close();
|
|
201
|
-
},
|
|
202
|
-
});
|
|
203
|
-
|
|
204
|
-
deployment.addResource({
|
|
205
|
-
name: "workers",
|
|
206
|
-
|
|
207
|
-
start() {
|
|
208
|
-
worker = jobs.startWorker();
|
|
209
|
+
return database.ready;
|
|
209
210
|
},
|
|
210
211
|
|
|
211
|
-
|
|
212
|
-
|
|
212
|
+
stop() {
|
|
213
|
+
return database.close();
|
|
213
214
|
},
|
|
214
215
|
});
|
|
215
|
-
|
|
216
|
-
await deployment.start();
|
|
217
216
|
```
|
|
218
217
|
|
|
219
|
-
|
|
218
|
+
In `0.3.1`, the DI container remains active until application resources and plugins have stopped, then disposes injected services in reverse creation order.
|
|
220
219
|
|
|
221
|
-
|
|
220
|
+
## Database presets
|
|
222
221
|
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
222
|
+
- MySQL: `mysql2`
|
|
223
|
+
- PostgreSQL: `pg`
|
|
224
|
+
- SQLite: `better-sqlite3`
|
|
225
|
+
- MongoDB: `mongodb`
|
|
226
|
+
- None: no database dependency
|
|
227
227
|
|
|
228
|
-
|
|
229
|
-
return createDeploymentReadinessResponse(
|
|
230
|
-
deployment
|
|
231
|
-
);
|
|
232
|
-
}
|
|
233
|
-
```
|
|
228
|
+
For MySQL, PostgreSQL and SQLite, generated `lib/database.ts` exposes BCP database primitives through `bcp/database`.
|
|
234
229
|
|
|
235
|
-
|
|
230
|
+
## Authentication and security
|
|
236
231
|
|
|
237
|
-
|
|
238
|
-
BCP_DEPLOYMENT_ID
|
|
239
|
-
BCP_INSTANCE_ID
|
|
240
|
-
BCP_RELEASE
|
|
241
|
-
NODE_ENV
|
|
242
|
-
BCP_SHUTDOWN_TIMEOUT_MS
|
|
243
|
-
```
|
|
232
|
+
The JWT Cookie preset creates starter authentication code. BCP supports revocable session stores, permission/policy authorization, route guards and same-origin/CSRF helpers.
|
|
244
233
|
|
|
245
|
-
|
|
234
|
+
## Jobs, workflows, events and realtime
|
|
246
235
|
|
|
247
|
-
|
|
248
|
-
const removeSignals =
|
|
249
|
-
deployment.installSignalHandlers();
|
|
250
|
-
```
|
|
236
|
+
Use `bcp/jobs`, `bcp/workflow`, `bcp/events` and `bcp/realtime` directly or register selected instances with the Application Platform/DI container.
|
|
251
237
|
|
|
252
|
-
|
|
238
|
+
## Testing
|
|
253
239
|
|
|
254
|
-
|
|
240
|
+
`bcp/testing` provides framework-native request/route/page/auth/database/middleware/jobs/workflow/outbox/realtime helpers. DI scope overrides complement these helpers for application-level dependency replacement.
|
|
255
241
|
|
|
256
|
-
|
|
242
|
+
## Plugins
|
|
257
243
|
|
|
258
|
-
|
|
244
|
+
`bcp/plugins` remains available for reusable plugin/module lifecycle composition. Plugin definitions/modules can be passed to `createApp()`.
|
|
259
245
|
|
|
260
|
-
|
|
261
|
-
npm run api:check
|
|
262
|
-
npm run release:readiness
|
|
263
|
-
```
|
|
246
|
+
## Observability and deployment
|
|
264
247
|
|
|
265
|
-
|
|
248
|
+
`bcp/observability` provides metrics/tracing. `bcp/deployment` remains available when an application wants to own resource lifecycle directly; `bcp/application` reuses its readiness/diagnostics/shutdown model.
|
|
266
249
|
|
|
267
250
|
## Application packaging
|
|
268
251
|
|
|
@@ -271,9 +254,7 @@ npm run build
|
|
|
271
254
|
npm run package
|
|
272
255
|
```
|
|
273
256
|
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
BCP `0.2.19` prepared framework packages preserve the compiled ESM runtime map introduced by Deployment Platform v2 for the main server entrypoints including config, auth, observability, deployment, server and middleware.
|
|
257
|
+
BCP `0.3.1` prepared packages include compiled `container.mjs` and `application.mjs` server runtimes. Project `.env` files and application devDependencies are excluded from deployment packages.
|
|
277
258
|
|
|
278
259
|
## Project generators
|
|
279
260
|
|
|
@@ -301,5 +282,5 @@ npm run generate -- migration create_users
|
|
|
301
282
|
For prerelease/local package verification:
|
|
302
283
|
|
|
303
284
|
```bash
|
|
304
|
-
npx create-bcp-app my-app --bcp file:../chidchanun-bcp-0.
|
|
285
|
+
npx create-bcp-app my-app --bcp file:../chidchanun-bcp-0.3.1.tgz
|
|
305
286
|
```
|
package/package.json
CHANGED
package/template/README.md
CHANGED
|
@@ -27,162 +27,182 @@ npm run update
|
|
|
27
27
|
|
|
28
28
|
Generated projects include `bcp.project.json` with non-secret scaffold metadata. Commit it with the project, but never put passwords, tokens or access keys in it.
|
|
29
29
|
|
|
30
|
-
##
|
|
31
|
-
|
|
32
|
-
JWT Cookie projects can use `createAuth()` and optional `AuthSessionStore` revocation. Permission guards/resource policies live in `bcp/auth`; same-origin/CSRF helpers live in `bcp/server`.
|
|
33
|
-
|
|
34
|
-
## Database
|
|
30
|
+
## Application Platform — BCP 0.3.x
|
|
35
31
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
## Jobs, scheduling and workflows
|
|
32
|
+
For applications with several server subsystems, `bcp/application` provides one optional composition root:
|
|
39
33
|
|
|
40
34
|
```ts
|
|
41
35
|
import {
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
} from "bcp/jobs";
|
|
45
|
-
import {
|
|
46
|
-
createWorkflow,
|
|
47
|
-
} from "bcp/workflow";
|
|
48
|
-
```
|
|
49
|
-
|
|
50
|
-
Durable jobs support leases, heartbeat, stale recovery and DLQ. Workflows support sequential/parallel steps, retries, persisted delays and compensation.
|
|
36
|
+
createApp,
|
|
37
|
+
} from "bcp/application";
|
|
51
38
|
|
|
52
|
-
|
|
39
|
+
export const app =
|
|
40
|
+
createApp({
|
|
41
|
+
name: "bcp-app",
|
|
42
|
+
});
|
|
43
|
+
```
|
|
53
44
|
|
|
54
|
-
|
|
45
|
+
## Dependency Injection — BCP 0.3.1+
|
|
55
46
|
|
|
56
|
-
|
|
47
|
+
Use `bcp/container` for typed application dependencies:
|
|
57
48
|
|
|
58
49
|
```ts
|
|
59
50
|
import {
|
|
60
|
-
|
|
61
|
-
|
|
51
|
+
createServiceToken,
|
|
52
|
+
provideFactory,
|
|
53
|
+
provideValue,
|
|
54
|
+
} from "bcp/container";
|
|
55
|
+
|
|
56
|
+
const configToken =
|
|
57
|
+
createServiceToken<{
|
|
58
|
+
apiUrl: string;
|
|
59
|
+
}>("config");
|
|
60
|
+
|
|
61
|
+
const clientToken =
|
|
62
|
+
createServiceToken<ApiClient>(
|
|
63
|
+
"api-client"
|
|
64
|
+
);
|
|
62
65
|
|
|
63
|
-
export const
|
|
64
|
-
|
|
66
|
+
export const app =
|
|
67
|
+
createApp({
|
|
68
|
+
name: "bcp-app",
|
|
69
|
+
providers: [
|
|
70
|
+
provideValue(
|
|
71
|
+
configToken,
|
|
72
|
+
{
|
|
73
|
+
apiUrl: "https://api.example.com",
|
|
74
|
+
}
|
|
75
|
+
),
|
|
76
|
+
provideFactory(
|
|
77
|
+
clientToken,
|
|
78
|
+
[
|
|
79
|
+
configToken,
|
|
80
|
+
] as const,
|
|
81
|
+
(_context, [config]) =>
|
|
82
|
+
createApiClient(
|
|
83
|
+
config.apiUrl
|
|
84
|
+
)
|
|
85
|
+
),
|
|
86
|
+
],
|
|
87
|
+
});
|
|
65
88
|
```
|
|
66
89
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
## Testing
|
|
70
|
-
|
|
71
|
-
`bcp/testing` provides request/route/page/auth/database/middleware/jobs/workflow/outbox/realtime/SSE test helpers without requiring Jest or Vitest.
|
|
72
|
-
|
|
73
|
-
## Plugins
|
|
74
|
-
|
|
75
|
-
`bcp/plugins` provides reusable server-side plugins/modules, dependency ordering, lifecycle hooks, config parsing, shared services and awaited hooks.
|
|
76
|
-
|
|
77
|
-
## Cache Platform v2
|
|
90
|
+
Resolve typed services:
|
|
78
91
|
|
|
79
92
|
```ts
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
export const cache =
|
|
85
|
-
createCacheStore();
|
|
93
|
+
const client =
|
|
94
|
+
await app.container.resolve(
|
|
95
|
+
clientToken
|
|
96
|
+
);
|
|
86
97
|
```
|
|
87
98
|
|
|
88
|
-
|
|
99
|
+
Provider lifetimes are `singleton`, `scoped` and `transient`.
|
|
89
100
|
|
|
90
|
-
|
|
101
|
+
For request/job/test scopes:
|
|
91
102
|
|
|
92
103
|
```ts
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
export const tracer =
|
|
98
|
-
createTracer({
|
|
99
|
-
serviceName: "bcp-app",
|
|
104
|
+
const scope =
|
|
105
|
+
app.createScope({
|
|
106
|
+
name: "request:123",
|
|
100
107
|
});
|
|
101
108
|
```
|
|
102
109
|
|
|
103
|
-
|
|
110
|
+
Testing overrides can replace selected providers within a child scope without changing the root application container.
|
|
104
111
|
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
Use `bcp/deployment` to manage production resource lifecycle:
|
|
112
|
+
The legacy Plugin Platform registry remains supported:
|
|
108
113
|
|
|
109
114
|
```ts
|
|
110
|
-
|
|
111
|
-
createDeploymentRuntime,
|
|
112
|
-
} from "bcp/deployment";
|
|
113
|
-
|
|
114
|
-
export const deployment =
|
|
115
|
-
createDeploymentRuntime({
|
|
116
|
-
serviceName: "bcp-app",
|
|
117
|
-
});
|
|
115
|
+
app.provide("database", database);
|
|
118
116
|
```
|
|
119
117
|
|
|
120
|
-
|
|
118
|
+
Use typed `ServiceToken<T>` providers for new application dependency injection code.
|
|
119
|
+
|
|
120
|
+
## Lifecycle resources
|
|
121
|
+
|
|
122
|
+
Long-running infrastructure uses `app.addResource()`:
|
|
121
123
|
|
|
122
124
|
```ts
|
|
123
|
-
|
|
125
|
+
app.addResource({
|
|
124
126
|
name: "database",
|
|
125
127
|
|
|
126
|
-
|
|
127
|
-
|
|
128
|
+
start() {
|
|
129
|
+
return database.connect();
|
|
128
130
|
},
|
|
129
131
|
|
|
130
132
|
ready() {
|
|
131
|
-
return
|
|
133
|
+
return database.ready;
|
|
132
134
|
},
|
|
133
135
|
|
|
134
|
-
|
|
135
|
-
|
|
136
|
+
stop() {
|
|
137
|
+
return database.close();
|
|
136
138
|
},
|
|
137
139
|
});
|
|
138
140
|
```
|
|
139
141
|
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
Start runtime:
|
|
142
|
+
Then start the application runtime from server/bootstrap code:
|
|
143
143
|
|
|
144
144
|
```ts
|
|
145
|
-
await
|
|
145
|
+
await app.start();
|
|
146
146
|
```
|
|
147
147
|
|
|
148
|
-
|
|
148
|
+
BCP `0.3.1` keeps the DI container alive until application resources/plugins have stopped, then disposes resolved services in reverse creation order.
|
|
149
|
+
|
|
150
|
+
## Authentication and authorization
|
|
151
|
+
|
|
152
|
+
JWT Cookie projects can use `createAuth()` and optional `AuthSessionStore` revocation. Permission guards/resource policies live in `bcp/auth`; same-origin/CSRF helpers live in `bcp/server`.
|
|
153
|
+
|
|
154
|
+
## Database
|
|
155
|
+
|
|
156
|
+
MySQL, PostgreSQL and SQLite projects expose database primitives through `bcp/database`.
|
|
157
|
+
|
|
158
|
+
## Jobs, workflows and events
|
|
159
|
+
|
|
160
|
+
Use `bcp/jobs`, `bcp/workflow` and `bcp/events` independently or compose instances through the Application Platform.
|
|
161
|
+
|
|
162
|
+
## Realtime
|
|
149
163
|
|
|
150
164
|
```ts
|
|
151
165
|
import {
|
|
152
|
-
|
|
153
|
-
} from "bcp/
|
|
166
|
+
createRealtime,
|
|
167
|
+
} from "bcp/realtime";
|
|
154
168
|
|
|
155
|
-
export
|
|
156
|
-
|
|
157
|
-
deployment
|
|
158
|
-
);
|
|
159
|
-
}
|
|
169
|
+
export const realtime =
|
|
170
|
+
createRealtime();
|
|
160
171
|
```
|
|
161
172
|
|
|
162
|
-
|
|
173
|
+
BCP does not install a WebSocket server library. Adapt the selected provider through `RealtimeSocket`; SSE is built in.
|
|
163
174
|
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
175
|
+
## Testing
|
|
176
|
+
|
|
177
|
+
`bcp/testing` provides framework-native server test helpers. `bcp/container` child-scope overrides can replace application dependencies during tests.
|
|
178
|
+
|
|
179
|
+
## Plugins
|
|
180
|
+
|
|
181
|
+
`bcp/plugins` provides reusable server-side plugins/modules, dependency ordering, lifecycle hooks, config parsing, shared services and awaited hooks.
|
|
182
|
+
|
|
183
|
+
## Cache and observability
|
|
184
|
+
|
|
185
|
+
`bcp/cache` provides provider-neutral cache/lock primitives. `bcp/observability` provides metrics, health and tracing.
|
|
186
|
+
|
|
187
|
+
## Deployment lifecycle
|
|
168
188
|
|
|
169
|
-
|
|
189
|
+
`bcp/deployment` remains available for direct lifecycle ownership. `bcp/application` composes the same readiness/diagnostics/shutdown model.
|
|
170
190
|
|
|
171
|
-
|
|
191
|
+
Application startup order in `0.3.1` is:
|
|
172
192
|
|
|
173
193
|
```text
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
194
|
+
application setup
|
|
195
|
+
container
|
|
196
|
+
plugins
|
|
197
|
+
resources
|
|
198
|
+
application start
|
|
179
199
|
```
|
|
180
200
|
|
|
181
|
-
|
|
201
|
+
Shutdown reverses deployment dependencies, then runs application disposal.
|
|
182
202
|
|
|
183
|
-
|
|
203
|
+
## API baseline
|
|
184
204
|
|
|
185
|
-
Application code should
|
|
205
|
+
BCP `0.3.1` advances `0.3.0` additively with `bcp/container`. Application code should use documented public `bcp/*` entrypoints and avoid private framework `packages/*` paths.
|
|
186
206
|
|
|
187
207
|
## Production build
|
|
188
208
|
|
|
@@ -197,9 +217,9 @@ npm start
|
|
|
197
217
|
npm run package
|
|
198
218
|
```
|
|
199
219
|
|
|
200
|
-
BCP excludes project `.env` files and application `devDependencies` from
|
|
220
|
+
BCP excludes project `.env` files and application `devDependencies` from deployment packages. Supply secrets through the deployment environment.
|
|
201
221
|
|
|
202
|
-
|
|
222
|
+
Prepared `0.3.1` packages include compiled `container.mjs` and `application.mjs` runtimes.
|
|
203
223
|
|
|
204
224
|
## Direct CLI usage
|
|
205
225
|
|