@camstack/system 1.2.200 → 1.2.202
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/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.js +1 -1
- package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.mjs +1 -1
- package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.js +1 -1
- package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.mjs +1 -1
- package/dist/builtins/alerts/alerts.addon.js +1 -1
- package/dist/builtins/alerts/alerts.addon.mjs +1 -1
- package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.d.ts +38 -9
- package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.js +234 -81
- package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.mjs +234 -81
- package/dist/builtins/backup-orchestrator/destination-policy.d.ts +32 -14
- package/dist/builtins/backup-orchestrator/schedule-store.d.ts +12 -2
- package/dist/builtins/console-logging/index.js +1 -1
- package/dist/builtins/console-logging/index.mjs +1 -1
- package/dist/builtins/core-blocks/core-blocks.addon.js +1 -1
- package/dist/builtins/core-blocks/core-blocks.addon.mjs +1 -1
- package/dist/builtins/device-manager/device-manager.addon.js +2 -2
- package/dist/builtins/device-manager/device-manager.addon.mjs +2 -2
- package/dist/builtins/doorbell/virtual-doorbell.addon.js +1 -1
- package/dist/builtins/doorbell/virtual-doorbell.addon.mjs +1 -1
- package/dist/builtins/hub-forwarder/index.js +1 -1
- package/dist/builtins/hub-forwarder/index.mjs +1 -1
- package/dist/builtins/liveness-monitor/liveness-monitor.addon.js +1 -1
- package/dist/builtins/liveness-monitor/liveness-monitor.addon.mjs +1 -1
- package/dist/builtins/local-auth/local-auth.addon.js +1 -1
- package/dist/builtins/local-auth/local-auth.addon.mjs +1 -1
- package/dist/builtins/local-network/local-network.addon.js +1 -1
- package/dist/builtins/local-network/local-network.addon.mjs +1 -1
- package/dist/builtins/loki-logging/index.js +1 -1
- package/dist/builtins/loki-logging/index.mjs +1 -1
- package/dist/builtins/native-metrics/native-metrics.addon.js +1 -1
- package/dist/builtins/native-metrics/native-metrics.addon.mjs +1 -1
- package/dist/builtins/platform-probe/index.js +1 -1
- package/dist/builtins/platform-probe/index.mjs +1 -1
- package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +1 -1
- package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +1 -1
- package/dist/builtins/snapshot/index.js +1 -1
- package/dist/builtins/snapshot/index.mjs +1 -1
- package/dist/builtins/sqlite-storage/filesystem-storage.addon.js +1 -1
- package/dist/builtins/sqlite-storage/filesystem-storage.addon.mjs +1 -1
- package/dist/builtins/sqlite-storage/sqlite-settings.addon.js +0 -0
- package/dist/builtins/sqlite-storage/sqlite-settings.addon.mjs +0 -0
- package/dist/builtins/storage-orchestrator/location-store.d.ts +12 -3
- package/dist/builtins/storage-orchestrator/storage-migration-coordinator.d.ts +9 -9
- package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.js +181 -129
- package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.mjs +181 -129
- package/dist/builtins/storage-orchestrator/storage-orchestrator.service.d.ts +54 -31
- package/dist/builtins/system-config/system-config.addon.js +1 -1
- package/dist/builtins/system-config/system-config.addon.mjs +1 -1
- package/dist/builtins/winston-logging/index.js +1 -1
- package/dist/builtins/winston-logging/index.mjs +1 -1
- package/dist/{dist-CCp74QLJ.mjs → dist-CiHYspij.mjs} +235 -199
- package/dist/{dist-KQ5D2wqr.js → dist-jZb-HKI5.js} +246 -198
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/dist/{retired-settings-keys-7P9XwNdl.mjs → retired-settings-keys-DeRxo3vg.mjs} +1 -1
- package/dist/{retired-settings-keys-2lWk7OeU.js → retired-settings-keys-Dxv9S_lO.js} +1 -1
- package/package.json +1 -1
|
@@ -184,23 +184,31 @@ export declare class StorageOrchestratorService {
|
|
|
184
184
|
*/
|
|
185
185
|
attachStore(store: ILocationStore): Promise<void>;
|
|
186
186
|
/**
|
|
187
|
-
*
|
|
187
|
+
* ONE explicit migration onto the enabled write set (D383), run once per
|
|
188
|
+
* boot against the rows that came off disk. Idempotent: the second boot finds
|
|
189
|
+
* nothing to do.
|
|
188
190
|
*
|
|
189
|
-
*
|
|
190
|
-
*
|
|
191
|
-
* hand-edited store or a row written by another build can too. It matters
|
|
192
|
-
* because every bare-type ref still resolves through {@link getDefaultLocation}
|
|
193
|
-
* until Stage 5 of the enabled-write-set design: on such a row
|
|
194
|
-
* `storage.write({ location: 'eventMedia' })` and the migration coordinator's
|
|
195
|
-
* drain destination both point at a disk the operator turned off.
|
|
191
|
+
* Two steps, in order, and each one is a WRITE — the point is that "absent"
|
|
192
|
+
* stops existing rather than being re-interpreted on every read forever:
|
|
196
193
|
*
|
|
197
|
-
*
|
|
198
|
-
*
|
|
199
|
-
*
|
|
200
|
-
*
|
|
201
|
-
*
|
|
194
|
+
* 1. A flagless row (persisted before `enabled` existed) is stamped
|
|
195
|
+
* `enabled: true`. Absence already meant active, so this preserves
|
|
196
|
+
* behaviour exactly; it is the operator's "the initial locations are
|
|
197
|
+
* enabled" spelled into the store.
|
|
198
|
+
* 2. A type left with NO enabled row — only reachable from a hand-edited
|
|
199
|
+
* store or a row an older build wrote — gets one enabled back, chosen as
|
|
200
|
+
* the row the RETIRED default flag named, else the `:default`-slugged
|
|
201
|
+
* row, else the lexicographically first. Loudly: a class with no write
|
|
202
|
+
* target records nowhere, and refusing to repair it here would leave the
|
|
203
|
+
* hub silently unable to write with no operator action pending.
|
|
204
|
+
*
|
|
205
|
+
* An operator's explicit `enabled: false` is never reversed by step 1 — only
|
|
206
|
+
* step 2 touches it, and only when the alternative is a class that cannot
|
|
207
|
+
* write at all.
|
|
202
208
|
*/
|
|
203
|
-
private
|
|
209
|
+
private migrateOntoTheWriteSet;
|
|
210
|
+
/** Apply one migrated row in memory and mirror it to the store. */
|
|
211
|
+
private persistMigrated;
|
|
204
212
|
/**
|
|
205
213
|
* Inject the declaration-driven cardinality source. Called once by the
|
|
206
214
|
* addon after the kernel aggregates every addon's `storageLocations`
|
|
@@ -259,22 +267,36 @@ export declare class StorageOrchestratorService {
|
|
|
259
267
|
*/
|
|
260
268
|
backfillNodeIds(hubNodeId: string): Promise<void>;
|
|
261
269
|
listLocations(filter?: ListLocationsFilter): readonly StorageLocation[];
|
|
262
|
-
getDefaultLocation(type: string): StorageLocation | null;
|
|
263
270
|
/**
|
|
264
|
-
*
|
|
265
|
-
*
|
|
266
|
-
* a
|
|
267
|
-
* the
|
|
271
|
+
* The WRITE SET of a type: every enabled location of it, in stable id order.
|
|
272
|
+
* This replaced `getDefaultLocation` (D383) — a type does not have one write
|
|
273
|
+
* target any more, it has a pool, and every consumer that must pick one picks
|
|
274
|
+
* from here by its own rule (the recorder by headroom, a drain by an operator
|
|
275
|
+
* -named destination).
|
|
276
|
+
*/
|
|
277
|
+
writeTargets(type: string): readonly StorageLocation[];
|
|
278
|
+
/**
|
|
279
|
+
* Change the WRITE SET as one compensated commit: each named location is
|
|
280
|
+
* enabled (it joins the pool) or disabled (it becomes read-only — still read,
|
|
281
|
+
* still played back, still age-swept, still drained).
|
|
282
|
+
*
|
|
283
|
+
* This is the cutover verb, and its only caller is the migration coordinator,
|
|
284
|
+
* which persists its `repointing` phase BEFORE calling so a crash mid-write
|
|
285
|
+
* is recovered by replaying the same idempotent set before writers resume.
|
|
286
|
+
*
|
|
287
|
+
* It moves ONLY the locations it is given: a cutover from A to C on a class
|
|
288
|
+
* that also writes to B leaves B in the pool, because the operator's pool is
|
|
289
|
+
* the authority and a migration is not a licence to shrink it. The commit is
|
|
290
|
+
* refused when it would leave a write-serving type with nothing enabled —
|
|
291
|
+
* the same refusal `upsertLocation` applies, judged on the RESULT so an
|
|
292
|
+
* enable and a disable in one commit are weighed together.
|
|
268
293
|
*/
|
|
269
|
-
|
|
294
|
+
setWriteTargets(enabledByLocationId: ReadonlyMap<string, boolean>): Promise<void>;
|
|
270
295
|
/**
|
|
271
|
-
* Insert or update a location.
|
|
272
|
-
* demotes any other default for the same type — operators always see
|
|
273
|
-
* exactly one default per type.
|
|
296
|
+
* Insert or update a location.
|
|
274
297
|
*
|
|
275
|
-
* When a persistence store is wired (Task 6), the
|
|
276
|
-
*
|
|
277
|
-
* mutation returns. Persistence errors propagate to the caller.
|
|
298
|
+
* When a persistence store is wired (Task 6), the record is mirrored to it;
|
|
299
|
+
* the mirror is fire-and-forget and its errors reach the logger.
|
|
278
300
|
*/
|
|
279
301
|
/**
|
|
280
302
|
* Refuse a `(location kind, provider)` pair the kind cannot use.
|
|
@@ -310,8 +332,7 @@ export declare class StorageOrchestratorService {
|
|
|
310
332
|
/**
|
|
311
333
|
* Remove a location. Refuses the last location of a type and the last
|
|
312
334
|
* enabled location of a type. `isSystem` is informational — a frozen
|
|
313
|
-
* recordings `:default` is deletable once a sibling is live.
|
|
314
|
-
* the flagged default promotes an enabled sibling. Occupancy still
|
|
335
|
+
* recordings `:default` is deletable once a sibling is live. Occupancy still
|
|
315
336
|
* refuses unless `force` is set; force never overrides uniqueness /
|
|
316
337
|
* last-enabled.
|
|
317
338
|
*/
|
|
@@ -392,9 +413,11 @@ export declare class StorageOrchestratorService {
|
|
|
392
413
|
* declarations on a populated map is a no-op (each declared `id`
|
|
393
414
|
* already resolves to an existing `<id>:default`).
|
|
394
415
|
*
|
|
395
|
-
*
|
|
396
|
-
* `
|
|
397
|
-
*
|
|
416
|
+
* The seeded row is born ENABLED — a fresh install must be able to write the
|
|
417
|
+
* moment it boots, and `enabled` is the only write switch there is (D383).
|
|
418
|
+
* The `:default` suffix is a NAME kept for idempotency across existing
|
|
419
|
+
* installs, not a flag: the stored `id` is `'recordings:default'` so it
|
|
420
|
+
* satisfies the
|
|
398
421
|
* `^[a-z][a-z0-9-]*:[a-z0-9-]+$` regex on `StorageLocationSchema.id`.
|
|
399
422
|
*
|
|
400
423
|
* `basePath` is the storage root (e.g. `<CAMSTACK_DATA>`). Each
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-jZb-HKI5.js");
|
|
7
7
|
//#region src/builtins/system-config/system-config.addon.ts
|
|
8
8
|
/**
|
|
9
9
|
* Built-in `system-config` addon — Phase 4 of the settings redesign.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Lt as errMsg, Rt as BaseAddon, tn as hydrateSchema } from "../../dist-CiHYspij.mjs";
|
|
2
2
|
//#region src/builtins/system-config/system-config.addon.ts
|
|
3
3
|
/**
|
|
4
4
|
* Built-in `system-config` addon — Phase 4 of the settings redesign.
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-jZb-HKI5.js");
|
|
7
7
|
const require_formatter = require("../../formatter-DqAKDlvN.js");
|
|
8
8
|
let node_path = require("node:path");
|
|
9
9
|
node_path = require_chunk.__toESM(node_path);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Rt as BaseAddon, dt as logDestinationCapability } from "../../dist-CiHYspij.mjs";
|
|
2
2
|
import { t as formatLogLine } from "../../formatter-B7qW8bPJ.mjs";
|
|
3
3
|
import * as path$1 from "node:path";
|
|
4
4
|
import path from "node:path";
|