@camstack/server 1.2.803 → 1.2.805
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/CHANGELOG.md +13 -0
- package/dist/agent/main.js +1 -1
- package/dist/api/core/addon-settings.router.js +2 -2
- package/dist/api/trpc/device-config-secret-redaction.js +3 -5
- package/dist/api/trpc/generated-cap-routers.js +10 -24
- package/dist/api/trpc/localized-schema-paths.js +0 -2
- package/dist/core/addon/addon-registry.service.js +4 -4
- package/dist/core/addon/addon-settings-provider.js +2 -49
- package/package.json +34 -15
- package/system/dist/addon-runner.js +2 -9
- package/system/dist/addon-runner.mjs +2 -9
- package/system/dist/{agent-https-DtYiXPGm.js → agent-https-CuChFRA2.js} +1 -1
- package/system/dist/{agent-https-BRfJO9ZR.mjs → agent-https-DS4b0ucn.mjs} +1 -1
- package/system/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.js +1 -1
- package/system/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.mjs +1 -1
- package/system/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.js +1 -1
- package/system/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.mjs +1 -1
- package/system/dist/builtins/alerts/alerts.addon.js +1 -1
- package/system/dist/builtins/alerts/alerts.addon.mjs +1 -1
- package/system/dist/builtins/autotrack/index.js +1 -1
- package/system/dist/builtins/autotrack/index.mjs +1 -1
- package/system/dist/builtins/backup-orchestrator/backup-orchestrator.addon.js +2 -2
- package/system/dist/builtins/backup-orchestrator/backup-orchestrator.addon.mjs +2 -2
- package/system/dist/builtins/calendars/calendars.addon.js +1 -1
- package/system/dist/builtins/calendars/calendars.addon.mjs +1 -1
- package/system/dist/builtins/camera-grid/index.js +1 -1
- package/system/dist/builtins/camera-grid/index.mjs +1 -1
- package/system/dist/builtins/composer/composed-device.d.ts +5 -0
- package/system/dist/builtins/composer/composer.addon.js +39 -4
- package/system/dist/builtins/composer/composer.addon.mjs +39 -4
- package/system/dist/builtins/composer/composer.d.ts +13 -0
- package/system/dist/builtins/console-logging/index.js +1 -1
- package/system/dist/builtins/console-logging/index.mjs +1 -1
- package/system/dist/builtins/core-blocks/core-blocks.addon.js +4 -5
- package/system/dist/builtins/core-blocks/core-blocks.addon.mjs +4 -5
- package/system/dist/builtins/device-history/device-history.addon.js +2 -2
- package/system/dist/builtins/device-history/device-history.addon.mjs +2 -2
- package/system/dist/builtins/device-manager/device-alias-actions.d.ts +45 -0
- package/system/dist/builtins/device-manager/device-manager.addon.js +958 -768
- package/system/dist/builtins/device-manager/device-manager.addon.mjs +958 -768
- package/system/dist/builtins/device-manager/device-meta-types.d.ts +3 -0
- package/system/dist/builtins/device-manager/device-row-store.d.ts +8 -0
- package/system/dist/builtins/device-manager/device-template/mirror-resolver.d.ts +19 -0
- package/system/dist/builtins/device-manager/device-template/nunjucks-internals.d.ts +53 -0
- package/system/dist/builtins/device-manager/device-template/template-filters.d.ts +28 -0
- package/system/dist/builtins/device-manager/device-template/template-grammar.d.ts +43 -0
- package/system/dist/builtins/device-manager/device-template/template-protocol.d.ts +33 -0
- package/system/dist/builtins/device-manager/device-template/template-renderer.d.ts +54 -0
- package/system/dist/builtins/device-manager/device-template/template-worker.d.ts +1 -0
- package/system/dist/builtins/hub-forwarder/index.js +1 -1
- package/system/dist/builtins/hub-forwarder/index.mjs +1 -1
- package/system/dist/builtins/keychain/index.js +4 -4
- package/system/dist/builtins/keychain/index.mjs +4 -4
- package/system/dist/builtins/liveness-monitor/liveness-monitor.addon.js +1 -1
- package/system/dist/builtins/liveness-monitor/liveness-monitor.addon.mjs +1 -1
- package/system/dist/builtins/local-auth/local-auth.addon.js +2 -2
- package/system/dist/builtins/local-auth/local-auth.addon.mjs +2 -2
- package/system/dist/builtins/local-network/local-network.addon.js +2 -2
- package/system/dist/builtins/local-network/local-network.addon.mjs +2 -2
- package/system/dist/builtins/loki-logging/index.js +1 -1
- package/system/dist/builtins/loki-logging/index.mjs +1 -1
- package/system/dist/builtins/native-metrics/native-metrics.addon.js +1 -1
- package/system/dist/builtins/native-metrics/native-metrics.addon.mjs +1 -1
- package/system/dist/builtins/platform-probe/index.js +1 -1
- package/system/dist/builtins/platform-probe/index.mjs +1 -1
- package/system/dist/builtins/record-entries/index.js +1 -1
- package/system/dist/builtins/record-entries/index.mjs +1 -1
- package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +1 -1
- package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +1 -1
- package/system/dist/builtins/snapshot/index.js +2 -2
- package/system/dist/builtins/snapshot/index.mjs +2 -2
- package/system/dist/builtins/snapshot/snapshot.addon.d.ts +1 -1
- package/system/dist/builtins/sqlite-storage/filesystem-storage.addon.js +1 -1
- package/system/dist/builtins/sqlite-storage/filesystem-storage.addon.mjs +1 -1
- package/system/dist/builtins/sqlite-storage/index.js +1 -1
- package/system/dist/builtins/sqlite-storage/index.mjs +1 -1
- package/system/dist/builtins/sqlite-storage/sqlite-settings.addon.js +3 -3
- package/system/dist/builtins/sqlite-storage/sqlite-settings.addon.mjs +3 -3
- package/system/dist/builtins/storage-orchestrator/storage-orchestrator.addon.js +1 -1
- package/system/dist/builtins/storage-orchestrator/storage-orchestrator.addon.mjs +1 -1
- package/system/dist/builtins/system-config/bootstrap-form-actions.d.ts +4 -4
- package/system/dist/builtins/system-config/system-config.addon.js +7 -7
- package/system/dist/builtins/system-config/system-config.addon.mjs +7 -7
- package/system/dist/builtins/winston-logging/index.js +1 -1
- package/system/dist/builtins/winston-logging/index.mjs +1 -1
- package/system/dist/{capture-engine-BQ08XTnZ.js → capture-engine-Byc5Fkp0.js} +1 -1
- package/system/dist/{capture-engine-BFgeAHa9.mjs → capture-engine-CnVIcnyN.mjs} +1 -1
- package/system/dist/{composition-sources-DkOfzgpS.mjs → composition-sources-BhM6G9QT.mjs} +1 -1
- package/system/dist/{composition-sources-DNHNUvTr.js → composition-sources-BxK6ttP9.js} +1 -1
- package/system/dist/{constants-D5CG3Gvc.js → constants--xo6Q-KA.js} +1 -1
- package/system/dist/{constants-GCrIKhD_.mjs → constants-Bf1PEHRU.mjs} +1 -1
- package/system/dist/{device-ca-Dk2sx_18.mjs → device-ca-Do0-HV_h.mjs} +1 -1
- package/system/dist/{device-ca-DgZeLVC1.js → device-ca-Uq5KGFSq.js} +1 -1
- package/system/dist/device-template-worker.js +7289 -0
- package/system/dist/device-template-worker.mjs +7287 -0
- package/system/dist/{dist-D5nGm8Sd.js → dist-2SHQaxaS.js} +631 -618
- package/system/dist/{dist-ze-qVU7x.mjs → dist-CogtCQxu.mjs} +608 -619
- package/system/dist/file-host-worker.js +1 -1
- package/system/dist/file-host-worker.mjs +1 -1
- package/system/dist/{hub-mdns-ciao-D4g9qsNL.js → hub-mdns-ciao-DqPrLiYH.js} +2 -2
- package/system/dist/{hub-mdns-ciao-DD2QP3w5.mjs → hub-mdns-ciao-aFHCKrif.mjs} +2 -2
- package/system/dist/index.js +28 -48
- package/system/dist/index.mjs +28 -48
- package/system/dist/kernel/moleculer/addon-service-factory.d.ts +2 -3
- package/system/dist/kernel/transport/child-cap-protocol.d.ts +2 -2
- package/system/dist/kernel/transport/parent-unowned-call.d.ts +1 -1
- package/system/dist/{legacy-integration-rows-door-MRr8Ncb_.js → legacy-integration-rows-door-Bz8rivxI.js} +1 -1
- package/system/dist/{legacy-integration-rows-door-BvEFQrAa.mjs → legacy-integration-rows-door-CiuxDLoc.mjs} +1 -1
- package/system/dist/{restore-archive-aG7OlQNo.js → restore-archive-D-3wmHDq.js} +1 -1
- package/system/dist/{restore-archive-DBc5sNQS.mjs → restore-archive-PlBC2NwT.mjs} +1 -1
- package/system/dist/{wal-maintenance-C-ddHy-q.js → wal-maintenance-BTR55y--.js} +0 -0
- package/system/dist/{wal-maintenance-vQHsOLGg.mjs → wal-maintenance-jrhYTCn2.mjs} +0 -0
- package/system/package.json +1 -1
|
@@ -100,6 +100,9 @@ export interface PersistedDeviceMeta {
|
|
|
100
100
|
* legacy rows — the reconcile treats a non-placeholder name as user-named for
|
|
101
101
|
* safety and stamps the resolved decision forward. */
|
|
102
102
|
userNamed?: boolean;
|
|
103
|
+
/** The template alias (D1021) — see `DeviceInfo.alias`. Absent until the first
|
|
104
|
+
* registration stamps it (or the boot backfill does, for an older row). */
|
|
105
|
+
alias?: string;
|
|
103
106
|
/**
|
|
104
107
|
* Operator-organisational label (room / area / zone). `null` when
|
|
105
108
|
* unset. Mutable through `setLocation` action; surfaced on
|
|
@@ -185,6 +185,8 @@ export declare function deviceRowBackendOf(client: SettingsStoreClient): DeviceR
|
|
|
185
185
|
export interface DeviceRowPatch {
|
|
186
186
|
readonly type?: string;
|
|
187
187
|
readonly name?: string;
|
|
188
|
+
/** The template alias (D1021) — written by the first-registration stamp, `setAlias` and the backfill. */
|
|
189
|
+
readonly alias?: string;
|
|
188
190
|
readonly userNamed?: boolean;
|
|
189
191
|
readonly location?: string | null;
|
|
190
192
|
readonly disabled?: boolean;
|
|
@@ -343,6 +345,12 @@ export declare class DeviceRowStore {
|
|
|
343
345
|
* so rather than picking arbitrarily.
|
|
344
346
|
*/
|
|
345
347
|
findByStableId(addonId: string, stableId: string): Promise<DeviceRow | null>;
|
|
348
|
+
/**
|
|
349
|
+
* The device that owns a template alias, or `null`. Aliases are unique, so a
|
|
350
|
+
* second row for one alias would be a corruption: the LOWEST id is answered and
|
|
351
|
+
* the duplicate is said on the record.
|
|
352
|
+
*/
|
|
353
|
+
findByAlias(alias: string): Promise<DeviceRow | null>;
|
|
346
354
|
/** Every device owned by one addon, ordered by numeric id. */
|
|
347
355
|
listByAddon(addonId: string): Promise<readonly DeviceRow[]>;
|
|
348
356
|
/** Every device an integration owns, ordered by numeric id. */
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The renderer's resolver over the state mirror the automation engine already
|
|
3
|
+
* keeps (`ConditionMirror`): current slices, no read per render. The hub
|
|
4
|
+
* adapter lists the devices (alias, caps) from the device rows and hands the
|
|
5
|
+
* mirror the sources `templateMirrorSources` names.
|
|
6
|
+
*/
|
|
7
|
+
import type { ConditionMirror, DeviceTemplateView, MirrorSource } from "@camstack/types";
|
|
8
|
+
import type { DeviceTemplateResolver } from "./template-renderer.js";
|
|
9
|
+
/** One device a template may name. */
|
|
10
|
+
export interface TemplateDeviceEntry {
|
|
11
|
+
readonly deviceId: number;
|
|
12
|
+
readonly addonId: string;
|
|
13
|
+
readonly stableId: string;
|
|
14
|
+
readonly alias: string;
|
|
15
|
+
readonly caps: readonly string[];
|
|
16
|
+
}
|
|
17
|
+
/** The slices the mirror must hold so these devices' templates can render. */
|
|
18
|
+
export declare function templateMirrorSources(devices: readonly TemplateDeviceEntry[]): readonly MirrorSource[];
|
|
19
|
+
export declare function mirrorTemplateResolver(mirror: Pick<ConditionMirror, "sliceOf">, devices: readonly TemplateDeviceEntry[], unitOf?: DeviceTemplateView["unitOf"]): DeviceTemplateResolver;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
/** One node of the parsed template, as the grammar walker sees it. */
|
|
2
|
+
export interface TemplateNode {
|
|
3
|
+
readonly typename: string;
|
|
4
|
+
readonly lineno: number;
|
|
5
|
+
readonly colno: number;
|
|
6
|
+
/** The node's child nodes (field order), flattened; non-node fields excluded. */
|
|
7
|
+
readonly children: readonly TemplateNode[];
|
|
8
|
+
/** The node's own literal payload (`Symbol.value`, `Literal.value`, `Filter.name` is a child). */
|
|
9
|
+
readonly value: unknown;
|
|
10
|
+
/** A named child node (`target`, `val`, `name`, `args`, `cond` …), when present and a node. */
|
|
11
|
+
readonly field: (name: string) => TemplateNode | undefined;
|
|
12
|
+
/** Every child node of a named field (`Set.targets` holds several). */
|
|
13
|
+
readonly all: (name: string) => readonly TemplateNode[];
|
|
14
|
+
/** The node's declared fields (`fields` on the node class), in order. */
|
|
15
|
+
readonly fieldNames: readonly string[];
|
|
16
|
+
/**
|
|
17
|
+
* Own properties that hold nodes but are NOT declared fields (`Set.body`).
|
|
18
|
+
* The compiler visits them; a walker that follows `fieldNames` would not.
|
|
19
|
+
*/
|
|
20
|
+
readonly unlisted: readonly string[];
|
|
21
|
+
}
|
|
22
|
+
/** The declared fields of every nunjucks node class, by type name — what the grammar's field policy is checked against. */
|
|
23
|
+
export declare function nunjucksNodeFields(): ReadonlyMap<string, readonly string[]>;
|
|
24
|
+
export type ParseOutcome = {
|
|
25
|
+
readonly ok: true;
|
|
26
|
+
readonly root: TemplateNode;
|
|
27
|
+
} | {
|
|
28
|
+
readonly ok: false;
|
|
29
|
+
readonly message: string;
|
|
30
|
+
};
|
|
31
|
+
/** Parse a template into an AST without compiling or loading anything. */
|
|
32
|
+
export declare function parseTemplateSource(source: string): ParseOutcome;
|
|
33
|
+
export interface TemplateEnvironmentOptions {
|
|
34
|
+
/** Prints a value the way `{{ … }}` does (replaces nunjucks' `suppressValue`). */
|
|
35
|
+
readonly print: (value: unknown) => string;
|
|
36
|
+
/** nunjucks' own filters to keep (the pure string/number ones); every other built-in is removed. */
|
|
37
|
+
readonly keepBuiltinFilters: readonly string[];
|
|
38
|
+
/** Globals a template may read or call (`range`); `range`/`cycler`/`joiner` are otherwise neutralised. */
|
|
39
|
+
readonly globals: Readonly<Record<string, unknown>>;
|
|
40
|
+
/** `a + b` and `a ~ b` compile to calls of these (installed on the runtime) so an unavailable operand is decided in one place. */
|
|
41
|
+
readonly add: (left: unknown, right: unknown) => unknown;
|
|
42
|
+
readonly concat: (left: unknown, right: unknown) => unknown;
|
|
43
|
+
readonly filters: Readonly<Record<string, (this: unknown, ...args: never[]) => unknown>>;
|
|
44
|
+
}
|
|
45
|
+
export interface TemplateEnvironment {
|
|
46
|
+
render(source: string, context: object): string;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* A fresh environment: no loader (so include/import/extends cannot resolve),
|
|
50
|
+
* autoescape off, `range`/`cycler`/`joiner` neutralised, only the filters
|
|
51
|
+
* handed in. Printing goes through `print` so an unknown value reads `—`.
|
|
52
|
+
*/
|
|
53
|
+
export declare function createTemplateEnvironment(options: TemplateEnvironmentOptions): TemplateEnvironment;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/** A number with a unit symbol: what `unit()` returns and `round`/`format`/`default` accept. */
|
|
2
|
+
export declare class Quantity {
|
|
3
|
+
readonly value: number;
|
|
4
|
+
readonly symbol: string;
|
|
5
|
+
constructor(value: number, symbol: string);
|
|
6
|
+
}
|
|
7
|
+
export declare const UNAVAILABLE_VALUE: object;
|
|
8
|
+
export declare function addChecked(left: unknown, right: unknown): unknown;
|
|
9
|
+
export declare function concatChecked(left: unknown, right: unknown): unknown;
|
|
10
|
+
/** `range(n)`, `range(a, b)`, `range(a, b, step)` — integers only, never more than `RANGE_MAX` items. */
|
|
11
|
+
export declare const RANGE_MAX = 1e3;
|
|
12
|
+
export declare function rangeGlobal(...args: readonly unknown[]): readonly number[];
|
|
13
|
+
export declare function unitFilter(input: unknown, from: unknown, to: unknown): unknown;
|
|
14
|
+
export declare function roundFilter(input: unknown, digits: unknown): unknown;
|
|
15
|
+
export declare function defaultFilter(input: unknown, fallback: unknown): unknown;
|
|
16
|
+
/** `since`: how long ago a timestamp was, as `5 min`. `nowMs` comes with the request, never from a clock in the worker. */
|
|
17
|
+
export declare function makeSinceFilter(nowMs: number): (input: unknown) => unknown;
|
|
18
|
+
/** `ago`: `5 min ago`. */
|
|
19
|
+
export declare function makeAgoFilter(nowMs: number): (input: unknown) => unknown;
|
|
20
|
+
/** `format('%.1f')`, `format('%d items')`, `format('%s')`: one value, one placeholder. */
|
|
21
|
+
export declare function formatFilter(input: unknown, pattern: unknown): unknown;
|
|
22
|
+
/** What `{{ … }}` prints. Unknown values read as `unavailable`; objects never print their shape. */
|
|
23
|
+
export interface Printer {
|
|
24
|
+
readonly print: (value: unknown) => string;
|
|
25
|
+
/** How many outputs printed as unavailable because an operand of `+` / `~` was. */
|
|
26
|
+
readonly poisoned: () => number;
|
|
27
|
+
}
|
|
28
|
+
export declare function makePrinter(unavailable: string): Printer;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What a device value template may contain, decided from the parsed tree.
|
|
3
|
+
*
|
|
4
|
+
* nunjucks does not sandbox: `{{ range.constructor("return process")() }}`
|
|
5
|
+
* runs. So the template is refused unless EVERY node is on a whitelist — no
|
|
6
|
+
* calls, no include/import/extends, no macros, no dynamic member lookups, no
|
|
7
|
+
* `constructor`-style member names, no filter outside the allow-list. The
|
|
8
|
+
* worker re-runs this over what it receives (defence in depth).
|
|
9
|
+
*
|
|
10
|
+
* Type-only imports from `@camstack/types`: this module is loaded by the
|
|
11
|
+
* render worker, which must not load the types barrel (D453).
|
|
12
|
+
*/
|
|
13
|
+
import type { DeviceTemplateRef, DeviceTemplateRefusal } from "@camstack/types";
|
|
14
|
+
/**
|
|
15
|
+
* Per node kind: the declared fields the walker FOLLOWS (`walk`) and the ones
|
|
16
|
+
* that carry plain data (`data`) or are checked by the kind's own rule
|
|
17
|
+
* (`special`). A kind not listed here is refused; a node carrying a field this
|
|
18
|
+
* table does not name is refused (a child the walker never visits is a child
|
|
19
|
+
* that executes unvetted). `template-grammar.spec.ts` compares this table with
|
|
20
|
+
* nunjucks' own node classes, so a field added upstream fails the spec.
|
|
21
|
+
*/
|
|
22
|
+
export interface NodePolicy {
|
|
23
|
+
readonly walk: readonly string[];
|
|
24
|
+
readonly data: readonly string[];
|
|
25
|
+
readonly special: readonly string[];
|
|
26
|
+
}
|
|
27
|
+
export declare const NODE_POLICY: Readonly<Record<string, NodePolicy>>;
|
|
28
|
+
/** A `unit(…)` call: where its name token sits and the reference it converts, when it is a direct one. */
|
|
29
|
+
export interface UnitSite {
|
|
30
|
+
readonly lineno: number;
|
|
31
|
+
readonly colno: number;
|
|
32
|
+
readonly ref: DeviceTemplateRef | undefined;
|
|
33
|
+
}
|
|
34
|
+
export type TemplateAnalysis = {
|
|
35
|
+
readonly ok: true;
|
|
36
|
+
readonly refs: readonly DeviceTemplateRef[];
|
|
37
|
+
readonly unitSites: readonly UnitSite[];
|
|
38
|
+
} | {
|
|
39
|
+
readonly ok: false;
|
|
40
|
+
readonly refusal: DeviceTemplateRefusal;
|
|
41
|
+
};
|
|
42
|
+
/** Parse and vet a template. A template that passes may be handed to the worker. */
|
|
43
|
+
export declare function analyzeTemplate(source: string, allowedFilters: readonly string[], maxLength: number): TemplateAnalysis;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Messages between the renderer and its worker thread. Pure types and guards:
|
|
3
|
+
* the worker loads this file, so it imports nothing from the types barrel.
|
|
4
|
+
*/
|
|
5
|
+
import type { DeviceTemplateRefusalReason } from "@camstack/types";
|
|
6
|
+
/** Fixed at spawn: the worker cannot read the types barrel, so the limits travel with it. */
|
|
7
|
+
export interface TemplateWorkerData {
|
|
8
|
+
readonly allowedFilters: readonly string[];
|
|
9
|
+
readonly maxSourceLength: number;
|
|
10
|
+
readonly maxOutput: number;
|
|
11
|
+
readonly unavailable: string;
|
|
12
|
+
}
|
|
13
|
+
export interface RenderRequest {
|
|
14
|
+
readonly id: number;
|
|
15
|
+
readonly source: string;
|
|
16
|
+
/** Plain JSON-like data, keyed by alias; the worker freezes it into null-prototype objects. */
|
|
17
|
+
readonly context: Readonly<Record<string, unknown>>;
|
|
18
|
+
readonly nowMs: number;
|
|
19
|
+
}
|
|
20
|
+
export type RenderResponse = {
|
|
21
|
+
readonly id: number;
|
|
22
|
+
readonly ok: true;
|
|
23
|
+
readonly text: string;
|
|
24
|
+
/** Outputs that printed as unavailable because an operand of `+` / `~` was. */
|
|
25
|
+
readonly poisoned: number;
|
|
26
|
+
} | {
|
|
27
|
+
readonly id: number;
|
|
28
|
+
readonly ok: false;
|
|
29
|
+
readonly reason: DeviceTemplateRefusalReason;
|
|
30
|
+
readonly message: string;
|
|
31
|
+
};
|
|
32
|
+
export declare function isRenderResponse(value: unknown): value is RenderResponse;
|
|
33
|
+
export declare function isRenderRequest(value: unknown): value is RenderRequest;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { type DeviceTemplateRender, type DeviceTemplateView } from "@camstack/types";
|
|
2
|
+
import { type TemplateAnalysis } from "./template-grammar.js";
|
|
3
|
+
/** How the renderer finds a device by alias. The hub adapter answers it from the device rows and the state mirror. */
|
|
4
|
+
export interface DeviceTemplateResolver {
|
|
5
|
+
viewOf(alias: string): DeviceTemplateView | undefined;
|
|
6
|
+
}
|
|
7
|
+
/** `dist/device-template-worker.js` at the package root, found through its own `package.json`. */
|
|
8
|
+
export declare function defaultTemplateWorkerPath(): string;
|
|
9
|
+
export interface DeviceTemplateRendererOptions {
|
|
10
|
+
readonly workerPath?: string;
|
|
11
|
+
/** Specs run the TypeScript source: `['--import', 'tsx']`. */
|
|
12
|
+
readonly workerExecArgv?: readonly string[];
|
|
13
|
+
readonly budgetMs?: number;
|
|
14
|
+
readonly now?: () => number;
|
|
15
|
+
/** How long a fresh worker may take to announce `ready` (default 10 s). */
|
|
16
|
+
readonly spawnTimeoutMs?: number;
|
|
17
|
+
/** Renders allowed to wait behind the running one before `busy` (default 16). */
|
|
18
|
+
readonly maxQueue?: number;
|
|
19
|
+
/** Consecutive timeouts of one template before it is refused without running (default 3). */
|
|
20
|
+
readonly breakerThreshold?: number;
|
|
21
|
+
/** How long a tripped template stays refused (default 60 s). */
|
|
22
|
+
readonly breakerWindowMs?: number;
|
|
23
|
+
}
|
|
24
|
+
export declare class DeviceTemplateRenderer {
|
|
25
|
+
private readonly workerPath;
|
|
26
|
+
private readonly execArgv;
|
|
27
|
+
private readonly budgetMs;
|
|
28
|
+
private readonly now;
|
|
29
|
+
private worker;
|
|
30
|
+
private ready;
|
|
31
|
+
private nextId;
|
|
32
|
+
private readonly pending;
|
|
33
|
+
private queue;
|
|
34
|
+
private waiting;
|
|
35
|
+
private readonly spawnTimeoutMs;
|
|
36
|
+
private readonly maxQueue;
|
|
37
|
+
private readonly breakerThreshold;
|
|
38
|
+
private readonly breakerWindowMs;
|
|
39
|
+
private readonly breakers;
|
|
40
|
+
constructor(options?: DeviceTemplateRendererOptions);
|
|
41
|
+
/** Vet a template without rendering it: its references, or the refusal. */
|
|
42
|
+
validate(source: string): TemplateAnalysis;
|
|
43
|
+
render(source: string, resolver: DeviceTemplateResolver): Promise<DeviceTemplateRender>;
|
|
44
|
+
private noteOutcome;
|
|
45
|
+
dispose(): void;
|
|
46
|
+
private prepare;
|
|
47
|
+
private enqueue;
|
|
48
|
+
private renderOne;
|
|
49
|
+
private ensureWorker;
|
|
50
|
+
/** Fail only the renders that were running on THIS worker: a killed worker's late `exit` must not fail the next one. */
|
|
51
|
+
private failPending;
|
|
52
|
+
private dropWorker;
|
|
53
|
+
private killWorker;
|
|
54
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -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-2SHQaxaS.js");
|
|
7
7
|
const require_formatter = require("../../formatter-xbxeV4GD.js");
|
|
8
8
|
//#region src/builtins/hub-forwarder/hub-forwarder-destination.ts
|
|
9
9
|
var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Ko as BaseAddon, hi as logDestinationCapability } from "../../dist-CogtCQxu.mjs";
|
|
2
2
|
import { t as formatLogLine } from "../../formatter-DkYZ4LXp.mjs";
|
|
3
3
|
//#region src/builtins/hub-forwarder/hub-forwarder-destination.ts
|
|
4
4
|
var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
|
|
@@ -3,11 +3,11 @@ 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-
|
|
7
|
-
const require_device_ca = require("../../device-ca-
|
|
6
|
+
const require_dist = require("../../dist-2SHQaxaS.js");
|
|
7
|
+
const require_device_ca = require("../../device-ca-Uq5KGFSq.js");
|
|
8
8
|
const require_read_all_rows$1 = require("../../read-all-rows-CVoO1ONM.js");
|
|
9
|
-
const require_legacy_integration_rows_door = require("../../legacy-integration-rows-door-
|
|
10
|
-
const require_constants = require("../../constants-
|
|
9
|
+
const require_legacy_integration_rows_door = require("../../legacy-integration-rows-door-Bz8rivxI.js");
|
|
10
|
+
const require_constants = require("../../constants--xo6Q-KA.js");
|
|
11
11
|
const require_platform_key_source = require("../../platform-key-source-Di7HrlGR.js");
|
|
12
12
|
let node_crypto = require("node:crypto");
|
|
13
13
|
let _camstack_types_node = require("@camstack/types/node");
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { d as JWT_SIGNING_KEY_REF, n as DEVICE_CA_KEY_REF, p as SYSTEM_SECRET_OWNER } from "../../device-ca-
|
|
1
|
+
import { Hs as defineRecordKinds, Ic as EventCategory, Ko as BaseAddon, Ks as formatSecretScope, _t as KEYCHAIN_RESET_TRIGGER_ACTOR, ai as keychainAdminCapability, gc as parseSecretRef, oi as keychainCapability, pc as normalizeSecretOwner, vt as KeychainAuditEntrySchema, yt as KeychainResetRecordSchema } from "../../dist-CogtCQxu.mjs";
|
|
2
|
+
import { d as JWT_SIGNING_KEY_REF, n as DEVICE_CA_KEY_REF, p as SYSTEM_SECRET_OWNER } from "../../device-ca-Do0-HV_h.mjs";
|
|
3
3
|
import { t as require_read_all_rows } from "../../read-all-rows-TaPqdWNF.mjs";
|
|
4
|
-
import { t as LEGACY_INTEGRATION_ROWS_TABLE } from "../../legacy-integration-rows-door-
|
|
5
|
-
import { a as MESH_CA_KEY_REF } from "../../constants-
|
|
4
|
+
import { t as LEGACY_INTEGRATION_ROWS_TABLE } from "../../legacy-integration-rows-door-CiuxDLoc.mjs";
|
|
5
|
+
import { a as MESH_CA_KEY_REF } from "../../constants-Bf1PEHRU.mjs";
|
|
6
6
|
import { n as getPlatformKeychainKey } from "../../platform-key-source-BWlq0jjn.mjs";
|
|
7
7
|
import { createCipheriv, createDecipheriv, createHmac, randomBytes, randomUUID, timingSafeEqual } from "node:crypto";
|
|
8
8
|
import { restrictDirToOwnerSync, restrictFileToOwnerSync, writeOwnerOnlyFileSync } from "@camstack/types/node";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
3
|
-
const require_dist = require("../../dist-
|
|
3
|
+
const require_dist = require("../../dist-2SHQaxaS.js");
|
|
4
4
|
let node_fs = require("node:fs");
|
|
5
5
|
let node_path = require("node:path");
|
|
6
6
|
node_path = require_chunk.__toESM(node_path);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Bt as RECORDING_SOURCE_CAMSTACK_ADDON,
|
|
1
|
+
import { Bt as RECORDING_SOURCE_CAMSTACK_ADDON, Ic as EventCategory, Ko as BaseAddon, Ls as createEvent, Pc as errMsg, Ut as RecordingStatusSchema, yi as mayWriteToLocation } from "../../dist-CogtCQxu.mjs";
|
|
2
2
|
import { constants } from "node:fs";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
import * as fsp from "node:fs/promises";
|
|
@@ -3,10 +3,10 @@ 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-2SHQaxaS.js");
|
|
7
7
|
const require_safe_buffer$1 = require("../../safe-buffer-D3aoa-7X.js");
|
|
8
8
|
const require_ms$1 = require("../../ms-LB3giGoU.js");
|
|
9
|
-
const require_device_ca = require("../../device-ca-
|
|
9
|
+
const require_device_ca = require("../../device-ca-Uq5KGFSq.js");
|
|
10
10
|
const require_read_all_rows$1 = require("../../read-all-rows-CVoO1ONM.js");
|
|
11
11
|
let zod = require("zod");
|
|
12
12
|
let node_crypto = require("node:crypto");
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { i as __require, o as __toESM, t as __commonJSMin } from "../../chunk-CNf5ZN-e.mjs";
|
|
2
|
-
import { An as buildDeviceEnrollmentLink, B as DEVICE_ENROLLMENT_TTL_MS, Cn as authProviderCapability,
|
|
2
|
+
import { $a as userManagementCapability, An as buildDeviceEnrollmentLink, B as DEVICE_ENROLLMENT_TTL_MS, Cn as authProviderCapability, Hs as defineRecordKinds, It as PreferenceDeviceIdSchema, Ko as BaseAddon, Lr as formatDeviceRevoker, Lt as PreferenceNamespaceSchema, M as CredentialTokenClaimsSchema, Qt as ScopedTokenSchema, Rt as PreferenceValueSchema, T as CREDENTIAL_TOKEN_AUDIENCE, U as DEVICE_NONCE_TTL_MS, Zr as isCredentialTokenPayload, ac as isSecretMarker, cc as makeSecretMarker, en as SsoBridgeClaimsSchema, jn as buildDeviceSignatureMessage, jt as PREFERENCES_MAX_VALUE_BYTES, kc as userError, ln as UserRecordSchema, mr as deviceCredentialsCapability, sn as TokenScopeSchema } from "../../dist-CogtCQxu.mjs";
|
|
3
3
|
import { t as require_safe_buffer } from "../../safe-buffer-B1OjL1I9.mjs";
|
|
4
4
|
import { t as require_ms } from "../../ms-CgH2OFlD.mjs";
|
|
5
|
-
import { _ as setProcessJwtSigningKey, a as importDevicePublicKey, c as rebuildDeviceCaCertificate, d as JWT_SIGNING_KEY_REF, g as processJwtSigningKey, h as loadJwtSigningKey, i as generateDeviceCa, l as verifyDeviceLeaf, m as getProcessJwtSigningKeyState, n as DEVICE_CA_KEY_REF, o as issueDeviceLeaf, r as DEVICE_CA_SETTINGS_SECTION, s as loadDeviceCa, t as DEVICE_CA_FIELD, u as verifyDeviceSignature } from "../../device-ca-
|
|
5
|
+
import { _ as setProcessJwtSigningKey, a as importDevicePublicKey, c as rebuildDeviceCaCertificate, d as JWT_SIGNING_KEY_REF, g as processJwtSigningKey, h as loadJwtSigningKey, i as generateDeviceCa, l as verifyDeviceLeaf, m as getProcessJwtSigningKeyState, n as DEVICE_CA_KEY_REF, o as issueDeviceLeaf, r as DEVICE_CA_SETTINGS_SECTION, s as loadDeviceCa, t as DEVICE_CA_FIELD, u as verifyDeviceSignature } from "../../device-ca-Do0-HV_h.mjs";
|
|
6
6
|
import { t as require_read_all_rows } from "../../read-all-rows-TaPqdWNF.mjs";
|
|
7
7
|
import { z } from "zod";
|
|
8
8
|
import * as crypto$1 from "node:crypto";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
3
|
-
const require_dist = require("../../dist-
|
|
3
|
+
const require_dist = require("../../dist-2SHQaxaS.js");
|
|
4
4
|
const require_dns_wire = require("../../dns-wire-B1BvF9Ao.js");
|
|
5
|
-
const require_hub_mdns_ciao = require("../../hub-mdns-ciao-
|
|
5
|
+
const require_hub_mdns_ciao = require("../../hub-mdns-ciao-DqPrLiYH.js");
|
|
6
6
|
let zod = require("zod");
|
|
7
7
|
let node_net = require("node:net");
|
|
8
8
|
let node_fs = require("node:fs");
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Aa as shortHostname, Ic as EventCategory, Jr as isAppLinkBase, Ko as BaseAddon, Pc as errMsg, Qr as isDefaultAppConnectionEndpoint, Wi as pickAppLinkHub, Yi as preconditionOf, ca as resolveAppConnections, di as localNetworkCapability, fa as resolveHubAddressRoles, ft as HUB_MDNS_SERVICE_TYPE, ga as resolveNotificationTapAddress, kt as NetworkTunnelStartedDataSchema, pt as HUB_MDNS_TXT_KEYS, to as validateCustomAddress, v as CAMSTACK_APP_LINK_ORIGIN, zn as checkRoleAddress, zs as defineAddonMigrations } from "../../dist-CogtCQxu.mjs";
|
|
2
2
|
import { a as emptyMdnsRecords, c as parseMdnsMessage, i as buildRecordQuery, l as parseMdnsRecords, n as MDNS_PORT, o as mergeMdnsRecords, r as buildPtrQuery, s as normalizeServiceType, t as MDNS_GROUP } from "../../dns-wire-Dm3H_7ST.mjs";
|
|
3
|
-
import { E as ensureTlsCert, I as readLanHttpState, N as applyLanHttp, _ as readTlsMode, a as storeUploadedCertificate, b as writeTlsEnabled, d as servedHttpsLeafFingerprint, h as readTlsAccessStatus, i as revertToGeneratedCertificate, j as DEFAULT_LAN_HTTP_PORT, m as readExtraSans, n as applyCertificateToListener, o as useStoredUploadedCertificate, r as regenerateCertificate, t as createCiaoPublisher, y as writeExtraSans } from "../../hub-mdns-ciao-
|
|
3
|
+
import { E as ensureTlsCert, I as readLanHttpState, N as applyLanHttp, _ as readTlsMode, a as storeUploadedCertificate, b as writeTlsEnabled, d as servedHttpsLeafFingerprint, h as readTlsAccessStatus, i as revertToGeneratedCertificate, j as DEFAULT_LAN_HTTP_PORT, m as readExtraSans, n as applyCertificateToListener, o as useStoredUploadedCertificate, r as regenerateCertificate, t as createCiaoPublisher, y as writeExtraSans } from "../../hub-mdns-ciao-aFHCKrif.mjs";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
import { isIP } from "node:net";
|
|
6
6
|
import { readFileSync } from "node:fs";
|
|
@@ -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-2SHQaxaS.js");
|
|
7
7
|
const require_log_read_filter = require("../../log-read-filter-Bi066jwU.js");
|
|
8
8
|
let zod = require("zod");
|
|
9
9
|
//#region src/builtins/loki-logging/loki-payload.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Ko as BaseAddon, Tn as bareAddonId, Ur as integrationInstancesCapability, Vs as defineEntryKind, Yi as preconditionOf, ac as isSecretMarker, bs as RevConflictError, ec as isInstanceEnabled, hi as logDestinationCapability, hs as RecordIntegrationInstances, ic as isSecretFieldView, ni as isSameAddonId, zs as defineAddonMigrations } from "../../dist-CogtCQxu.mjs";
|
|
2
2
|
import { n as compileLogFilter, o as lineMatches } from "../../log-read-filter-D7Ev3zm-.mjs";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
//#region src/builtins/loki-logging/loki-payload.ts
|
|
@@ -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-2SHQaxaS.js");
|
|
7
7
|
let node_fs = require("node:fs");
|
|
8
8
|
node_fs = require_chunk.__toESM(node_fs);
|
|
9
9
|
let node_fs_promises = require("node:fs/promises");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Ht as ROOT_BUCKET_KEY, Ic as EventCategory, Ir as foldSnapshotByFunction, Ko as BaseAddon, Ls as createEvent, Pc as errMsg, cn as UNATTRIBUTED_BUCKET_KEY, la as resolveBucketMs, ra as reducePoints, wi as metricsProviderCapability } from "../../dist-CogtCQxu.mjs";
|
|
2
2
|
import * as fs$1 from "node:fs";
|
|
3
3
|
import { constants, readFileSync } from "node:fs";
|
|
4
4
|
import { access, readFile, readdir } from "node:fs/promises";
|
|
@@ -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-2SHQaxaS.js");
|
|
7
7
|
const require_coral_accelerators = require("../../coral-accelerators-BSVsBVzt.js");
|
|
8
8
|
let node_fs = require("node:fs");
|
|
9
9
|
node_fs = require_chunk.__toESM(node_fs);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { o as __toESM, r as __exportAll } from "../../chunk-CNf5ZN-e.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { Ic as EventCategory, Ki as platformProbeCapability, Ko as BaseAddon, Pc as errMsg, Sr as enumerateInferenceDevices, Ta as scoreRuntimes, Ws as emitReadiness, zi as parseAcceleratorFactsJson } from "../../dist-CogtCQxu.mjs";
|
|
3
3
|
import { n as detectCoralAccelerator, r as nodeCoralFs } from "../../coral-accelerators-DBlgWB8k.mjs";
|
|
4
4
|
import * as fs$1 from "node:fs";
|
|
5
5
|
import * as path$1 from "node:path";
|
|
@@ -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-2SHQaxaS.js");
|
|
7
7
|
let zod = require("zod");
|
|
8
8
|
let node_crypto = require("node:crypto");
|
|
9
9
|
//#region src/builtins/record-entries/entries-service.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Ko as BaseAddon, Ts as UnknownRecordKindError, ns as InvalidRecordError, ta as recordEntriesCapability, wc as secretViewsOf } from "../../dist-CogtCQxu.mjs";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
import { randomUUID } from "node:crypto";
|
|
4
4
|
//#region src/builtins/record-entries/entries-service.ts
|
|
@@ -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-2SHQaxaS.js");
|
|
7
7
|
let zod = require("zod");
|
|
8
8
|
//#region src/builtins/remote-access-orchestrator/enabled-providers-reconcile.ts
|
|
9
9
|
/**
|
package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Ic as EventCategory, Ko as BaseAddon } from "../../dist-CogtCQxu.mjs";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
//#region src/builtins/remote-access-orchestrator/enabled-providers-reconcile.ts
|
|
4
4
|
/**
|
|
@@ -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-2SHQaxaS.js");
|
|
7
7
|
const require_snapshot_courtesy = require("../../snapshot-courtesy-D_C5-nC0.js");
|
|
8
8
|
let zod = require("zod");
|
|
9
9
|
let node_crypto = require("node:crypto");
|
|
@@ -1695,7 +1695,7 @@ var SnapshotAddon = class SnapshotAddon extends require_dist.BaseAddon {
|
|
|
1695
1695
|
/**
|
|
1696
1696
|
* Drop the cached ingest owner whenever addon-level settings change —
|
|
1697
1697
|
* cheap, correct-by-construction refresh point (BaseAddon calls this
|
|
1698
|
-
* after every `
|
|
1698
|
+
* after every `updateScopedSettings`/`updateAddonSettings`). Combined
|
|
1699
1699
|
* with the TTL in `resolveIngestOwner`, a cluster topology change is
|
|
1700
1700
|
* picked up either on the next settings save or within
|
|
1701
1701
|
* `OWNER_CACHE_TTL_MS`, whichever comes first.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { En as batteryCapability, Ha as streamQualityLabel, Ic as EventCategory, Ko as BaseAddon, Na as snapshotCapability, Nc as DeviceType, Pc as errMsg, Si as memoizePinnedFfmpeg, Tn as bareAddonId, dc as nodePin, dr as deriveBatteryPresence, g as BatteryStatusSchema, jc as DeviceFeature } from "../../dist-CogtCQxu.mjs";
|
|
2
2
|
import { i as renderCourtesyOverlayJpeg, n as courtesyCacheKey, r as renderCourtesyJpeg } from "../../snapshot-courtesy-CyFs1M3I.mjs";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
import { randomUUID } from "node:crypto";
|
|
@@ -1689,7 +1689,7 @@ var SnapshotAddon = class SnapshotAddon extends BaseAddon {
|
|
|
1689
1689
|
/**
|
|
1690
1690
|
* Drop the cached ingest owner whenever addon-level settings change —
|
|
1691
1691
|
* cheap, correct-by-construction refresh point (BaseAddon calls this
|
|
1692
|
-
* after every `
|
|
1692
|
+
* after every `updateScopedSettings`/`updateAddonSettings`). Combined
|
|
1693
1693
|
* with the TTL in `resolveIngestOwner`, a cluster topology change is
|
|
1694
1694
|
* picked up either on the next settings save or within
|
|
1695
1695
|
* `OWNER_CACHE_TTL_MS`, whichever comes first.
|
|
@@ -303,7 +303,7 @@ export declare class SnapshotAddon extends BaseAddon<SnapshotAddonConfig> {
|
|
|
303
303
|
/**
|
|
304
304
|
* Drop the cached ingest owner whenever addon-level settings change —
|
|
305
305
|
* cheap, correct-by-construction refresh point (BaseAddon calls this
|
|
306
|
-
* after every `
|
|
306
|
+
* after every `updateScopedSettings`/`updateAddonSettings`). Combined
|
|
307
307
|
* with the TTL in `resolveIngestOwner`, a cluster topology change is
|
|
308
308
|
* picked up either on the next settings save or within
|
|
309
309
|
* `OWNER_CACHE_TTL_MS`, whichever comes first.
|
|
@@ -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-2SHQaxaS.js");
|
|
7
7
|
let node_crypto = require("node:crypto");
|
|
8
8
|
let node_fs = require("node:fs");
|
|
9
9
|
node_fs = require_chunk.__toESM(node_fs);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Ba as storageProviderCapability, Fr as filesystemBrowseCapability, Ko as BaseAddon } from "../../dist-CogtCQxu.mjs";
|
|
2
2
|
import { randomUUID } from "node:crypto";
|
|
3
3
|
import * as fs$1 from "node:fs";
|
|
4
4
|
import * as path$1 from "node:path";
|
|
@@ -4,7 +4,7 @@ Object.defineProperties(exports, {
|
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
6
|
const require_builtins_sqlite_storage_filesystem_storage_addon = require("./filesystem-storage.addon.js");
|
|
7
|
-
const require_wal_maintenance = require("../../wal-maintenance-
|
|
7
|
+
const require_wal_maintenance = require("../../wal-maintenance-BTR55y--.js");
|
|
8
8
|
const require_builtins_sqlite_storage_sqlite_settings_addon = require("./sqlite-settings.addon.js");
|
|
9
9
|
//#region src/builtins/sqlite-storage/config-store.ts
|
|
10
10
|
var ConfigStore = class {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { FilesystemStorageAddon, t as FilesystemStorageProvider } from "./filesystem-storage.addon.mjs";
|
|
2
|
-
import { B as SQLITE_ENGINE_STORM_WALL_SHARE, F as SQLITE_MMAP_FLOOR_BYTES, G as SqliteOpProfiler, H as SQLITE_PROFILE_REPORT_INTERVAL_MS, I as SQLITE_PAGE_CACHE_CEILING_KIB, K as sqliteEngineStorm, L as SQLITE_PAGE_CACHE_FLOOR_KIB, N as SQLITE_JOURNAL_SIZE_LIMIT_BYTES, P as SQLITE_MMAP_CEILING_BYTES, R as sqliteMmapSizeFor, U as SQLITE_PROFILE_TOP_N, V as SQLITE_PROFILE_REPORT_FLOOR_MS, W as SQLITE_SLOW_CALL_MS, a as WalMaintenance, i as WAL_MAINTENANCE_INTERVAL_MS, l as SqliteSettingsBackend, n as WAL_HIGH_WATER_BYTES, r as WAL_IDLE_QUIET_MS, t as WAL_CHECKPOINT_BUSY_TIMEOUT_MS, z as sqlitePageCacheKibFor } from "../../wal-maintenance-
|
|
2
|
+
import { B as SQLITE_ENGINE_STORM_WALL_SHARE, F as SQLITE_MMAP_FLOOR_BYTES, G as SqliteOpProfiler, H as SQLITE_PROFILE_REPORT_INTERVAL_MS, I as SQLITE_PAGE_CACHE_CEILING_KIB, K as sqliteEngineStorm, L as SQLITE_PAGE_CACHE_FLOOR_KIB, N as SQLITE_JOURNAL_SIZE_LIMIT_BYTES, P as SQLITE_MMAP_CEILING_BYTES, R as sqliteMmapSizeFor, U as SQLITE_PROFILE_TOP_N, V as SQLITE_PROFILE_REPORT_FLOOR_MS, W as SQLITE_SLOW_CALL_MS, a as WalMaintenance, i as WAL_MAINTENANCE_INTERVAL_MS, l as SqliteSettingsBackend, n as WAL_HIGH_WATER_BYTES, r as WAL_IDLE_QUIET_MS, t as WAL_CHECKPOINT_BUSY_TIMEOUT_MS, z as sqlitePageCacheKibFor } from "../../wal-maintenance-jrhYTCn2.mjs";
|
|
3
3
|
import { SqliteSettingsAddon } from "./sqlite-settings.addon.mjs";
|
|
4
4
|
//#region src/builtins/sqlite-storage/config-store.ts
|
|
5
5
|
var ConfigStore = class {
|
|
@@ -3,12 +3,12 @@ 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-2SHQaxaS.js");
|
|
7
7
|
const require_retired_settings_keys = require("../../retired-settings-keys-C8nOOr5H.js");
|
|
8
|
-
const require_wal_maintenance = require("../../wal-maintenance-
|
|
8
|
+
const require_wal_maintenance = require("../../wal-maintenance-BTR55y--.js");
|
|
9
9
|
const require_sqlite_snapshot_protocol = require("../../sqlite-snapshot-protocol-B9OndqZv.js");
|
|
10
10
|
const require_wal_checkpoint_policy = require("../../wal-checkpoint-policy-d2z2qPqx.js");
|
|
11
|
-
const require_legacy_integration_rows_door = require("../../legacy-integration-rows-door-
|
|
11
|
+
const require_legacy_integration_rows_door = require("../../legacy-integration-rows-door-Bz8rivxI.js");
|
|
12
12
|
let zod = require("zod");
|
|
13
13
|
let node_crypto = require("node:crypto");
|
|
14
14
|
let node_fs = require("node:fs");
|