@camstack/server 1.2.790 → 1.2.792
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/api/trpc/device-config-secret-redaction.js +14 -1
- package/dist/api/trpc/generated-cap-routers.js +24 -0
- package/dist/api/trpc/localized-schema-paths.js +1 -0
- package/dist/core/addon/addon-settings-provider.js +57 -0
- package/package.json +18 -24
- package/system/dist/addon-runner.js +22 -0
- package/system/dist/addon-runner.mjs +22 -0
- package/system/dist/{agent-https-ByceQLwr.mjs → agent-https-BmVaVskH.mjs} +1 -1
- package/system/dist/{agent-https-BmXXKQAA.js → agent-https-DOs15BCJ.js} +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/autotrack.addon.d.ts +7 -7
- package/system/dist/builtins/autotrack/index.js +15 -8
- package/system/dist/builtins/autotrack/index.mjs +15 -8
- 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/composer.addon.js +3 -3
- package/system/dist/builtins/composer/composer.addon.mjs +3 -3
- 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 +3 -3
- package/system/dist/builtins/core-blocks/core-blocks.addon.mjs +3 -3
- 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-manager.addon.js +1 -1
- package/system/dist/builtins/device-manager/device-manager.addon.mjs +1 -1
- 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/address-book.d.ts +2 -0
- package/system/dist/builtins/local-network/local-network.addon.d.ts +7 -0
- package/system/dist/builtins/local-network/local-network.addon.js +27 -9
- package/system/dist/builtins/local-network/local-network.addon.mjs +27 -9
- package/system/dist/builtins/loki-logging/index.js +53 -83
- package/system/dist/builtins/loki-logging/index.mjs +53 -83
- package/system/dist/builtins/loki-logging/loki-logging.addon.d.ts +1 -4
- package/system/dist/builtins/loki-logging/migrations/index.d.ts +4 -1
- package/system/dist/builtins/loki-logging/migrations/retired-enabled-flag.d.ts +22 -0
- 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.d.ts +4 -10
- package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +16 -9
- package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +16 -9
- package/system/dist/builtins/snapshot/index.js +1 -1
- package/system/dist/builtins/snapshot/index.mjs +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/system-config.addon.js +3 -3
- package/system/dist/builtins/system-config/system-config.addon.mjs +284 -284
- 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-BHj1fNYC.js → capture-engine-BVpkq9Mv.js} +1 -1
- package/system/dist/{capture-engine-D9n4KDaN.mjs → capture-engine-D-oUDtX5.mjs} +1 -1
- package/system/dist/{composition-sources-wI4qWTz2.mjs → composition-sources-Br7JhpbD.mjs} +1 -1
- package/system/dist/{composition-sources-BGgIuuvd.js → composition-sources-DKCbVA67.js} +1 -1
- package/system/dist/{constants-DHqkxbYk.mjs → constants-Bl0Qxbek.mjs} +1 -1
- package/system/dist/{constants-DNdriMRD.js → constants-CJVY-mUq.js} +1 -1
- package/system/dist/{device-ca-gr5eE3h5.mjs → device-ca-BeDGy8NK.mjs} +1 -1
- package/system/dist/{device-ca-C2RzT1VT.js → device-ca-i8EbKp3q.js} +1 -1
- package/system/dist/{dist-BUoL5bbr.mjs → dist-CPUbgRkb.mjs} +280 -8
- package/system/dist/{dist-DV0V3JiE.js → dist-Ddkk4Dqq.js} +280 -8
- package/system/dist/file-host-worker.js +1 -1
- package/system/dist/file-host-worker.mjs +1 -1
- package/system/dist/{hub-mdns-ciao-DoSb8dwB.mjs → hub-mdns-ciao-DgF4SifE.mjs} +2 -2
- package/system/dist/{hub-mdns-ciao-Be5PGXW6.js → hub-mdns-ciao-lHRHbXqV.js} +2 -2
- package/system/dist/index.js +8 -8
- package/system/dist/index.mjs +8 -8
- package/system/dist/kernel/transport/child-cap-protocol.d.ts +1 -1
- package/system/dist/{legacy-integration-rows-door-DRC0xn6k.mjs → legacy-integration-rows-door-9JSt493H.mjs} +1 -1
- package/system/dist/{legacy-integration-rows-door-D5s8oM7e.js → legacy-integration-rows-door-n9GIUxgq.js} +1 -1
- package/system/dist/{restore-archive-Dh4gfCRY.js → restore-archive-BDvLSZtj.js} +1 -1
- package/system/dist/{restore-archive-DH3P9j-V.mjs → restore-archive-DWS1l6ac.mjs} +82 -82
- package/system/dist/{wal-maintenance-BWfH3Lov.mjs → wal-maintenance-BQJAmAwS.mjs} +0 -0
- package/system/dist/{wal-maintenance-DgN_WD5T.js → wal-maintenance-CWlz_qRq.js} +0 -0
- package/system/package.json +1 -1
- package/system/dist/builtins/loki-logging/retire-enabled-flag.d.ts +0 -33
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $s as isSecretMarker, Bo as BaseAddon, Fs as defineEntryKind, Js as isInstanceEnabled, Ns as defineAddonMigrations, Qs as isSecretFieldView, Tn as bareAddonId, Vr as integrationInstancesCapability, ei as isSameAddonId, ls as RecordIntegrationInstances, ms as RevConflictError, pi as logDestinationCapability, qi as preconditionOf } from "../../dist-
|
|
1
|
+
import { $s as isSecretMarker, Bo as BaseAddon, Fs as defineEntryKind, Js as isInstanceEnabled, Ns as defineAddonMigrations, Qs as isSecretFieldView, Tn as bareAddonId, Vr as integrationInstancesCapability, ei as isSameAddonId, ls as RecordIntegrationInstances, ms as RevConflictError, pi as logDestinationCapability, qi as preconditionOf } from "../../dist-CPUbgRkb.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
|
|
@@ -899,6 +899,39 @@ async function confirmRecordHoldsLegacy(ports, stored) {
|
|
|
899
899
|
if (legacyPassword && !record.hasPassword) return refuse("the record holds no password");
|
|
900
900
|
}
|
|
901
901
|
//#endregion
|
|
902
|
+
//#region src/builtins/loki-logging/migrations/retired-enabled-flag.ts
|
|
903
|
+
/**
|
|
904
|
+
* Loki's private `enabled` setting is gone (D777, D986, D987).
|
|
905
|
+
*
|
|
906
|
+
* The per-destination toggle is the only enable, and the legacy flag has not gated shipping since
|
|
907
|
+
* D777. A stored `enabled: false` therefore describes NOTHING in effect: carrying it over would
|
|
908
|
+
* switch off a destination that has been shipping for months, so this migration disables nothing.
|
|
909
|
+
* It deletes the dead key, and the marker the earlier boot-time carry-over left beside it, in ONE
|
|
910
|
+
* plan the engine applies under a precondition. Absence of the keys is the marker; a rerun finds
|
|
911
|
+
* nothing and writes nothing. A read that fails throws and nothing is written.
|
|
912
|
+
*/
|
|
913
|
+
/** The retired settings key. */
|
|
914
|
+
var RETIRED_ENABLED_KEY = "enabled";
|
|
915
|
+
var RETIRED_KEYS = [RETIRED_ENABLED_KEY, "migratedEnabled"];
|
|
916
|
+
async function planDropRetiredEnabledFlag(ports) {
|
|
917
|
+
const stored = await ports.readRawStored();
|
|
918
|
+
const present = RETIRED_KEYS.filter((key) => key in stored);
|
|
919
|
+
if (present.length === 0) return { edits: [] };
|
|
920
|
+
const flag = stored[RETIRED_ENABLED_KEY];
|
|
921
|
+
if (typeof flag === "boolean") ports.info(`Loki logging: the retired \`enabled: ${String(flag)}\` setting was removed; it has not gated shipping since D777, so nothing was switched. The per-destination toggle is the only enable.`);
|
|
922
|
+
const rowId = (key) => `${LOKI_ADDON_ID}.${key}`;
|
|
923
|
+
return { edits: [{
|
|
924
|
+
op: "deleteKeys",
|
|
925
|
+
scope: ADDON_SETTINGS_TABLE,
|
|
926
|
+
keys: present.map(rowId),
|
|
927
|
+
precondition: preconditionOf(Object.fromEntries(present.map((key) => [rowId(key), {
|
|
928
|
+
addonId: LOKI_ADDON_ID,
|
|
929
|
+
key,
|
|
930
|
+
value: stored[key]
|
|
931
|
+
}])))
|
|
932
|
+
}] };
|
|
933
|
+
}
|
|
934
|
+
//#endregion
|
|
902
935
|
//#region src/builtins/loki-logging/migrations/registry-toggle-to-record.ts
|
|
903
936
|
async function moveRegistryToggleToRecord(ports) {
|
|
904
937
|
const state = await ports.readRegistryState();
|
|
@@ -975,6 +1008,22 @@ var ADDON_MIGRATIONS = [
|
|
|
975
1008
|
fixtureMark: "a destinations record field the migration does not know (the job)"
|
|
976
1009
|
},
|
|
977
1010
|
procedure: moveRegistryToggleToRecord
|
|
1011
|
+
},
|
|
1012
|
+
{
|
|
1013
|
+
meta: {
|
|
1014
|
+
id: "loki-logging/2026-11-07-drop-retired-enabled-flag",
|
|
1015
|
+
owner: "loki-logging",
|
|
1016
|
+
level: "addon-state",
|
|
1017
|
+
seq: 4,
|
|
1018
|
+
dependsOn: [],
|
|
1019
|
+
store: "settings",
|
|
1020
|
+
scope: "cluster",
|
|
1021
|
+
onFailure: "tolerate",
|
|
1022
|
+
bodyKind: "plan",
|
|
1023
|
+
description: "Delete the retired `enabled` setting (it gates nothing any more) and the marker its boot-time carry-over left",
|
|
1024
|
+
fixtureMark: "a setting key the migration does not know"
|
|
1025
|
+
},
|
|
1026
|
+
plan: planDropRetiredEnabledFlag
|
|
978
1027
|
}
|
|
979
1028
|
];
|
|
980
1029
|
/**
|
|
@@ -985,46 +1034,7 @@ var ADDON_MIGRATIONS = [
|
|
|
985
1034
|
*/
|
|
986
1035
|
var INITIALIZE_MIGRATIONS = ADDON_MIGRATIONS.filter((m) => m.meta.id !== REGISTRY_TOGGLE_TO_RECORD_ID);
|
|
987
1036
|
//#endregion
|
|
988
|
-
//#region src/builtins/loki-logging/retire-enabled-flag.ts
|
|
989
|
-
/** The retired settings key. */
|
|
990
|
-
var RETIRED_ENABLED_KEY = "enabled";
|
|
991
|
-
/** Store key marking the retirement as done. Not a schema field. Pre-D777 name kept. */
|
|
992
|
-
var RETIREMENT_MARKER_KEY = "migratedEnabled";
|
|
993
|
-
function deferred(reason) {
|
|
994
|
-
return {
|
|
995
|
-
kind: "deferred",
|
|
996
|
-
reason
|
|
997
|
-
};
|
|
998
|
-
}
|
|
999
|
-
function isMarked(read) {
|
|
1000
|
-
return read.kind === "present" && read.value === true;
|
|
1001
|
-
}
|
|
1002
|
-
async function retireEnabledFlag(deps) {
|
|
1003
|
-
const marker = await deps.readStoredKey(RETIREMENT_MARKER_KEY);
|
|
1004
|
-
if (marker.kind === "unreadable") return deferred("settings store unreadable (marker)");
|
|
1005
|
-
if (isMarked(marker)) return { kind: "already-retired" };
|
|
1006
|
-
const flag = await deps.readStoredKey(RETIRED_ENABLED_KEY);
|
|
1007
|
-
if (flag.kind === "unreadable") return deferred("settings store unreadable (enabled)");
|
|
1008
|
-
const strippedValue = flag.kind === "present" && typeof flag.value === "boolean" ? flag.value : null;
|
|
1009
|
-
await deps.commit();
|
|
1010
|
-
if (!isMarked(await deps.readStoredKey("migratedEnabled"))) return deferred("retirement write did not land");
|
|
1011
|
-
return {
|
|
1012
|
-
kind: "retired",
|
|
1013
|
-
strippedValue
|
|
1014
|
-
};
|
|
1015
|
-
}
|
|
1016
|
-
//#endregion
|
|
1017
1037
|
//#region src/builtins/loki-logging/loki-logging.addon.ts
|
|
1018
|
-
/** Backoff between retirement attempts — the first ones are refused until the
|
|
1019
|
-
* provider registration reaches the hub. After the last, the next boot retries. */
|
|
1020
|
-
var RETIREMENT_RETRY_DELAYS_MS = [
|
|
1021
|
-
1e3,
|
|
1022
|
-
2e3,
|
|
1023
|
-
5e3,
|
|
1024
|
-
1e4,
|
|
1025
|
-
3e4,
|
|
1026
|
-
6e4
|
|
1027
|
-
];
|
|
1028
1038
|
/** An agent re-reads the record on this period; the hub applies a change at once (`onChanged`). */
|
|
1029
1039
|
var AGENT_REFRESH_MS = 3e4;
|
|
1030
1040
|
/** The headers the destination itself sends: tenant and basic auth. */
|
|
@@ -1049,7 +1059,6 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
1049
1059
|
destination = null;
|
|
1050
1060
|
instances = null;
|
|
1051
1061
|
refreshTimer = null;
|
|
1052
|
-
retirementTimer = null;
|
|
1053
1062
|
shuttingDown = false;
|
|
1054
1063
|
declared = false;
|
|
1055
1064
|
/** Instances whose keychain lock was already warned about — once per lock, per instance. */
|
|
@@ -1105,7 +1114,6 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
1105
1114
|
await this.destination.initialize();
|
|
1106
1115
|
const urls = this.destination.getStatuses().filter((status) => status.configured).map((status) => status.instanceId);
|
|
1107
1116
|
this.ctx.logger.info(urls.length > 0 ? `Loki logging initialized with ${String(urls.length)} destination(s): ${urls.join(", ")}` : "Loki logging registered but inactive (no destination configured)");
|
|
1108
|
-
this.attemptEnabledFlagRetirement(0);
|
|
1109
1117
|
return registrations;
|
|
1110
1118
|
}
|
|
1111
1119
|
async ensureDeclared() {
|
|
@@ -1181,6 +1189,9 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
1181
1189
|
return stored;
|
|
1182
1190
|
},
|
|
1183
1191
|
readRawStored: async () => this.resolveGlobalStore(),
|
|
1192
|
+
info: (message) => {
|
|
1193
|
+
this.ctx.logger.info(message);
|
|
1194
|
+
},
|
|
1184
1195
|
warn: (message) => {
|
|
1185
1196
|
this.ctx.logger.warn(message);
|
|
1186
1197
|
},
|
|
@@ -1287,45 +1298,6 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
1287
1298
|
};
|
|
1288
1299
|
}
|
|
1289
1300
|
}
|
|
1290
|
-
/** One attempt of the D777 carry-over; reschedules itself while deferred. */
|
|
1291
|
-
async attemptEnabledFlagRetirement(attempt) {
|
|
1292
|
-
if (this.shuttingDown) return;
|
|
1293
|
-
let outcome;
|
|
1294
|
-
try {
|
|
1295
|
-
outcome = await retireEnabledFlag({
|
|
1296
|
-
readStoredKey: (key) => this.readStoredGlobalKey(key),
|
|
1297
|
-
commit: async () => {
|
|
1298
|
-
const patch = {
|
|
1299
|
-
[RETIRED_ENABLED_KEY]: void 0,
|
|
1300
|
-
[RETIREMENT_MARKER_KEY]: true
|
|
1301
|
-
};
|
|
1302
|
-
await this.updateGlobalSettings(patch);
|
|
1303
|
-
}
|
|
1304
|
-
});
|
|
1305
|
-
} catch (err) {
|
|
1306
|
-
outcome = {
|
|
1307
|
-
kind: "deferred",
|
|
1308
|
-
reason: err instanceof Error ? err.message : String(err)
|
|
1309
|
-
};
|
|
1310
|
-
}
|
|
1311
|
-
if (outcome.kind === "retired" && outcome.strippedValue !== null) this.ctx.logger.info(`Loki logging: the retired \`enabled: ${String(outcome.strippedValue)}\` setting was removed; it has not gated shipping since D777, so nothing was switched. The per-destination toggle is the only enable.`);
|
|
1312
|
-
if (outcome.kind !== "deferred") return;
|
|
1313
|
-
const delay = RETIREMENT_RETRY_DELAYS_MS[attempt];
|
|
1314
|
-
if (delay === void 0) {
|
|
1315
|
-
this.ctx.logger.warn("Loki logging: enablement carry-over deferred to next boot", { meta: { reason: outcome.reason } });
|
|
1316
|
-
return;
|
|
1317
|
-
}
|
|
1318
|
-
this.ctx.logger.debug("Loki logging: enablement carry-over deferred", { meta: {
|
|
1319
|
-
reason: outcome.reason,
|
|
1320
|
-
attempt,
|
|
1321
|
-
retryInMs: delay
|
|
1322
|
-
} });
|
|
1323
|
-
this.retirementTimer = setTimeout(() => {
|
|
1324
|
-
this.retirementTimer = null;
|
|
1325
|
-
this.attemptEnabledFlagRetirement(attempt + 1);
|
|
1326
|
-
}, delay);
|
|
1327
|
-
this.retirementTimer.unref?.();
|
|
1328
|
-
}
|
|
1329
1301
|
/**
|
|
1330
1302
|
* Registration is done: the hub calls this after the providers are registered, so
|
|
1331
1303
|
* `listCapabilityProviders` now sees Loki. The registry-toggle migration cannot decide before
|
|
@@ -1350,8 +1322,6 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
1350
1322
|
}
|
|
1351
1323
|
async onShutdown() {
|
|
1352
1324
|
this.shuttingDown = true;
|
|
1353
|
-
if (this.retirementTimer !== null) clearTimeout(this.retirementTimer);
|
|
1354
|
-
this.retirementTimer = null;
|
|
1355
1325
|
if (this.refreshTimer !== null) clearInterval(this.refreshTimer);
|
|
1356
1326
|
this.refreshTimer = null;
|
|
1357
1327
|
await this.destination?.shutdown();
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* operator supplies a URL: `url` defaults to empty and `LokiDestination` treats
|
|
6
6
|
* that as inert. Whether it is used at all is the per-destination
|
|
7
7
|
* `log-destination` capability toggle — the ONE enable (D777); the old private
|
|
8
|
-
* `enabled` setting is retired by `
|
|
8
|
+
* `enabled` setting is retired by a ledger migration (`migrations/retired-enabled-flag.ts`). The provider is
|
|
9
9
|
* registered either way, so the Logging page can show it and the operator can
|
|
10
10
|
* turn it on without a restart of anything else.
|
|
11
11
|
*
|
|
@@ -30,7 +30,6 @@ export declare class LokiLoggingAddon extends BaseAddon<LokiAddonConfig> {
|
|
|
30
30
|
private destination;
|
|
31
31
|
private instances;
|
|
32
32
|
private refreshTimer;
|
|
33
|
-
private retirementTimer;
|
|
34
33
|
private shuttingDown;
|
|
35
34
|
private declared;
|
|
36
35
|
/** Instances whose keychain lock was already warned about — once per lock, per instance. */
|
|
@@ -58,8 +57,6 @@ export declare class LokiLoggingAddon extends BaseAddon<LokiAddonConfig> {
|
|
|
58
57
|
private migrationPorts;
|
|
59
58
|
/** Probe a Loki instance (`/ready`) with the form's values, falling back to the stored ones. */
|
|
60
59
|
private probe;
|
|
61
|
-
/** One attempt of the D777 carry-over; reschedules itself while deferred. */
|
|
62
|
-
private attemptEnabledFlagRetirement;
|
|
63
60
|
/**
|
|
64
61
|
* Registration is done: the hub calls this after the providers are registered, so
|
|
65
62
|
* `listCapabilityProviders` now sees Loki. The registry-toggle migration cannot decide before
|
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
import type { AddonMigration } from "@camstack/types";
|
|
2
2
|
import { type DropMovedSettingsPorts, type LokiMigrationPorts } from "./connection-to-records.js";
|
|
3
|
+
import { type RetiredEnabledFlagPorts } from "./retired-enabled-flag.js";
|
|
3
4
|
import { type RegistryToggleMigrationPorts } from "./registry-toggle-to-record.js";
|
|
5
|
+
export { RETIRED_ENABLED_KEY, RETIREMENT_MARKER_KEY, type RetiredEnabledFlagPorts } from "./retired-enabled-flag.js";
|
|
4
6
|
export type { RegistryState, RegistryToggleMigrationPorts } from "./registry-toggle-to-record.js";
|
|
5
7
|
export type { DropMovedSettingsPorts, LokiMigrationLog, LokiMigrationPorts, LokiRecordState } from "./connection-to-records.js";
|
|
6
8
|
/** Both bodies read through ONE port object, so the addon binds the catalogue once. */
|
|
7
|
-
export type LokiCataloguePorts = LokiMigrationPorts & DropMovedSettingsPorts & RegistryToggleMigrationPorts;
|
|
9
|
+
export type LokiCataloguePorts = LokiMigrationPorts & DropMovedSettingsPorts & RegistryToggleMigrationPorts & RetiredEnabledFlagPorts;
|
|
8
10
|
export declare const CONNECTION_TO_RECORDS_ID = "loki-logging/2026-11-02-connection-to-records";
|
|
9
11
|
export declare const REGISTRY_TOGGLE_TO_RECORD_ID = "loki-logging/2026-11-02-registry-toggle-to-record";
|
|
12
|
+
export declare const DROP_RETIRED_ENABLED_ID = "loki-logging/2026-11-07-drop-retired-enabled-flag";
|
|
10
13
|
/** The `loki-logging` catalogue (D987): offered to the engine when the hub-resident addon initialises. */
|
|
11
14
|
export declare const ADDON_MIGRATIONS: readonly AddonMigration<LokiCataloguePorts>[];
|
|
12
15
|
/**
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Loki's private `enabled` setting is gone (D777, D986, D987).
|
|
3
|
+
*
|
|
4
|
+
* The per-destination toggle is the only enable, and the legacy flag has not gated shipping since
|
|
5
|
+
* D777. A stored `enabled: false` therefore describes NOTHING in effect: carrying it over would
|
|
6
|
+
* switch off a destination that has been shipping for months, so this migration disables nothing.
|
|
7
|
+
* It deletes the dead key, and the marker the earlier boot-time carry-over left beside it, in ONE
|
|
8
|
+
* plan the engine applies under a precondition. Absence of the keys is the marker; a rerun finds
|
|
9
|
+
* nothing and writes nothing. A read that fails throws and nothing is written.
|
|
10
|
+
*/
|
|
11
|
+
import { type MigrationPlan } from "@camstack/types";
|
|
12
|
+
/** The retired settings key. */
|
|
13
|
+
export declare const RETIRED_ENABLED_KEY = "enabled";
|
|
14
|
+
/** The marker the boot-time carry-over set. Not a schema field. Pre-D777 name kept. */
|
|
15
|
+
export declare const RETIREMENT_MARKER_KEY = "migratedEnabled";
|
|
16
|
+
export interface RetiredEnabledFlagPorts {
|
|
17
|
+
/** The addon's stored settings as written (markers unresolved), unparsed. Throws when unreadable. */
|
|
18
|
+
readRawStored(): Promise<Readonly<Record<string, unknown>>>;
|
|
19
|
+
/** Said once, at the moment the key goes: the operator learns nothing was switched. */
|
|
20
|
+
info(message: string): void;
|
|
21
|
+
}
|
|
22
|
+
export declare function planDropRetiredEnabledFlag(ports: RetiredEnabledFlagPorts): Promise<MigrationPlan>;
|
|
@@ -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-Ddkk4Dqq.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 { Bo as BaseAddon, Fr as foldSnapshotByFunction, Ht as ROOT_BUCKET_KEY, Oc as errMsg, Si as metricsProviderCapability, cn as UNATTRIBUTED_BUCKET_KEY, js as createEvent, kc as EventCategory, sa as resolveBucketMs, ta as reducePoints } from "../../dist-
|
|
1
|
+
import { Bo as BaseAddon, Fr as foldSnapshotByFunction, Ht as ROOT_BUCKET_KEY, Oc as errMsg, Si as metricsProviderCapability, cn as UNATTRIBUTED_BUCKET_KEY, js as createEvent, kc as EventCategory, sa as resolveBucketMs, ta as reducePoints } from "../../dist-CPUbgRkb.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-Ddkk4Dqq.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 { Bo as BaseAddon, Ca as scoreRuntimes, Li as parseAcceleratorFactsJson, Oc as errMsg, Rs as emitReadiness, Wi as platformProbeCapability, kc as EventCategory, xr as enumerateInferenceDevices } from "../../dist-
|
|
2
|
+
import { Bo as BaseAddon, Ca as scoreRuntimes, Li as parseAcceleratorFactsJson, Oc as errMsg, Rs as emitReadiness, Wi as platformProbeCapability, kc as EventCategory, xr as enumerateInferenceDevices } from "../../dist-CPUbgRkb.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-Ddkk4Dqq.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 { $i as recordEntriesCapability, Bo as BaseAddon, Xo as InvalidRecordError, vc as secretViewsOf, ys as UnknownRecordKindError } from "../../dist-
|
|
1
|
+
import { $i as recordEntriesCapability, Bo as BaseAddon, Xo as InvalidRecordError, vc as secretViewsOf, ys as UnknownRecordKindError } from "../../dist-CPUbgRkb.mjs";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
import { randomUUID } from "node:crypto";
|
|
4
4
|
//#region src/builtins/record-entries/entries-service.ts
|
package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.d.ts
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* What it still owns — the load-bearing logic:
|
|
10
10
|
* The orchestrator owns the "operator wants this provider running"
|
|
11
11
|
* intent — an `enabledProviders: string[]` slice in its addon-store
|
|
12
|
-
* blob (
|
|
12
|
+
* blob (`state('enabledProviders')`). On boot we iterate the list and call
|
|
13
13
|
* `provider.start()` for each enabled entry, so a tunnel set up once
|
|
14
14
|
* stays up across hub restarts.
|
|
15
15
|
*
|
|
@@ -30,14 +30,8 @@
|
|
|
30
30
|
* it can only add already-connected providers, never evict.
|
|
31
31
|
*/
|
|
32
32
|
import { BaseAddon, type ProviderRegistration } from "@camstack/types";
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
* addonIds the operator has explicitly Started. Auto-respawned on
|
|
36
|
-
* boot so a tunnel set up once stays up across hub restarts.
|
|
37
|
-
*/
|
|
38
|
-
readonly enabledProviders: readonly string[];
|
|
39
|
-
}
|
|
40
|
-
export declare class RemoteAccessOrchestratorAddon extends BaseAddon<RemoteAccessOrchestratorConfig> {
|
|
33
|
+
export declare class RemoteAccessOrchestratorAddon extends BaseAddon<Record<string, never>> {
|
|
34
|
+
private readonly enabledProviders;
|
|
41
35
|
constructor();
|
|
42
36
|
protected onInitialize(): Promise<ProviderRegistration[]>;
|
|
43
37
|
/**
|
|
@@ -65,7 +59,7 @@ export declare class RemoteAccessOrchestratorAddon extends BaseAddon<RemoteAcces
|
|
|
65
59
|
*/
|
|
66
60
|
private reconcileAndPersist;
|
|
67
61
|
private autoStartEnabledProviders;
|
|
68
|
-
|
|
62
|
+
protected markEnabled(addonId: string, enabled: boolean): Promise<void>;
|
|
69
63
|
private resolveImpl;
|
|
70
64
|
}
|
|
71
65
|
export default RemoteAccessOrchestratorAddon;
|
|
@@ -3,7 +3,8 @@ 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-Ddkk4Dqq.js");
|
|
7
|
+
let zod = require("zod");
|
|
7
8
|
//#region src/builtins/remote-access-orchestrator/enabled-providers-reconcile.ts
|
|
8
9
|
/**
|
|
9
10
|
* Reconcile the durable `enabledProviders` set against authoritative
|
|
@@ -47,7 +48,7 @@ function reconcileEnabledProviders(currentEnabled, probes) {
|
|
|
47
48
|
* What it still owns — the load-bearing logic:
|
|
48
49
|
* The orchestrator owns the "operator wants this provider running"
|
|
49
50
|
* intent — an `enabledProviders: string[]` slice in its addon-store
|
|
50
|
-
* blob (
|
|
51
|
+
* blob (`state('enabledProviders')`). On boot we iterate the list and call
|
|
51
52
|
* `provider.start()` for each enabled entry, so a tunnel set up once
|
|
52
53
|
* stays up across hub restarts.
|
|
53
54
|
*
|
|
@@ -67,12 +68,18 @@ function reconcileEnabledProviders(currentEnabled, probes) {
|
|
|
67
68
|
* stopped). Running before `autoStartEnabledProviders` is safe:
|
|
68
69
|
* it can only add already-connected providers, never evict.
|
|
69
70
|
*/
|
|
71
|
+
/**
|
|
72
|
+
* addonIds the operator has explicitly Started (store key `enabledProviders`). Auto-respawned on
|
|
73
|
+
* boot so a tunnel set up once stays up across hub restarts.
|
|
74
|
+
*/
|
|
75
|
+
var EnabledProvidersSchema = zod.z.array(zod.z.string());
|
|
70
76
|
var RemoteAccessOrchestratorAddon = class extends require_dist.BaseAddon {
|
|
77
|
+
enabledProviders = this.state("enabledProviders", EnabledProvidersSchema, []);
|
|
71
78
|
constructor() {
|
|
72
|
-
super({
|
|
79
|
+
super({});
|
|
73
80
|
}
|
|
74
81
|
async onInitialize() {
|
|
75
|
-
this.ctx.logger.info("Remote-access orchestrator initialized (backend-only)", { meta: { enabledCount: this.
|
|
82
|
+
this.ctx.logger.info("Remote-access orchestrator initialized (backend-only)", { meta: { enabledCount: (await this.enabledProviders.get()).length } });
|
|
76
83
|
this.ctx.eventBus?.subscribe({ category: require_dist.EventCategory.NetworkTunnelStarted }, (event) => {
|
|
77
84
|
this.onTunnelLifecycle(event.source, true);
|
|
78
85
|
});
|
|
@@ -148,17 +155,17 @@ var RemoteAccessOrchestratorAddon = class extends require_dist.BaseAddon {
|
|
|
148
155
|
};
|
|
149
156
|
}
|
|
150
157
|
}));
|
|
151
|
-
const result = reconcileEnabledProviders(this.
|
|
158
|
+
const result = reconcileEnabledProviders(await this.enabledProviders.get(), probes);
|
|
152
159
|
if (!result.changed) return;
|
|
153
160
|
this.ctx.logger.info("reconcile: corrected enabledProviders from RPC-pulled state", { meta: {
|
|
154
161
|
added: result.added,
|
|
155
162
|
removed: result.removed
|
|
156
163
|
} });
|
|
157
|
-
await this.
|
|
164
|
+
await this.enabledProviders.set([...result.nextEnabled]);
|
|
158
165
|
}
|
|
159
166
|
async autoStartEnabledProviders() {
|
|
160
167
|
await this.reconcileAndPersist();
|
|
161
|
-
const ids = this.
|
|
168
|
+
const ids = await this.enabledProviders.get();
|
|
162
169
|
if (ids.length === 0) return;
|
|
163
170
|
this.ctx.logger.info("Auto-starting enabled remote-access providers", { meta: { addonIds: [...ids] } });
|
|
164
171
|
for (const addonId of ids) try {
|
|
@@ -194,7 +201,7 @@ var RemoteAccessOrchestratorAddon = class extends require_dist.BaseAddon {
|
|
|
194
201
|
}
|
|
195
202
|
}
|
|
196
203
|
async markEnabled(addonId, enabled) {
|
|
197
|
-
const current = new Set(this.
|
|
204
|
+
const current = new Set(await this.enabledProviders.get());
|
|
198
205
|
const wasEnabled = current.has(addonId);
|
|
199
206
|
if (enabled) current.add(addonId);
|
|
200
207
|
else current.delete(addonId);
|
|
@@ -203,7 +210,7 @@ var RemoteAccessOrchestratorAddon = class extends require_dist.BaseAddon {
|
|
|
203
210
|
addonId,
|
|
204
211
|
enabled
|
|
205
212
|
} });
|
|
206
|
-
await this.
|
|
213
|
+
await this.enabledProviders.set([...current]);
|
|
207
214
|
}
|
|
208
215
|
resolveImpl(addonId) {
|
|
209
216
|
return (this.capabilities?.getCollectionEntries("network-access") ?? []).find(([id]) => id === addonId)?.[1] ?? null;
|
package/system/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { Bo as BaseAddon, kc as EventCategory } from "../../dist-
|
|
1
|
+
import { Bo as BaseAddon, kc as EventCategory } from "../../dist-CPUbgRkb.mjs";
|
|
2
|
+
import { z } from "zod";
|
|
2
3
|
//#region src/builtins/remote-access-orchestrator/enabled-providers-reconcile.ts
|
|
3
4
|
/**
|
|
4
5
|
* Reconcile the durable `enabledProviders` set against authoritative
|
|
@@ -42,7 +43,7 @@ function reconcileEnabledProviders(currentEnabled, probes) {
|
|
|
42
43
|
* What it still owns — the load-bearing logic:
|
|
43
44
|
* The orchestrator owns the "operator wants this provider running"
|
|
44
45
|
* intent — an `enabledProviders: string[]` slice in its addon-store
|
|
45
|
-
* blob (
|
|
46
|
+
* blob (`state('enabledProviders')`). On boot we iterate the list and call
|
|
46
47
|
* `provider.start()` for each enabled entry, so a tunnel set up once
|
|
47
48
|
* stays up across hub restarts.
|
|
48
49
|
*
|
|
@@ -62,12 +63,18 @@ function reconcileEnabledProviders(currentEnabled, probes) {
|
|
|
62
63
|
* stopped). Running before `autoStartEnabledProviders` is safe:
|
|
63
64
|
* it can only add already-connected providers, never evict.
|
|
64
65
|
*/
|
|
66
|
+
/**
|
|
67
|
+
* addonIds the operator has explicitly Started (store key `enabledProviders`). Auto-respawned on
|
|
68
|
+
* boot so a tunnel set up once stays up across hub restarts.
|
|
69
|
+
*/
|
|
70
|
+
var EnabledProvidersSchema = z.array(z.string());
|
|
65
71
|
var RemoteAccessOrchestratorAddon = class extends BaseAddon {
|
|
72
|
+
enabledProviders = this.state("enabledProviders", EnabledProvidersSchema, []);
|
|
66
73
|
constructor() {
|
|
67
|
-
super({
|
|
74
|
+
super({});
|
|
68
75
|
}
|
|
69
76
|
async onInitialize() {
|
|
70
|
-
this.ctx.logger.info("Remote-access orchestrator initialized (backend-only)", { meta: { enabledCount: this.
|
|
77
|
+
this.ctx.logger.info("Remote-access orchestrator initialized (backend-only)", { meta: { enabledCount: (await this.enabledProviders.get()).length } });
|
|
71
78
|
this.ctx.eventBus?.subscribe({ category: EventCategory.NetworkTunnelStarted }, (event) => {
|
|
72
79
|
this.onTunnelLifecycle(event.source, true);
|
|
73
80
|
});
|
|
@@ -143,17 +150,17 @@ var RemoteAccessOrchestratorAddon = class extends BaseAddon {
|
|
|
143
150
|
};
|
|
144
151
|
}
|
|
145
152
|
}));
|
|
146
|
-
const result = reconcileEnabledProviders(this.
|
|
153
|
+
const result = reconcileEnabledProviders(await this.enabledProviders.get(), probes);
|
|
147
154
|
if (!result.changed) return;
|
|
148
155
|
this.ctx.logger.info("reconcile: corrected enabledProviders from RPC-pulled state", { meta: {
|
|
149
156
|
added: result.added,
|
|
150
157
|
removed: result.removed
|
|
151
158
|
} });
|
|
152
|
-
await this.
|
|
159
|
+
await this.enabledProviders.set([...result.nextEnabled]);
|
|
153
160
|
}
|
|
154
161
|
async autoStartEnabledProviders() {
|
|
155
162
|
await this.reconcileAndPersist();
|
|
156
|
-
const ids = this.
|
|
163
|
+
const ids = await this.enabledProviders.get();
|
|
157
164
|
if (ids.length === 0) return;
|
|
158
165
|
this.ctx.logger.info("Auto-starting enabled remote-access providers", { meta: { addonIds: [...ids] } });
|
|
159
166
|
for (const addonId of ids) try {
|
|
@@ -189,7 +196,7 @@ var RemoteAccessOrchestratorAddon = class extends BaseAddon {
|
|
|
189
196
|
}
|
|
190
197
|
}
|
|
191
198
|
async markEnabled(addonId, enabled) {
|
|
192
|
-
const current = new Set(this.
|
|
199
|
+
const current = new Set(await this.enabledProviders.get());
|
|
193
200
|
const wasEnabled = current.has(addonId);
|
|
194
201
|
if (enabled) current.add(addonId);
|
|
195
202
|
else current.delete(addonId);
|
|
@@ -198,7 +205,7 @@ var RemoteAccessOrchestratorAddon = class extends BaseAddon {
|
|
|
198
205
|
addonId,
|
|
199
206
|
enabled
|
|
200
207
|
} });
|
|
201
|
-
await this.
|
|
208
|
+
await this.enabledProviders.set([...current]);
|
|
202
209
|
}
|
|
203
210
|
resolveImpl(addonId) {
|
|
204
211
|
return (this.capabilities?.getCollectionEntries("network-access") ?? []).find(([id]) => id === addonId)?.[1] ?? null;
|
|
@@ -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-Ddkk4Dqq.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");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Bo as BaseAddon, Dc as DeviceType, En as batteryCapability, Oc as errMsg, Tc as DeviceFeature, Tn as bareAddonId, ac as nodePin, bi as memoizePinnedFfmpeg, g as BatteryStatusSchema, ja as snapshotCapability, kc as EventCategory, ur as deriveBatteryPresence, za as streamQualityLabel } from "../../dist-
|
|
1
|
+
import { Bo as BaseAddon, Dc as DeviceType, En as batteryCapability, Oc as errMsg, Tc as DeviceFeature, Tn as bareAddonId, ac as nodePin, bi as memoizePinnedFfmpeg, g as BatteryStatusSchema, ja as snapshotCapability, kc as EventCategory, ur as deriveBatteryPresence, za as streamQualityLabel } from "../../dist-CPUbgRkb.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";
|
|
@@ -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-Ddkk4Dqq.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 { Bo as BaseAddon, La as storageProviderCapability, Pr as filesystemBrowseCapability } from "../../dist-
|
|
1
|
+
import { Bo as BaseAddon, La as storageProviderCapability, Pr as filesystemBrowseCapability } from "../../dist-CPUbgRkb.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-CWlz_qRq.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-BQJAmAwS.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-Ddkk4Dqq.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-CWlz_qRq.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-n9GIUxgq.js");
|
|
12
12
|
let zod = require("zod");
|
|
13
13
|
let node_crypto = require("node:crypto");
|
|
14
14
|
let node_fs = require("node:fs");
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { Bo as BaseAddon, Ci as migrationsCapability, Ct as MIGRATION_API_V1_METHODS, F as DATABASE_SNAPSHOT_TIMEOUT_MS, I as DATA_STORE_DATABASES, Ii as orderMigrations, Ko as DeclarationRefusedError, Ln as catalogueIssues, Ms as customAction, N as DATABASE_SNAPSHOT_PARTIAL_SUFFIX, Na as storageAdminCapability, Oc as errMsg$1, Ot as MigrationMetaSchema, P as DATABASE_SNAPSHOT_SUFFIX, Ps as defineCustomActions, Tn as bareAddonId, Xo as InvalidRecordError, Zo as NoCallerError, _s as TransactRefusedError, ar as databaseSnapshotCapability, ea as recordsCapability, ha as resolveRunnerId, ir as dataStoreProviderCapability, kc as EventCategory, ks as collectSecretMarkerRefs, os as RUNTIME_DEFAULTS, rs as RECORD_SWEEP_INTERVAL_MS, sc as normalizeSecretOwner, to as vectorStoreCapability, us as RecordKindDeclarationSchema, ys as UnknownRecordKindError } from "../../dist-
|
|
1
|
+
import { Bo as BaseAddon, Ci as migrationsCapability, Ct as MIGRATION_API_V1_METHODS, F as DATABASE_SNAPSHOT_TIMEOUT_MS, I as DATA_STORE_DATABASES, Ii as orderMigrations, Ko as DeclarationRefusedError, Ln as catalogueIssues, Ms as customAction, N as DATABASE_SNAPSHOT_PARTIAL_SUFFIX, Na as storageAdminCapability, Oc as errMsg$1, Ot as MigrationMetaSchema, P as DATABASE_SNAPSHOT_SUFFIX, Ps as defineCustomActions, Tn as bareAddonId, Xo as InvalidRecordError, Zo as NoCallerError, _s as TransactRefusedError, ar as databaseSnapshotCapability, ea as recordsCapability, ha as resolveRunnerId, ir as dataStoreProviderCapability, kc as EventCategory, ks as collectSecretMarkerRefs, os as RUNTIME_DEFAULTS, rs as RECORD_SWEEP_INTERVAL_MS, sc as normalizeSecretOwner, to as vectorStoreCapability, us as RecordKindDeclarationSchema, ys as UnknownRecordKindError } from "../../dist-CPUbgRkb.mjs";
|
|
2
2
|
import { r as retiredKeyStoreOf, t as purgeRetiredSettingsKeys } from "../../retired-settings-keys-u6xQA6r7.mjs";
|
|
3
|
-
import { A as callRecords, D as RecordsEngine, E as databaseOfStore, M as controlTargetOf, O as callControl, T as trustResult, _ as rehydrateError, a as WalMaintenance, b as collectTransferables, c as vectorProviderOfOwnedFile, d as callMigrate, f as migrateTargetOf, g as DuplicatePlacementError, h as DatabaseBusyError, j as callVector, k as callData, l as SqliteSettingsBackend, m as CrossDatabaseTransactError, o as createVectorIndex, p as CollectionPlacementError, s as vectorProviderOf, u as HUB_MIGRATIONS, x as isFileHostMessage } from "../../wal-maintenance-
|
|
3
|
+
import { A as callRecords, D as RecordsEngine, E as databaseOfStore, M as controlTargetOf, O as callControl, T as trustResult, _ as rehydrateError, a as WalMaintenance, b as collectTransferables, c as vectorProviderOfOwnedFile, d as callMigrate, f as migrateTargetOf, g as DuplicatePlacementError, h as DatabaseBusyError, j as callVector, k as callData, l as SqliteSettingsBackend, m as CrossDatabaseTransactError, o as createVectorIndex, p as CollectionPlacementError, s as vectorProviderOf, u as HUB_MIGRATIONS, x as isFileHostMessage } from "../../wal-maintenance-BQJAmAwS.mjs";
|
|
4
4
|
import { r as isSnapshotWorkerMessage } from "../../sqlite-snapshot-protocol-2QaTouWV.mjs";
|
|
5
5
|
import { a as isWorkerMessage, t as WAL_CHECKPOINT_LARGE_PASS_FRAMES } from "../../wal-checkpoint-policy-BahrTtyD.mjs";
|
|
6
|
-
import { a as patchLegacyIntegrationRows, i as legacyIntegrationAddonId, n as clearLegacyIntegrationRows, o as readLegacyIntegrationRows, r as deleteLegacyIntegrationRowKeys } from "../../legacy-integration-rows-door-
|
|
6
|
+
import { a as patchLegacyIntegrationRows, i as legacyIntegrationAddonId, n as clearLegacyIntegrationRows, o as readLegacyIntegrationRows, r as deleteLegacyIntegrationRowKeys } from "../../legacy-integration-rows-door-9JSt493H.mjs";
|
|
7
7
|
import { createRequire } from "node:module";
|
|
8
8
|
import { z } from "zod";
|
|
9
9
|
import { randomUUID } from "node:crypto";
|
|
@@ -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-Ddkk4Dqq.js");
|
|
7
7
|
const require_read_all_rows$1 = require("../../read-all-rows-CVoO1ONM.js");
|
|
8
8
|
let zod = require("zod");
|
|
9
9
|
let node_crypto = require("node:crypto");
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $s as isSecretMarker, Bo as BaseAddon, Ds as collectSecretConfigKeys, Er as evictionPolicyOfLocation, Es as buildSecretRef, Fa as storageMigrationCapability, Ha as switchStateOfMode, Is as defineRecordKinds, Jt as STORAGE_LOCATION_MODES, Ms as customAction, Ns as defineAddonMigrations, Pa as storageCapability, Ps as defineCustomActions, Qr as isLocationEnabled, Qs as isSecretFieldView, Rr as gbToBytes, Ti as modeMayWrite, Vr as integrationInstancesCapability, Zs as isSecretClear, _i as mayWriteToLocation, da as resolveLocationMode, fc as recordSecretRef, gi as mayReadLocation, in as StorageMigrationJobSchema, io as withLocationMode, is as REDACTED_SECRET, kc as EventCategory, mc as resolveSecretMarkers, nc as makeSecretMarker, nn as StorageLocationModeSchema, oc as normalizeNodeId, oi as legacyModeOf, rn as StorageLocationTypeSchema, tn as StorageCleanupJobSchema, uc as parseSecretRef, wa as settingsStoreCapability, wi as modeForSwitch, xc as toSecretFieldView, xt as LegacyStorageLocationDefaultSchema } from "../../dist-
|
|
1
|
+
import { $s as isSecretMarker, Bo as BaseAddon, Ds as collectSecretConfigKeys, Er as evictionPolicyOfLocation, Es as buildSecretRef, Fa as storageMigrationCapability, Ha as switchStateOfMode, Is as defineRecordKinds, Jt as STORAGE_LOCATION_MODES, Ms as customAction, Ns as defineAddonMigrations, Pa as storageCapability, Ps as defineCustomActions, Qr as isLocationEnabled, Qs as isSecretFieldView, Rr as gbToBytes, Ti as modeMayWrite, Vr as integrationInstancesCapability, Zs as isSecretClear, _i as mayWriteToLocation, da as resolveLocationMode, fc as recordSecretRef, gi as mayReadLocation, in as StorageMigrationJobSchema, io as withLocationMode, is as REDACTED_SECRET, kc as EventCategory, mc as resolveSecretMarkers, nc as makeSecretMarker, nn as StorageLocationModeSchema, oc as normalizeNodeId, oi as legacyModeOf, rn as StorageLocationTypeSchema, tn as StorageCleanupJobSchema, uc as parseSecretRef, wa as settingsStoreCapability, wi as modeForSwitch, xc as toSecretFieldView, xt as LegacyStorageLocationDefaultSchema } from "../../dist-CPUbgRkb.mjs";
|
|
2
2
|
import { t as require_read_all_rows } from "../../read-all-rows-TaPqdWNF.mjs";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
import { randomUUID } from "node:crypto";
|
|
@@ -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-
|
|
6
|
+
const require_dist = require("../../dist-Ddkk4Dqq.js");
|
|
7
7
|
const require_safe_buffer$1 = require("../../safe-buffer-D3aoa-7X.js");
|
|
8
8
|
const require_x509_es = require("../../x509.es-WtnRNyYS.js");
|
|
9
|
-
const require_agent_https = require("../../agent-https-
|
|
10
|
-
const require_constants$8 = require("../../constants-
|
|
9
|
+
const require_agent_https = require("../../agent-https-DOs15BCJ.js");
|
|
10
|
+
const require_constants$8 = require("../../constants-CJVY-mUq.js");
|
|
11
11
|
const require_src$1 = require("../../src-CnAqG6EF.js");
|
|
12
12
|
let zod = require("zod");
|
|
13
13
|
let node_crypto = require("node:crypto");
|