@camstack/addon-provider-onvif 1.2.31 → 1.2.33
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/addon.js +409 -30
- package/dist/addon.mjs +409 -30
- package/package.json +1 -1
package/dist/addon.js
CHANGED
|
@@ -7467,6 +7467,111 @@ var CameraSwitchGroupSchema = object({
|
|
|
7467
7467
|
fetchedAt: number()
|
|
7468
7468
|
});
|
|
7469
7469
|
/**
|
|
7470
|
+
* Per-component log CHANNELS — the gate a hot path consults, and the registry
|
|
7471
|
+
* an addon declares its channels in.
|
|
7472
|
+
*
|
|
7473
|
+
* ## Two axes, deliberately separated
|
|
7474
|
+
*
|
|
7475
|
+
* - **DECLARATION** — which channels exist. Only the addon knows:
|
|
7476
|
+
* `stream-broker` knows webrtc/ICE/RTP, `provider-reolink` knows
|
|
7477
|
+
* baichuan/handshake. A hand-wired central list rots at the first addition,
|
|
7478
|
+
* and rots silently. So a channel is declared where it is consulted, and the
|
|
7479
|
+
* `log-channels` capability enumerates the declarations.
|
|
7480
|
+
* - **VALUE** — at which level, for which scope, until when. That stays ONE
|
|
7481
|
+
* thing: the logging settings document on the `system` cap. Two authorities
|
|
7482
|
+
* over the values is the exact defect
|
|
7483
|
+
* `docs/design/plans/2026-08-26-logging-per-componente.md` was written to
|
|
7484
|
+
* remove; re-introducing it from the cure side would be grotesque.
|
|
7485
|
+
*
|
|
7486
|
+
* Nothing in this file reads a clock, an env var or a store. The registry is
|
|
7487
|
+
* a MIRROR: it is moved only by {@link LogChannelRegistry.apply}, called off
|
|
7488
|
+
* the hot path with a value somebody actually read, and by
|
|
7489
|
+
* {@link LogChannelRegistry.tick}, called on a timer. A store read that fails
|
|
7490
|
+
* never reaches here, so it can neither disarm an armed channel nor arm a
|
|
7491
|
+
* disarmed one (D49).
|
|
7492
|
+
*
|
|
7493
|
+
* ## The canonical call shape
|
|
7494
|
+
*
|
|
7495
|
+
* ```ts
|
|
7496
|
+
* if (CH_RTP.on && CH_RTP.wants(deviceId)) {
|
|
7497
|
+
* CH_RTP.log(logger, 'rtp subscriber added', { tags: { deviceId }, meta: { ssrc } })
|
|
7498
|
+
* }
|
|
7499
|
+
* ```
|
|
7500
|
+
*
|
|
7501
|
+
* `on` is a plain boolean FIELD — never a getter — and it is the FIRST thing
|
|
7502
|
+
* read. Disarmed, a call site costs one load and one branch, and the `extras`
|
|
7503
|
+
* object literal is never constructed because it lives inside the branch. It
|
|
7504
|
+
* is the same shape already proven in production at `stream-broker.ts:1650`,
|
|
7505
|
+
* and the same discipline `LoggingGate.allowsDestination` uses for the
|
|
7506
|
+
* destination floor (measured at 1.93 ns/call when off).
|
|
7507
|
+
*
|
|
7508
|
+
* ## Why a channel emits at `info`
|
|
7509
|
+
*
|
|
7510
|
+
* `loki-logging.addon.ts` pins the destination default at `info` and
|
|
7511
|
+
* `loki-destination.ts` drops everything below it, so a line emitted at
|
|
7512
|
+
* `debug` never reaches Loki and the hub's in-memory ring only holds ~35
|
|
7513
|
+
* minutes. A diagnostic that cannot be read an hour later is worse than no
|
|
7514
|
+
* diagnostic, because it looks done. {@link LogChannelGate.log} therefore
|
|
7515
|
+
* emits at the channel's declared level, whose schema floor is `info`.
|
|
7516
|
+
*/
|
|
7517
|
+
/**
|
|
7518
|
+
* The level a channel writes at once armed.
|
|
7519
|
+
*
|
|
7520
|
+
* `debug` is absent ON PURPOSE and not by omission: below `info` the line does
|
|
7521
|
+
* not leave the process for Loki, and the whole point of arming a channel is
|
|
7522
|
+
* to read it later.
|
|
7523
|
+
*/
|
|
7524
|
+
var LogChannelLevelSchema = _enum([
|
|
7525
|
+
"info",
|
|
7526
|
+
"warn",
|
|
7527
|
+
"error"
|
|
7528
|
+
]);
|
|
7529
|
+
/**
|
|
7530
|
+
* What an addon declares about one channel. No value, no state — a
|
|
7531
|
+
* declaration is inert.
|
|
7532
|
+
*/
|
|
7533
|
+
var LogChannelDescriptorSchema = object({
|
|
7534
|
+
/**
|
|
7535
|
+
* Dotted `area.thing`, unique across the workspace. `area` is conventionally
|
|
7536
|
+
* the addon's short name so an operator reading a channel list can tell who
|
|
7537
|
+
* owns it without a second lookup.
|
|
7538
|
+
*/
|
|
7539
|
+
name: string().min(3).regex(/^[a-z0-9-]+(\.[a-z0-9-]+)+$/, "a channel name is dotted lower-kebab, e.g. area.thing"),
|
|
7540
|
+
/** One sentence: what the operator will SEE after arming it. */
|
|
7541
|
+
description: string().min(1),
|
|
7542
|
+
/** The level its lines are emitted at. Never below `info`. */
|
|
7543
|
+
defaultLevel: LogChannelLevelSchema,
|
|
7544
|
+
/**
|
|
7545
|
+
* Whether this channel can be narrowed to a camera.
|
|
7546
|
+
*
|
|
7547
|
+
* `true` is a PROMISE with two halves, and both must hold: the gate is
|
|
7548
|
+
* consulted with the numeric device id, AND every line the channel admits
|
|
7549
|
+
* carries `tags: { deviceId }` with that same numeric id. The second half is
|
|
7550
|
+
* what makes `| json | deviceId="617"` work in Loki — `loki-payload.ts`
|
|
7551
|
+
* keeps `deviceId` out of the stream labels for cardinality, so the tag in
|
|
7552
|
+
* the body is the only way to filter.
|
|
7553
|
+
*
|
|
7554
|
+
* A channel whose lines carry the device only in `meta` (or not at all) is
|
|
7555
|
+
* declared `false`. Declaring it `true` anyway would be a lie the UI repeats:
|
|
7556
|
+
* the operator narrows to one camera, sees nothing, and concludes the code
|
|
7557
|
+
* path was never taken.
|
|
7558
|
+
*/
|
|
7559
|
+
perDevice: boolean()
|
|
7560
|
+
});
|
|
7561
|
+
/**
|
|
7562
|
+
* An armed window over one channel, as the document hands it to a mirror.
|
|
7563
|
+
*
|
|
7564
|
+
* A window is a DEADLINE, never a flag (ADR-0244): a channel somebody forgot
|
|
7565
|
+
* expires by itself, which is the one failure a boolean cannot avoid.
|
|
7566
|
+
*/
|
|
7567
|
+
var LogChannelWindowSchema = object({
|
|
7568
|
+
channel: string().min(1),
|
|
7569
|
+
/** Epoch ms the window closes at. */
|
|
7570
|
+
armedUntilMs: number(),
|
|
7571
|
+
/** `null` = every camera. A non-empty list narrows to those numeric ids. */
|
|
7572
|
+
deviceIds: array(number().int()).readonly().nullable()
|
|
7573
|
+
});
|
|
7574
|
+
/**
|
|
7470
7575
|
* Ops-log — the durable, append-only operations audit shared by the
|
|
7471
7576
|
* recordings and events management surfaces.
|
|
7472
7577
|
*
|
|
@@ -10985,6 +11090,35 @@ var MutationFilterSchema = object({
|
|
|
10985
11090
|
whereBetween: record(string(), tuple([unknown(), unknown()])).optional(),
|
|
10986
11091
|
whereNot: record(string(), unknown()).optional()
|
|
10987
11092
|
});
|
|
11093
|
+
/**
|
|
11094
|
+
* One scalar an {@link settingsStoreCapability.methods.aggregate} call asks for.
|
|
11095
|
+
*
|
|
11096
|
+
* `as` names the slot in the result, so the SAME column may be asked twice with
|
|
11097
|
+
* two operations (`MIN(startMs)` and `MAX(startMs)` in one round trip) — which
|
|
11098
|
+
* a `Record<column, op>` shape could not express.
|
|
11099
|
+
*/
|
|
11100
|
+
var AggregateFieldSchema = object({
|
|
11101
|
+
/** Result key. */
|
|
11102
|
+
as: string().min(1),
|
|
11103
|
+
/** Column to aggregate. Must be a real column of a declared collection. */
|
|
11104
|
+
field: string().min(1),
|
|
11105
|
+
op: _enum([
|
|
11106
|
+
"sum",
|
|
11107
|
+
"min",
|
|
11108
|
+
"max"
|
|
11109
|
+
])
|
|
11110
|
+
});
|
|
11111
|
+
/**
|
|
11112
|
+
* `COUNT(*)` plus one number per requested field.
|
|
11113
|
+
*
|
|
11114
|
+
* `null` means NO ROW MATCHED, never zero: a `SUM` over an empty set and a sum
|
|
11115
|
+
* that really is 0 are different facts, and an accounting caller that renders
|
|
11116
|
+
* "0 bytes, oldest = 0" for "nothing here" reports a lie about a disk.
|
|
11117
|
+
*/
|
|
11118
|
+
var AggregateResultSchema = object({
|
|
11119
|
+
count: number().int(),
|
|
11120
|
+
values: record(string(), number().nullable())
|
|
11121
|
+
});
|
|
10988
11122
|
/** A single stored record: `{ id, data }`. */
|
|
10989
11123
|
var SettingsRecordSchema = object({
|
|
10990
11124
|
id: string(),
|
|
@@ -11069,6 +11203,11 @@ method(object({
|
|
|
11069
11203
|
collection: string(),
|
|
11070
11204
|
filter: QueryFilterSchema.optional()
|
|
11071
11205
|
}), number()), method(object({
|
|
11206
|
+
namespace: string().optional(),
|
|
11207
|
+
collection: string(),
|
|
11208
|
+
fields: array(AggregateFieldSchema).readonly(),
|
|
11209
|
+
filter: QueryFilterSchema.optional()
|
|
11210
|
+
}), AggregateResultSchema), method(object({
|
|
11072
11211
|
namespace: string().optional(),
|
|
11073
11212
|
collection: string(),
|
|
11074
11213
|
field: string(),
|
|
@@ -11185,6 +11324,11 @@ method(_void(), EngineInfoSchema, { auth: "admin" }), method(object({
|
|
|
11185
11324
|
collection: string(),
|
|
11186
11325
|
filter: QueryFilterSchema.optional()
|
|
11187
11326
|
}), number(), { auth: "admin" }), method(object({
|
|
11327
|
+
namespace: string().optional(),
|
|
11328
|
+
collection: string(),
|
|
11329
|
+
fields: array(AggregateFieldSchema).readonly(),
|
|
11330
|
+
filter: QueryFilterSchema.optional()
|
|
11331
|
+
}), AggregateResultSchema, { auth: "admin" }), method(object({
|
|
11188
11332
|
namespace: string().optional(),
|
|
11189
11333
|
collection: string(),
|
|
11190
11334
|
field: string(),
|
|
@@ -11801,24 +11945,6 @@ var deviceProviderCapability = {
|
|
|
11801
11945
|
})
|
|
11802
11946
|
}
|
|
11803
11947
|
};
|
|
11804
|
-
/**
|
|
11805
|
-
* Device Manager capability — hub-side singleton that unifies device persistence,
|
|
11806
|
-
* live registry access, and all management operations into a single tRPC surface.
|
|
11807
|
-
*
|
|
11808
|
-
* Replaces:
|
|
11809
|
-
* - `device-persistence` capability (persistence methods absorbed here)
|
|
11810
|
-
* - `device-management.router.ts` (deleted in Phase 2)
|
|
11811
|
-
* - `device-ops.router.ts` (compat layer — deleted; device-provider ops absorbed here)
|
|
11812
|
-
*
|
|
11813
|
-
* All device provider addons (rtsp, onvif, frigate, …) are hub-local: they may
|
|
11814
|
-
* fork into separate processes but never run on remote cluster agents. Therefore:
|
|
11815
|
-
* - No nodeId routing needed — this is a pure hub singleton.
|
|
11816
|
-
* - The hub's DeviceRegistry is the single source of truth for all live devices.
|
|
11817
|
-
* - No shadow registry or cross-node aggregation required.
|
|
11818
|
-
*
|
|
11819
|
-
* Forked workers register devices back to the hub via `ctx.devices`
|
|
11820
|
-
* (DeviceManagerApi → ctx.api.deviceManager.registerDevice), same as today.
|
|
11821
|
-
*/
|
|
11822
11948
|
/** One child-placement directive on a container's `childLayout`. Structurally
|
|
11823
11949
|
* identical to `ChildLayoutEntry` in `device-management.ts` — the cap wire
|
|
11824
11950
|
* shape for the same field. The child is identified by its re-sync-stable
|
|
@@ -12187,7 +12313,7 @@ method(object({
|
|
|
12187
12313
|
* it answers today and the caller filters as it already does.
|
|
12188
12314
|
*/
|
|
12189
12315
|
deviceIds: array(number()).optional()
|
|
12190
|
-
}), array(DeviceInfoSchema)), method(object({ deviceId: number() }), DeviceInfoSchema.nullable()), method(object({ parentDeviceId: number() }), array(DeviceInfoSchema)), method(object({ deviceId: number() }), object({
|
|
12316
|
+
}), array(DeviceInfoSchema)), method(object({ deviceId: number() }), DeviceInfoSchema.nullable()), method(object({ parentDeviceId: number() }), array(DeviceInfoSchema)), method(object({ parentDeviceIds: array(number()).max(256) }), record(string(), array(DeviceInfoSchema))), method(object({ deviceId: number() }), object({
|
|
12191
12317
|
mode: LinkedDevicesModeSchema,
|
|
12192
12318
|
devices: array(LinkedDeviceSchema)
|
|
12193
12319
|
})), method(object({ deviceIds: array(number()) }), array(LinkedDevicesForDeviceSchema)), method(object({ deviceId: number() }), array(StreamSourceEntrySchema$1)), method(object({ deviceId: number() }), array(ConfigEntrySchema)), method(object({ deviceId: number() }), ConfigUISchemaOutput), method(object({
|
|
@@ -12911,6 +13037,59 @@ method(LlmGenerateBaseInputSchema, LlmGenerateResultSchema, { kind: "mutation" }
|
|
|
12911
13037
|
kind: "mutation",
|
|
12912
13038
|
auth: "admin"
|
|
12913
13039
|
});
|
|
13040
|
+
/**
|
|
13041
|
+
* `log-channels` — the capability an addon DECLARES its diagnostic channels
|
|
13042
|
+
* through. It stores nothing.
|
|
13043
|
+
*
|
|
13044
|
+
* ## Why a capability at all, and why this shape
|
|
13045
|
+
*
|
|
13046
|
+
* Which channels exist is knowledge only the addon has: `stream-broker` knows
|
|
13047
|
+
* webrtc/ICE/RTP, `provider-reolink` knows baichuan/handshake. A central list
|
|
13048
|
+
* maintained by hand rots at the first addition and rots INVISIBLY — nothing
|
|
13049
|
+
* fails, an operator just never sees the channel somebody added. So the list
|
|
13050
|
+
* is assembled from declarations at runtime.
|
|
13051
|
+
*
|
|
13052
|
+
* The shape is copied from `log-destination.cap.ts`, which already does
|
|
13053
|
+
* exactly this job: `mode: 'collection'`, `internal: true`,
|
|
13054
|
+
* `mount: { kind: 'skip' }` — no tRPC route, no generated hooks — while
|
|
13055
|
+
* `addons.listCapabilityProviders` still enumerates it, and the hub's
|
|
13056
|
+
* `CapabilityRegistry` still holds an RPC proxy per provider so a forked
|
|
13057
|
+
* runner's declarations reach hub-main over the transport that already exists.
|
|
13058
|
+
* No new UDS message, no second registry.
|
|
13059
|
+
*
|
|
13060
|
+
* ## What it deliberately does NOT own
|
|
13061
|
+
*
|
|
13062
|
+
* The VALUES — which channel is armed, for which cameras, until when — live in
|
|
13063
|
+
* ONE place: the logging settings document on the `system` cap
|
|
13064
|
+
* (`getLoggingSettings` / `setLoggingSettings`). Two authorities over the same
|
|
13065
|
+
* value is the defect the plan behind this work exists to remove, and
|
|
13066
|
+
* `setRequestCensus` was retired (D245) rather than allowed to be a second
|
|
13067
|
+
* one. {@link logChannelsCapability} therefore has no getter for a level, no
|
|
13068
|
+
* setter for a window and no persistence of any kind.
|
|
13069
|
+
*
|
|
13070
|
+
* ## Why `apply` is here even so
|
|
13071
|
+
*
|
|
13072
|
+
* The gate lives in the addon's PROCESS; the document lives in hub-main. Some
|
|
13073
|
+
* seam has to carry the value from the authority to the mirror, and a channel
|
|
13074
|
+
* that cannot be reached is precisely the dead knob this whole slice exists to
|
|
13075
|
+
* make impossible (D62 — `audioThresholdDbfs`, the HA entities with no source).
|
|
13076
|
+
* `apply` is that seam and nothing more: it writes an in-memory mirror, it
|
|
13077
|
+
* persists nothing, it is never the source of a value, and it is called only
|
|
13078
|
+
* with a set the hub actually read (D49 — a read that fails does not call it
|
|
13079
|
+
* at all, so no channel is silently disarmed by a bad read).
|
|
13080
|
+
*/
|
|
13081
|
+
/** What `apply` reports back — enough to log, not enough to be a second state. */
|
|
13082
|
+
var LogChannelApplyResultSchema = object({
|
|
13083
|
+
/** How many declared channels are armed in this process after the call. */
|
|
13084
|
+
armed: number().int().min(0),
|
|
13085
|
+
/**
|
|
13086
|
+
* Names the document armed that this process does not declare. Reported
|
|
13087
|
+
* rather than swallowed: a name here is either a typo or an addon that has
|
|
13088
|
+
* not booted, and both deserve a line instead of silence.
|
|
13089
|
+
*/
|
|
13090
|
+
unknown: array(string()).readonly()
|
|
13091
|
+
});
|
|
13092
|
+
method(_void(), array(LogChannelDescriptorSchema).readonly()), method(object({ windows: array(LogChannelWindowSchema).readonly() }), LogChannelApplyResultSchema, { kind: "mutation" });
|
|
12914
13093
|
var LogLevelSchema = _enum([
|
|
12915
13094
|
"debug",
|
|
12916
13095
|
"info",
|
|
@@ -26312,17 +26491,60 @@ var SetSiteLocationInputSchema = object({
|
|
|
26312
26491
|
longitude: number().min(-180).max(180)
|
|
26313
26492
|
}).nullable();
|
|
26314
26493
|
/**
|
|
26315
|
-
*
|
|
26494
|
+
* The TRANSPORT a call arrived on.
|
|
26495
|
+
*
|
|
26496
|
+
* Every counted call carries exactly one of these, and `unknown` is a PLANE
|
|
26497
|
+
* rather than a gap: a plane that cannot attribute a call declares it here, so
|
|
26498
|
+
* the call lands in a named bucket instead of vanishing. `planes` summing to
|
|
26499
|
+
* `procedureCalls` is what makes "the sum of the planes explains the total"
|
|
26500
|
+
* checkable rather than asserted.
|
|
26501
|
+
*
|
|
26502
|
+
* - `http` — the Fastify tRPC plugin (`/trpc/*`), one context per request.
|
|
26503
|
+
* - `ws` — `applyWSSHandler`, counted per OPERATION rather than per
|
|
26504
|
+
* connection; the viewer talks to the hub over `wsLink`
|
|
26505
|
+
* exclusively, so this is the plane the HTTP census could not see.
|
|
26506
|
+
* - `mesh` — the in-process `$core-caps` bridge (`createCaller`), which
|
|
26507
|
+
* never touches a socket and therefore never touched a census.
|
|
26508
|
+
* - `unknown` — counted, plane undecidable. No hook produces it today, and
|
|
26509
|
+
* that is exactly what its `0` asserts: every plane the hub has can name
|
|
26510
|
+
* itself. It is an output bucket, never a knob — a call that arrives on a
|
|
26511
|
+
* plane nobody instrumented lands here instead of vanishing from the total.
|
|
26512
|
+
*/
|
|
26513
|
+
var TransportPlaneSchema = _enum([
|
|
26514
|
+
"http",
|
|
26515
|
+
"ws",
|
|
26516
|
+
"mesh",
|
|
26517
|
+
"unknown"
|
|
26518
|
+
]);
|
|
26519
|
+
/**
|
|
26520
|
+
* Calls per plane. Every key is always present, `0` included — an absent plane
|
|
26521
|
+
* reads as "not instrumented", which is the one thing this census must never
|
|
26522
|
+
* make an operator wonder about.
|
|
26523
|
+
*/
|
|
26524
|
+
var TransportPlaneCountsSchema = object({
|
|
26525
|
+
http: number(),
|
|
26526
|
+
ws: number(),
|
|
26527
|
+
mesh: number(),
|
|
26528
|
+
unknown: number()
|
|
26529
|
+
});
|
|
26530
|
+
/**
|
|
26531
|
+
* One `(plane, procedure, user-agent, ip, principal)` tuple of the transport
|
|
26316
26532
|
* census. `principal` is the DERIVED identity (`apocaliss92 (admin)`,
|
|
26317
26533
|
* `scoped:1a2b3c4d (scoped-token)`, `anonymous`) that the tRPC error log
|
|
26318
26534
|
* already prints - never a token, never an `Authorization` header.
|
|
26535
|
+
*
|
|
26536
|
+
* `subscriptions` is counted APART from `calls`: a subscription is opened once
|
|
26537
|
+
* and lives for hours, so folding it into a call count makes one long-lived
|
|
26538
|
+
* stream look like a storm.
|
|
26319
26539
|
*/
|
|
26320
26540
|
var RequestCensusGroupSchema = object({
|
|
26541
|
+
plane: TransportPlaneSchema,
|
|
26321
26542
|
procedure: string(),
|
|
26322
26543
|
userAgent: string(),
|
|
26323
26544
|
ip: string(),
|
|
26324
26545
|
principal: string(),
|
|
26325
26546
|
calls: number(),
|
|
26547
|
+
subscriptions: number(),
|
|
26326
26548
|
perMin: number()
|
|
26327
26549
|
});
|
|
26328
26550
|
/**
|
|
@@ -26335,6 +26557,14 @@ var RequestCensusGroupSchema = object({
|
|
|
26335
26557
|
var RequestCensusProcedureSchema = object({
|
|
26336
26558
|
procedure: string(),
|
|
26337
26559
|
calls: number(),
|
|
26560
|
+
/**
|
|
26561
|
+
* The same total, split by transport. THIS is the row that answers the
|
|
26562
|
+
* question the census exists for: one look at `deviceManager.listAll` says
|
|
26563
|
+
* which plane carried the 4 960, without joining two log lines by eye.
|
|
26564
|
+
*/
|
|
26565
|
+
planes: TransportPlaneCountsSchema,
|
|
26566
|
+
/** Subscription STARTS on this procedure. Never folded into `calls`. */
|
|
26567
|
+
subscriptions: number(),
|
|
26338
26568
|
perMin: number()
|
|
26339
26569
|
});
|
|
26340
26570
|
/**
|
|
@@ -26362,14 +26592,45 @@ var RequestCensusStatusSchema = object({
|
|
|
26362
26592
|
*/
|
|
26363
26593
|
procedureCalls: number(),
|
|
26364
26594
|
/**
|
|
26595
|
+
* `procedureCalls` split by transport. The four keys sum to
|
|
26596
|
+
* `procedureCalls` by construction - {@link RequestCensusSnapshotSchema}'s
|
|
26597
|
+
* `planesExplainTotal` is that identity, checked rather than assumed.
|
|
26598
|
+
*/
|
|
26599
|
+
planes: TransportPlaneCountsSchema,
|
|
26600
|
+
/**
|
|
26601
|
+
* True iff `planes` sums to `procedureCalls`. False means a call was counted
|
|
26602
|
+
* on no plane at all - which is a RESULT (a plane is missing from the
|
|
26603
|
+
* instrument), not a failure, and it has to be visible to be read as one.
|
|
26604
|
+
*/
|
|
26605
|
+
planesExplainTotal: boolean(),
|
|
26606
|
+
/**
|
|
26365
26607
|
* tRPC WebSocket connections opened during the window. NOT calls - the WS
|
|
26366
|
-
*
|
|
26367
|
-
*
|
|
26608
|
+
* adapter resolves one context per connection - kept because a plane's call
|
|
26609
|
+
* count of zero against 37 open connections says something different from a
|
|
26610
|
+
* plane with no connections at all.
|
|
26368
26611
|
*/
|
|
26369
26612
|
wsConnections: number(),
|
|
26613
|
+
/**
|
|
26614
|
+
* Client frames the WS plane looked at. `wsMessages` far above
|
|
26615
|
+
* `planes.ws + subscriptions` means most traffic is not operations
|
|
26616
|
+
* (keepalives, connection params) - which is itself an answer.
|
|
26617
|
+
*/
|
|
26618
|
+
wsMessages: number(),
|
|
26619
|
+
/**
|
|
26620
|
+
* Subscription STARTS across every plane, excluded from `procedureCalls` on
|
|
26621
|
+
* purpose: one live-events stream opened at boot and held for six hours is
|
|
26622
|
+
* one subscription, and counting it as a call would let a quiet plane
|
|
26623
|
+
* masquerade as the storm.
|
|
26624
|
+
*/
|
|
26625
|
+
subscriptions: number(),
|
|
26626
|
+
/** `subscription.stop` frames. Starts minus stops is what is still open. */
|
|
26627
|
+
subscriptionStops: number(),
|
|
26370
26628
|
distinctGroups: number(),
|
|
26371
|
-
/**
|
|
26372
|
-
*
|
|
26629
|
+
/**
|
|
26630
|
+
* Operations counted in the totals whose CALLER attribution was shed at the
|
|
26631
|
+
* cardinality bound. Unrelated to the `unknown` PLANE: these calls know
|
|
26632
|
+
* which transport they arrived on, they just lost their group row.
|
|
26633
|
+
*/
|
|
26373
26634
|
unattributedCalls: number(),
|
|
26374
26635
|
procedures: array(RequestCensusProcedureSchema).readonly(),
|
|
26375
26636
|
groups: array(RequestCensusGroupSchema).readonly()
|
|
@@ -26392,10 +26653,11 @@ var DiagnosticIdSchema = _enum(["request-census"]);
|
|
|
26392
26653
|
* The layers of the level hierarchy, general → specific. The most specific
|
|
26393
26654
|
* layer that carries an explicit value wins.
|
|
26394
26655
|
*
|
|
26395
|
-
* `component`
|
|
26396
|
-
*
|
|
26397
|
-
*
|
|
26398
|
-
*
|
|
26656
|
+
* `component` became RESOLVABLE on 2026-08-27: a component is a declared log
|
|
26657
|
+
* CHANNEL (`stream-broker.webrtc`, `provider-reolink.baichuan`), named by
|
|
26658
|
+
* `scopeComponent`. It was declared-but-dark in the first slice precisely so
|
|
26659
|
+
* that turning it on would not force every consumer of this document to widen
|
|
26660
|
+
* a `levelSource` enum — which is what has now not happened.
|
|
26399
26661
|
*/
|
|
26400
26662
|
var LoggingScopeKindSchema = _enum([
|
|
26401
26663
|
"cluster",
|
|
@@ -26422,6 +26684,14 @@ var LoggingLevelLayerSchema = object({
|
|
|
26422
26684
|
scope: LoggingScopeKindSchema,
|
|
26423
26685
|
/** The node this layer speaks for; `null` on the cluster layer. */
|
|
26424
26686
|
nodeId: string().nullable(),
|
|
26687
|
+
/**
|
|
26688
|
+
* The declared channel this layer speaks for; `null` on every layer but
|
|
26689
|
+
* `component`. Never folded into `nodeId`: a component level is CLUSTER-WIDE
|
|
26690
|
+
* by design — the convention this repo settled on is one orchestrator-wide
|
|
26691
|
+
* setting, never per node (D52) — so a component layer that carried a node
|
|
26692
|
+
* would invite a per-node copy of a value that has no per-node meaning.
|
|
26693
|
+
*/
|
|
26694
|
+
component: string().nullable(),
|
|
26425
26695
|
/** Explicitly set here, or `null` when this layer inherits. */
|
|
26426
26696
|
level: LogLevelSchema$1.nullable()
|
|
26427
26697
|
});
|
|
@@ -26463,6 +26733,49 @@ var DiagnosticWindowPatchSchema = object({
|
|
|
26463
26733
|
reportEveryMs: number().int().positive().optional()
|
|
26464
26734
|
});
|
|
26465
26735
|
/**
|
|
26736
|
+
* A channel ARMED, as the document reports it.
|
|
26737
|
+
*
|
|
26738
|
+
* `armMs` is not echoed back: what an operator needs to see is the deadline
|
|
26739
|
+
* and the time left, because a diagnostic left running is itself an incident
|
|
26740
|
+
* and "armed for 10 minutes" said an hour ago is not an answer.
|
|
26741
|
+
*/
|
|
26742
|
+
var LogChannelWindowStateSchema = object({
|
|
26743
|
+
channel: string(),
|
|
26744
|
+
armed: boolean(),
|
|
26745
|
+
/** Epoch ms the window closes at. 0 when disarmed. */
|
|
26746
|
+
armedUntilMs: number(),
|
|
26747
|
+
/** Ms left before it expires on its own. 0 when disarmed. */
|
|
26748
|
+
remainingMs: number(),
|
|
26749
|
+
/**
|
|
26750
|
+
* The cameras it is narrowed to, or `null` for every camera.
|
|
26751
|
+
*
|
|
26752
|
+
* A channel declared `perDevice: false` can only ever report `null` here:
|
|
26753
|
+
* its lines do not carry `tags: { deviceId }`, so narrowing them would
|
|
26754
|
+
* produce a filter that silently matches nothing. The server REFUSES such a
|
|
26755
|
+
* patch rather than quietly widening it — ignoring the request would teach
|
|
26756
|
+
* the operator that per-camera filtering works on that channel when it does
|
|
26757
|
+
* not.
|
|
26758
|
+
*/
|
|
26759
|
+
deviceIds: array(number().int()).readonly().nullable()
|
|
26760
|
+
});
|
|
26761
|
+
/**
|
|
26762
|
+
* `armMs: 0` DISARMS. Same grammar as {@link DiagnosticWindowPatchSchema}, and
|
|
26763
|
+
* for the same reason: a channel is a window with a deadline, never a switch.
|
|
26764
|
+
*/
|
|
26765
|
+
var LogChannelWindowPatchSchema = object({
|
|
26766
|
+
channel: string().min(1),
|
|
26767
|
+
armMs: number().int().min(0),
|
|
26768
|
+
/**
|
|
26769
|
+
* Narrow to these numeric device ids. Absent or `null` = every camera.
|
|
26770
|
+
*
|
|
26771
|
+
* Numeric because the repo's own rule makes it possible: every log line
|
|
26772
|
+
* about a device carries `tags: { deviceId }` with the numeric id. That rule
|
|
26773
|
+
* was paid for with a 22% thumbnail gap and a 3-hour media blackout both
|
|
26774
|
+
* diagnosed by hand, and this is the first thing that collects on it.
|
|
26775
|
+
*/
|
|
26776
|
+
deviceIds: array(number().int()).readonly().nullable().optional()
|
|
26777
|
+
});
|
|
26778
|
+
/**
|
|
26466
26779
|
* A PATCH, and patches MERGE.
|
|
26467
26780
|
*
|
|
26468
26781
|
* A field absent from the patch is left exactly as it was — arming a
|
|
@@ -26481,7 +26794,14 @@ var LoggingSettingsPatchSchema = object({
|
|
|
26481
26794
|
* Only the diagnostics NAMED here change. An armed window that is not listed
|
|
26482
26795
|
* keeps running — a patch is never a full replacement.
|
|
26483
26796
|
*/
|
|
26484
|
-
diagnostics: array(DiagnosticWindowPatchSchema).readonly().optional()
|
|
26797
|
+
diagnostics: array(DiagnosticWindowPatchSchema).readonly().optional(),
|
|
26798
|
+
/**
|
|
26799
|
+
* Only the channels NAMED here change. An armed channel that is not listed
|
|
26800
|
+
* keeps running — same rule as `diagnostics`, because a patch that silently
|
|
26801
|
+
* disarmed the channels it did not mention would make the Levels page and
|
|
26802
|
+
* the Diagnostics page fight over the same value.
|
|
26803
|
+
*/
|
|
26804
|
+
channels: array(LogChannelWindowPatchSchema).readonly().optional()
|
|
26485
26805
|
});
|
|
26486
26806
|
/**
|
|
26487
26807
|
* Which LAYER of the hierarchy is addressed. Absent = the cluster layer.
|
|
@@ -26494,9 +26814,22 @@ var LoggingSettingsPatchSchema = object({
|
|
|
26494
26814
|
* authority over the whole hierarchy and answers for every layer, so the
|
|
26495
26815
|
* layer selector needs a name the transport does not already own.
|
|
26496
26816
|
*/
|
|
26497
|
-
var GetLoggingSettingsInputSchema = object({
|
|
26817
|
+
var GetLoggingSettingsInputSchema = object({
|
|
26818
|
+
scopeNodeId: string().optional(),
|
|
26819
|
+
/**
|
|
26820
|
+
* The declared CHANNEL this document is addressed at, when the caller wants
|
|
26821
|
+
* the `component` layer. Absent = the node/cluster hierarchy only.
|
|
26822
|
+
*
|
|
26823
|
+
* Naming it separately rather than overloading `scopeNodeId` keeps the two
|
|
26824
|
+
* axes from collapsing: a component level is cluster-wide, a node level is
|
|
26825
|
+
* not, and one selector for both would make "which of these two did I just
|
|
26826
|
+
* set" unanswerable — the exact ambiguity `explicit` exists to remove.
|
|
26827
|
+
*/
|
|
26828
|
+
scopeComponent: string().optional()
|
|
26829
|
+
});
|
|
26498
26830
|
var SetLoggingSettingsInputSchema = object({
|
|
26499
26831
|
scopeNodeId: string().optional(),
|
|
26832
|
+
scopeComponent: string().optional(),
|
|
26500
26833
|
patch: LoggingSettingsPatchSchema
|
|
26501
26834
|
});
|
|
26502
26835
|
/**
|
|
@@ -26511,9 +26844,20 @@ var SetLoggingSettingsInputSchema = object({
|
|
|
26511
26844
|
var LoggingSettingsStateSchema = object({
|
|
26512
26845
|
/** The layer this document was read at. `null` = the cluster layer. */
|
|
26513
26846
|
scopeNodeId: string().nullable(),
|
|
26847
|
+
/** The channel this document was read at. `null` = no component layer. */
|
|
26848
|
+
scopeComponent: string().nullable(),
|
|
26514
26849
|
effective: LoggingEffectiveSchema,
|
|
26515
26850
|
explicit: LoggingExplicitSchema,
|
|
26516
26851
|
activeWindows: array(DiagnosticWindowSchema).readonly(),
|
|
26852
|
+
/**
|
|
26853
|
+
* Every channel the cluster's addons DECLARE, gathered from the
|
|
26854
|
+
* `log-channels` providers. Not stored anywhere: assembled per read, so a
|
|
26855
|
+
* channel added by a redeployed addon appears without anybody editing a
|
|
26856
|
+
* list, and a channel whose addon is gone stops being offered.
|
|
26857
|
+
*/
|
|
26858
|
+
channels: array(LogChannelDescriptorSchema).readonly(),
|
|
26859
|
+
/** The channels ARMED right now, each with its deadline. */
|
|
26860
|
+
activeChannels: array(LogChannelWindowStateSchema).readonly(),
|
|
26517
26861
|
persisted: boolean()
|
|
26518
26862
|
});
|
|
26519
26863
|
method(_void(), FeatureManifestSchema), method(_void(), HealthStatusSchema), method(_void(), FeatureManifestSchema), method(_void(), array(NetworkAddressSchema).readonly()), method(_void(), unknown().nullable(), { auth: "admin" }), method(record(string(), unknown()), _null(), {
|
|
@@ -28500,6 +28844,12 @@ Object.freeze({
|
|
|
28500
28844
|
addonId: null,
|
|
28501
28845
|
access: "view"
|
|
28502
28846
|
},
|
|
28847
|
+
"dataStoreProvider.aggregate": {
|
|
28848
|
+
capName: "data-store-provider",
|
|
28849
|
+
capScope: "system",
|
|
28850
|
+
addonId: null,
|
|
28851
|
+
access: "view"
|
|
28852
|
+
},
|
|
28503
28853
|
"dataStoreProvider.count": {
|
|
28504
28854
|
capName: "data-store-provider",
|
|
28505
28855
|
capScope: "system",
|
|
@@ -28914,6 +29264,12 @@ Object.freeze({
|
|
|
28914
29264
|
addonId: null,
|
|
28915
29265
|
access: "view"
|
|
28916
29266
|
},
|
|
29267
|
+
"deviceManager.getChildrenBatch": {
|
|
29268
|
+
capName: "device-manager",
|
|
29269
|
+
capScope: "system",
|
|
29270
|
+
addonId: null,
|
|
29271
|
+
access: "view"
|
|
29272
|
+
},
|
|
28917
29273
|
"deviceManager.getConfigSchema": {
|
|
28918
29274
|
capName: "device-manager",
|
|
28919
29275
|
capScope: "system",
|
|
@@ -29964,6 +30320,18 @@ Object.freeze({
|
|
|
29964
30320
|
addonId: null,
|
|
29965
30321
|
access: "create"
|
|
29966
30322
|
},
|
|
30323
|
+
"logChannels.apply": {
|
|
30324
|
+
capName: "log-channels",
|
|
30325
|
+
capScope: "system",
|
|
30326
|
+
addonId: null,
|
|
30327
|
+
access: "create"
|
|
30328
|
+
},
|
|
30329
|
+
"logChannels.list": {
|
|
30330
|
+
capName: "log-channels",
|
|
30331
|
+
capScope: "system",
|
|
30332
|
+
addonId: null,
|
|
30333
|
+
access: "view"
|
|
30334
|
+
},
|
|
29967
30335
|
"logDestination.query": {
|
|
29968
30336
|
capName: "log-destination",
|
|
29969
30337
|
capScope: "system",
|
|
@@ -32118,6 +32486,12 @@ Object.freeze({
|
|
|
32118
32486
|
addonId: null,
|
|
32119
32487
|
access: "create"
|
|
32120
32488
|
},
|
|
32489
|
+
"settingsStore.aggregate": {
|
|
32490
|
+
capName: "settings-store",
|
|
32491
|
+
capScope: "system",
|
|
32492
|
+
addonId: null,
|
|
32493
|
+
access: "view"
|
|
32494
|
+
},
|
|
32121
32495
|
"settingsStore.count": {
|
|
32122
32496
|
capName: "settings-store",
|
|
32123
32497
|
capScope: "system",
|
|
@@ -33697,6 +34071,11 @@ Object.freeze({
|
|
|
33697
34071
|
form: "single",
|
|
33698
34072
|
optional: false
|
|
33699
34073
|
}],
|
|
34074
|
+
"deviceManager.getChildrenBatch": [{
|
|
34075
|
+
name: "parentDeviceIds",
|
|
34076
|
+
form: "array",
|
|
34077
|
+
optional: false
|
|
34078
|
+
}],
|
|
33700
34079
|
"deviceManager.getConfigSchema": [{
|
|
33701
34080
|
name: "deviceId",
|
|
33702
34081
|
form: "single",
|
package/dist/addon.mjs
CHANGED
|
@@ -7468,6 +7468,111 @@ var CameraSwitchGroupSchema = object({
|
|
|
7468
7468
|
fetchedAt: number()
|
|
7469
7469
|
});
|
|
7470
7470
|
/**
|
|
7471
|
+
* Per-component log CHANNELS — the gate a hot path consults, and the registry
|
|
7472
|
+
* an addon declares its channels in.
|
|
7473
|
+
*
|
|
7474
|
+
* ## Two axes, deliberately separated
|
|
7475
|
+
*
|
|
7476
|
+
* - **DECLARATION** — which channels exist. Only the addon knows:
|
|
7477
|
+
* `stream-broker` knows webrtc/ICE/RTP, `provider-reolink` knows
|
|
7478
|
+
* baichuan/handshake. A hand-wired central list rots at the first addition,
|
|
7479
|
+
* and rots silently. So a channel is declared where it is consulted, and the
|
|
7480
|
+
* `log-channels` capability enumerates the declarations.
|
|
7481
|
+
* - **VALUE** — at which level, for which scope, until when. That stays ONE
|
|
7482
|
+
* thing: the logging settings document on the `system` cap. Two authorities
|
|
7483
|
+
* over the values is the exact defect
|
|
7484
|
+
* `docs/design/plans/2026-08-26-logging-per-componente.md` was written to
|
|
7485
|
+
* remove; re-introducing it from the cure side would be grotesque.
|
|
7486
|
+
*
|
|
7487
|
+
* Nothing in this file reads a clock, an env var or a store. The registry is
|
|
7488
|
+
* a MIRROR: it is moved only by {@link LogChannelRegistry.apply}, called off
|
|
7489
|
+
* the hot path with a value somebody actually read, and by
|
|
7490
|
+
* {@link LogChannelRegistry.tick}, called on a timer. A store read that fails
|
|
7491
|
+
* never reaches here, so it can neither disarm an armed channel nor arm a
|
|
7492
|
+
* disarmed one (D49).
|
|
7493
|
+
*
|
|
7494
|
+
* ## The canonical call shape
|
|
7495
|
+
*
|
|
7496
|
+
* ```ts
|
|
7497
|
+
* if (CH_RTP.on && CH_RTP.wants(deviceId)) {
|
|
7498
|
+
* CH_RTP.log(logger, 'rtp subscriber added', { tags: { deviceId }, meta: { ssrc } })
|
|
7499
|
+
* }
|
|
7500
|
+
* ```
|
|
7501
|
+
*
|
|
7502
|
+
* `on` is a plain boolean FIELD — never a getter — and it is the FIRST thing
|
|
7503
|
+
* read. Disarmed, a call site costs one load and one branch, and the `extras`
|
|
7504
|
+
* object literal is never constructed because it lives inside the branch. It
|
|
7505
|
+
* is the same shape already proven in production at `stream-broker.ts:1650`,
|
|
7506
|
+
* and the same discipline `LoggingGate.allowsDestination` uses for the
|
|
7507
|
+
* destination floor (measured at 1.93 ns/call when off).
|
|
7508
|
+
*
|
|
7509
|
+
* ## Why a channel emits at `info`
|
|
7510
|
+
*
|
|
7511
|
+
* `loki-logging.addon.ts` pins the destination default at `info` and
|
|
7512
|
+
* `loki-destination.ts` drops everything below it, so a line emitted at
|
|
7513
|
+
* `debug` never reaches Loki and the hub's in-memory ring only holds ~35
|
|
7514
|
+
* minutes. A diagnostic that cannot be read an hour later is worse than no
|
|
7515
|
+
* diagnostic, because it looks done. {@link LogChannelGate.log} therefore
|
|
7516
|
+
* emits at the channel's declared level, whose schema floor is `info`.
|
|
7517
|
+
*/
|
|
7518
|
+
/**
|
|
7519
|
+
* The level a channel writes at once armed.
|
|
7520
|
+
*
|
|
7521
|
+
* `debug` is absent ON PURPOSE and not by omission: below `info` the line does
|
|
7522
|
+
* not leave the process for Loki, and the whole point of arming a channel is
|
|
7523
|
+
* to read it later.
|
|
7524
|
+
*/
|
|
7525
|
+
var LogChannelLevelSchema = _enum([
|
|
7526
|
+
"info",
|
|
7527
|
+
"warn",
|
|
7528
|
+
"error"
|
|
7529
|
+
]);
|
|
7530
|
+
/**
|
|
7531
|
+
* What an addon declares about one channel. No value, no state — a
|
|
7532
|
+
* declaration is inert.
|
|
7533
|
+
*/
|
|
7534
|
+
var LogChannelDescriptorSchema = object({
|
|
7535
|
+
/**
|
|
7536
|
+
* Dotted `area.thing`, unique across the workspace. `area` is conventionally
|
|
7537
|
+
* the addon's short name so an operator reading a channel list can tell who
|
|
7538
|
+
* owns it without a second lookup.
|
|
7539
|
+
*/
|
|
7540
|
+
name: string().min(3).regex(/^[a-z0-9-]+(\.[a-z0-9-]+)+$/, "a channel name is dotted lower-kebab, e.g. area.thing"),
|
|
7541
|
+
/** One sentence: what the operator will SEE after arming it. */
|
|
7542
|
+
description: string().min(1),
|
|
7543
|
+
/** The level its lines are emitted at. Never below `info`. */
|
|
7544
|
+
defaultLevel: LogChannelLevelSchema,
|
|
7545
|
+
/**
|
|
7546
|
+
* Whether this channel can be narrowed to a camera.
|
|
7547
|
+
*
|
|
7548
|
+
* `true` is a PROMISE with two halves, and both must hold: the gate is
|
|
7549
|
+
* consulted with the numeric device id, AND every line the channel admits
|
|
7550
|
+
* carries `tags: { deviceId }` with that same numeric id. The second half is
|
|
7551
|
+
* what makes `| json | deviceId="617"` work in Loki — `loki-payload.ts`
|
|
7552
|
+
* keeps `deviceId` out of the stream labels for cardinality, so the tag in
|
|
7553
|
+
* the body is the only way to filter.
|
|
7554
|
+
*
|
|
7555
|
+
* A channel whose lines carry the device only in `meta` (or not at all) is
|
|
7556
|
+
* declared `false`. Declaring it `true` anyway would be a lie the UI repeats:
|
|
7557
|
+
* the operator narrows to one camera, sees nothing, and concludes the code
|
|
7558
|
+
* path was never taken.
|
|
7559
|
+
*/
|
|
7560
|
+
perDevice: boolean()
|
|
7561
|
+
});
|
|
7562
|
+
/**
|
|
7563
|
+
* An armed window over one channel, as the document hands it to a mirror.
|
|
7564
|
+
*
|
|
7565
|
+
* A window is a DEADLINE, never a flag (ADR-0244): a channel somebody forgot
|
|
7566
|
+
* expires by itself, which is the one failure a boolean cannot avoid.
|
|
7567
|
+
*/
|
|
7568
|
+
var LogChannelWindowSchema = object({
|
|
7569
|
+
channel: string().min(1),
|
|
7570
|
+
/** Epoch ms the window closes at. */
|
|
7571
|
+
armedUntilMs: number(),
|
|
7572
|
+
/** `null` = every camera. A non-empty list narrows to those numeric ids. */
|
|
7573
|
+
deviceIds: array(number().int()).readonly().nullable()
|
|
7574
|
+
});
|
|
7575
|
+
/**
|
|
7471
7576
|
* Ops-log — the durable, append-only operations audit shared by the
|
|
7472
7577
|
* recordings and events management surfaces.
|
|
7473
7578
|
*
|
|
@@ -10986,6 +11091,35 @@ var MutationFilterSchema = object({
|
|
|
10986
11091
|
whereBetween: record(string(), tuple([unknown(), unknown()])).optional(),
|
|
10987
11092
|
whereNot: record(string(), unknown()).optional()
|
|
10988
11093
|
});
|
|
11094
|
+
/**
|
|
11095
|
+
* One scalar an {@link settingsStoreCapability.methods.aggregate} call asks for.
|
|
11096
|
+
*
|
|
11097
|
+
* `as` names the slot in the result, so the SAME column may be asked twice with
|
|
11098
|
+
* two operations (`MIN(startMs)` and `MAX(startMs)` in one round trip) — which
|
|
11099
|
+
* a `Record<column, op>` shape could not express.
|
|
11100
|
+
*/
|
|
11101
|
+
var AggregateFieldSchema = object({
|
|
11102
|
+
/** Result key. */
|
|
11103
|
+
as: string().min(1),
|
|
11104
|
+
/** Column to aggregate. Must be a real column of a declared collection. */
|
|
11105
|
+
field: string().min(1),
|
|
11106
|
+
op: _enum([
|
|
11107
|
+
"sum",
|
|
11108
|
+
"min",
|
|
11109
|
+
"max"
|
|
11110
|
+
])
|
|
11111
|
+
});
|
|
11112
|
+
/**
|
|
11113
|
+
* `COUNT(*)` plus one number per requested field.
|
|
11114
|
+
*
|
|
11115
|
+
* `null` means NO ROW MATCHED, never zero: a `SUM` over an empty set and a sum
|
|
11116
|
+
* that really is 0 are different facts, and an accounting caller that renders
|
|
11117
|
+
* "0 bytes, oldest = 0" for "nothing here" reports a lie about a disk.
|
|
11118
|
+
*/
|
|
11119
|
+
var AggregateResultSchema = object({
|
|
11120
|
+
count: number().int(),
|
|
11121
|
+
values: record(string(), number().nullable())
|
|
11122
|
+
});
|
|
10989
11123
|
/** A single stored record: `{ id, data }`. */
|
|
10990
11124
|
var SettingsRecordSchema = object({
|
|
10991
11125
|
id: string(),
|
|
@@ -11070,6 +11204,11 @@ method(object({
|
|
|
11070
11204
|
collection: string(),
|
|
11071
11205
|
filter: QueryFilterSchema.optional()
|
|
11072
11206
|
}), number()), method(object({
|
|
11207
|
+
namespace: string().optional(),
|
|
11208
|
+
collection: string(),
|
|
11209
|
+
fields: array(AggregateFieldSchema).readonly(),
|
|
11210
|
+
filter: QueryFilterSchema.optional()
|
|
11211
|
+
}), AggregateResultSchema), method(object({
|
|
11073
11212
|
namespace: string().optional(),
|
|
11074
11213
|
collection: string(),
|
|
11075
11214
|
field: string(),
|
|
@@ -11186,6 +11325,11 @@ method(_void(), EngineInfoSchema, { auth: "admin" }), method(object({
|
|
|
11186
11325
|
collection: string(),
|
|
11187
11326
|
filter: QueryFilterSchema.optional()
|
|
11188
11327
|
}), number(), { auth: "admin" }), method(object({
|
|
11328
|
+
namespace: string().optional(),
|
|
11329
|
+
collection: string(),
|
|
11330
|
+
fields: array(AggregateFieldSchema).readonly(),
|
|
11331
|
+
filter: QueryFilterSchema.optional()
|
|
11332
|
+
}), AggregateResultSchema, { auth: "admin" }), method(object({
|
|
11189
11333
|
namespace: string().optional(),
|
|
11190
11334
|
collection: string(),
|
|
11191
11335
|
field: string(),
|
|
@@ -11802,24 +11946,6 @@ var deviceProviderCapability = {
|
|
|
11802
11946
|
})
|
|
11803
11947
|
}
|
|
11804
11948
|
};
|
|
11805
|
-
/**
|
|
11806
|
-
* Device Manager capability — hub-side singleton that unifies device persistence,
|
|
11807
|
-
* live registry access, and all management operations into a single tRPC surface.
|
|
11808
|
-
*
|
|
11809
|
-
* Replaces:
|
|
11810
|
-
* - `device-persistence` capability (persistence methods absorbed here)
|
|
11811
|
-
* - `device-management.router.ts` (deleted in Phase 2)
|
|
11812
|
-
* - `device-ops.router.ts` (compat layer — deleted; device-provider ops absorbed here)
|
|
11813
|
-
*
|
|
11814
|
-
* All device provider addons (rtsp, onvif, frigate, …) are hub-local: they may
|
|
11815
|
-
* fork into separate processes but never run on remote cluster agents. Therefore:
|
|
11816
|
-
* - No nodeId routing needed — this is a pure hub singleton.
|
|
11817
|
-
* - The hub's DeviceRegistry is the single source of truth for all live devices.
|
|
11818
|
-
* - No shadow registry or cross-node aggregation required.
|
|
11819
|
-
*
|
|
11820
|
-
* Forked workers register devices back to the hub via `ctx.devices`
|
|
11821
|
-
* (DeviceManagerApi → ctx.api.deviceManager.registerDevice), same as today.
|
|
11822
|
-
*/
|
|
11823
11949
|
/** One child-placement directive on a container's `childLayout`. Structurally
|
|
11824
11950
|
* identical to `ChildLayoutEntry` in `device-management.ts` — the cap wire
|
|
11825
11951
|
* shape for the same field. The child is identified by its re-sync-stable
|
|
@@ -12188,7 +12314,7 @@ method(object({
|
|
|
12188
12314
|
* it answers today and the caller filters as it already does.
|
|
12189
12315
|
*/
|
|
12190
12316
|
deviceIds: array(number()).optional()
|
|
12191
|
-
}), array(DeviceInfoSchema)), method(object({ deviceId: number() }), DeviceInfoSchema.nullable()), method(object({ parentDeviceId: number() }), array(DeviceInfoSchema)), method(object({ deviceId: number() }), object({
|
|
12317
|
+
}), array(DeviceInfoSchema)), method(object({ deviceId: number() }), DeviceInfoSchema.nullable()), method(object({ parentDeviceId: number() }), array(DeviceInfoSchema)), method(object({ parentDeviceIds: array(number()).max(256) }), record(string(), array(DeviceInfoSchema))), method(object({ deviceId: number() }), object({
|
|
12192
12318
|
mode: LinkedDevicesModeSchema,
|
|
12193
12319
|
devices: array(LinkedDeviceSchema)
|
|
12194
12320
|
})), method(object({ deviceIds: array(number()) }), array(LinkedDevicesForDeviceSchema)), method(object({ deviceId: number() }), array(StreamSourceEntrySchema$1)), method(object({ deviceId: number() }), array(ConfigEntrySchema)), method(object({ deviceId: number() }), ConfigUISchemaOutput), method(object({
|
|
@@ -12912,6 +13038,59 @@ method(LlmGenerateBaseInputSchema, LlmGenerateResultSchema, { kind: "mutation" }
|
|
|
12912
13038
|
kind: "mutation",
|
|
12913
13039
|
auth: "admin"
|
|
12914
13040
|
});
|
|
13041
|
+
/**
|
|
13042
|
+
* `log-channels` — the capability an addon DECLARES its diagnostic channels
|
|
13043
|
+
* through. It stores nothing.
|
|
13044
|
+
*
|
|
13045
|
+
* ## Why a capability at all, and why this shape
|
|
13046
|
+
*
|
|
13047
|
+
* Which channels exist is knowledge only the addon has: `stream-broker` knows
|
|
13048
|
+
* webrtc/ICE/RTP, `provider-reolink` knows baichuan/handshake. A central list
|
|
13049
|
+
* maintained by hand rots at the first addition and rots INVISIBLY — nothing
|
|
13050
|
+
* fails, an operator just never sees the channel somebody added. So the list
|
|
13051
|
+
* is assembled from declarations at runtime.
|
|
13052
|
+
*
|
|
13053
|
+
* The shape is copied from `log-destination.cap.ts`, which already does
|
|
13054
|
+
* exactly this job: `mode: 'collection'`, `internal: true`,
|
|
13055
|
+
* `mount: { kind: 'skip' }` — no tRPC route, no generated hooks — while
|
|
13056
|
+
* `addons.listCapabilityProviders` still enumerates it, and the hub's
|
|
13057
|
+
* `CapabilityRegistry` still holds an RPC proxy per provider so a forked
|
|
13058
|
+
* runner's declarations reach hub-main over the transport that already exists.
|
|
13059
|
+
* No new UDS message, no second registry.
|
|
13060
|
+
*
|
|
13061
|
+
* ## What it deliberately does NOT own
|
|
13062
|
+
*
|
|
13063
|
+
* The VALUES — which channel is armed, for which cameras, until when — live in
|
|
13064
|
+
* ONE place: the logging settings document on the `system` cap
|
|
13065
|
+
* (`getLoggingSettings` / `setLoggingSettings`). Two authorities over the same
|
|
13066
|
+
* value is the defect the plan behind this work exists to remove, and
|
|
13067
|
+
* `setRequestCensus` was retired (D245) rather than allowed to be a second
|
|
13068
|
+
* one. {@link logChannelsCapability} therefore has no getter for a level, no
|
|
13069
|
+
* setter for a window and no persistence of any kind.
|
|
13070
|
+
*
|
|
13071
|
+
* ## Why `apply` is here even so
|
|
13072
|
+
*
|
|
13073
|
+
* The gate lives in the addon's PROCESS; the document lives in hub-main. Some
|
|
13074
|
+
* seam has to carry the value from the authority to the mirror, and a channel
|
|
13075
|
+
* that cannot be reached is precisely the dead knob this whole slice exists to
|
|
13076
|
+
* make impossible (D62 — `audioThresholdDbfs`, the HA entities with no source).
|
|
13077
|
+
* `apply` is that seam and nothing more: it writes an in-memory mirror, it
|
|
13078
|
+
* persists nothing, it is never the source of a value, and it is called only
|
|
13079
|
+
* with a set the hub actually read (D49 — a read that fails does not call it
|
|
13080
|
+
* at all, so no channel is silently disarmed by a bad read).
|
|
13081
|
+
*/
|
|
13082
|
+
/** What `apply` reports back — enough to log, not enough to be a second state. */
|
|
13083
|
+
var LogChannelApplyResultSchema = object({
|
|
13084
|
+
/** How many declared channels are armed in this process after the call. */
|
|
13085
|
+
armed: number().int().min(0),
|
|
13086
|
+
/**
|
|
13087
|
+
* Names the document armed that this process does not declare. Reported
|
|
13088
|
+
* rather than swallowed: a name here is either a typo or an addon that has
|
|
13089
|
+
* not booted, and both deserve a line instead of silence.
|
|
13090
|
+
*/
|
|
13091
|
+
unknown: array(string()).readonly()
|
|
13092
|
+
});
|
|
13093
|
+
method(_void(), array(LogChannelDescriptorSchema).readonly()), method(object({ windows: array(LogChannelWindowSchema).readonly() }), LogChannelApplyResultSchema, { kind: "mutation" });
|
|
12915
13094
|
var LogLevelSchema = _enum([
|
|
12916
13095
|
"debug",
|
|
12917
13096
|
"info",
|
|
@@ -26313,17 +26492,60 @@ var SetSiteLocationInputSchema = object({
|
|
|
26313
26492
|
longitude: number().min(-180).max(180)
|
|
26314
26493
|
}).nullable();
|
|
26315
26494
|
/**
|
|
26316
|
-
*
|
|
26495
|
+
* The TRANSPORT a call arrived on.
|
|
26496
|
+
*
|
|
26497
|
+
* Every counted call carries exactly one of these, and `unknown` is a PLANE
|
|
26498
|
+
* rather than a gap: a plane that cannot attribute a call declares it here, so
|
|
26499
|
+
* the call lands in a named bucket instead of vanishing. `planes` summing to
|
|
26500
|
+
* `procedureCalls` is what makes "the sum of the planes explains the total"
|
|
26501
|
+
* checkable rather than asserted.
|
|
26502
|
+
*
|
|
26503
|
+
* - `http` — the Fastify tRPC plugin (`/trpc/*`), one context per request.
|
|
26504
|
+
* - `ws` — `applyWSSHandler`, counted per OPERATION rather than per
|
|
26505
|
+
* connection; the viewer talks to the hub over `wsLink`
|
|
26506
|
+
* exclusively, so this is the plane the HTTP census could not see.
|
|
26507
|
+
* - `mesh` — the in-process `$core-caps` bridge (`createCaller`), which
|
|
26508
|
+
* never touches a socket and therefore never touched a census.
|
|
26509
|
+
* - `unknown` — counted, plane undecidable. No hook produces it today, and
|
|
26510
|
+
* that is exactly what its `0` asserts: every plane the hub has can name
|
|
26511
|
+
* itself. It is an output bucket, never a knob — a call that arrives on a
|
|
26512
|
+
* plane nobody instrumented lands here instead of vanishing from the total.
|
|
26513
|
+
*/
|
|
26514
|
+
var TransportPlaneSchema = _enum([
|
|
26515
|
+
"http",
|
|
26516
|
+
"ws",
|
|
26517
|
+
"mesh",
|
|
26518
|
+
"unknown"
|
|
26519
|
+
]);
|
|
26520
|
+
/**
|
|
26521
|
+
* Calls per plane. Every key is always present, `0` included — an absent plane
|
|
26522
|
+
* reads as "not instrumented", which is the one thing this census must never
|
|
26523
|
+
* make an operator wonder about.
|
|
26524
|
+
*/
|
|
26525
|
+
var TransportPlaneCountsSchema = object({
|
|
26526
|
+
http: number(),
|
|
26527
|
+
ws: number(),
|
|
26528
|
+
mesh: number(),
|
|
26529
|
+
unknown: number()
|
|
26530
|
+
});
|
|
26531
|
+
/**
|
|
26532
|
+
* One `(plane, procedure, user-agent, ip, principal)` tuple of the transport
|
|
26317
26533
|
* census. `principal` is the DERIVED identity (`apocaliss92 (admin)`,
|
|
26318
26534
|
* `scoped:1a2b3c4d (scoped-token)`, `anonymous`) that the tRPC error log
|
|
26319
26535
|
* already prints - never a token, never an `Authorization` header.
|
|
26536
|
+
*
|
|
26537
|
+
* `subscriptions` is counted APART from `calls`: a subscription is opened once
|
|
26538
|
+
* and lives for hours, so folding it into a call count makes one long-lived
|
|
26539
|
+
* stream look like a storm.
|
|
26320
26540
|
*/
|
|
26321
26541
|
var RequestCensusGroupSchema = object({
|
|
26542
|
+
plane: TransportPlaneSchema,
|
|
26322
26543
|
procedure: string(),
|
|
26323
26544
|
userAgent: string(),
|
|
26324
26545
|
ip: string(),
|
|
26325
26546
|
principal: string(),
|
|
26326
26547
|
calls: number(),
|
|
26548
|
+
subscriptions: number(),
|
|
26327
26549
|
perMin: number()
|
|
26328
26550
|
});
|
|
26329
26551
|
/**
|
|
@@ -26336,6 +26558,14 @@ var RequestCensusGroupSchema = object({
|
|
|
26336
26558
|
var RequestCensusProcedureSchema = object({
|
|
26337
26559
|
procedure: string(),
|
|
26338
26560
|
calls: number(),
|
|
26561
|
+
/**
|
|
26562
|
+
* The same total, split by transport. THIS is the row that answers the
|
|
26563
|
+
* question the census exists for: one look at `deviceManager.listAll` says
|
|
26564
|
+
* which plane carried the 4 960, without joining two log lines by eye.
|
|
26565
|
+
*/
|
|
26566
|
+
planes: TransportPlaneCountsSchema,
|
|
26567
|
+
/** Subscription STARTS on this procedure. Never folded into `calls`. */
|
|
26568
|
+
subscriptions: number(),
|
|
26339
26569
|
perMin: number()
|
|
26340
26570
|
});
|
|
26341
26571
|
/**
|
|
@@ -26363,14 +26593,45 @@ var RequestCensusStatusSchema = object({
|
|
|
26363
26593
|
*/
|
|
26364
26594
|
procedureCalls: number(),
|
|
26365
26595
|
/**
|
|
26596
|
+
* `procedureCalls` split by transport. The four keys sum to
|
|
26597
|
+
* `procedureCalls` by construction - {@link RequestCensusSnapshotSchema}'s
|
|
26598
|
+
* `planesExplainTotal` is that identity, checked rather than assumed.
|
|
26599
|
+
*/
|
|
26600
|
+
planes: TransportPlaneCountsSchema,
|
|
26601
|
+
/**
|
|
26602
|
+
* True iff `planes` sums to `procedureCalls`. False means a call was counted
|
|
26603
|
+
* on no plane at all - which is a RESULT (a plane is missing from the
|
|
26604
|
+
* instrument), not a failure, and it has to be visible to be read as one.
|
|
26605
|
+
*/
|
|
26606
|
+
planesExplainTotal: boolean(),
|
|
26607
|
+
/**
|
|
26366
26608
|
* tRPC WebSocket connections opened during the window. NOT calls - the WS
|
|
26367
|
-
*
|
|
26368
|
-
*
|
|
26609
|
+
* adapter resolves one context per connection - kept because a plane's call
|
|
26610
|
+
* count of zero against 37 open connections says something different from a
|
|
26611
|
+
* plane with no connections at all.
|
|
26369
26612
|
*/
|
|
26370
26613
|
wsConnections: number(),
|
|
26614
|
+
/**
|
|
26615
|
+
* Client frames the WS plane looked at. `wsMessages` far above
|
|
26616
|
+
* `planes.ws + subscriptions` means most traffic is not operations
|
|
26617
|
+
* (keepalives, connection params) - which is itself an answer.
|
|
26618
|
+
*/
|
|
26619
|
+
wsMessages: number(),
|
|
26620
|
+
/**
|
|
26621
|
+
* Subscription STARTS across every plane, excluded from `procedureCalls` on
|
|
26622
|
+
* purpose: one live-events stream opened at boot and held for six hours is
|
|
26623
|
+
* one subscription, and counting it as a call would let a quiet plane
|
|
26624
|
+
* masquerade as the storm.
|
|
26625
|
+
*/
|
|
26626
|
+
subscriptions: number(),
|
|
26627
|
+
/** `subscription.stop` frames. Starts minus stops is what is still open. */
|
|
26628
|
+
subscriptionStops: number(),
|
|
26371
26629
|
distinctGroups: number(),
|
|
26372
|
-
/**
|
|
26373
|
-
*
|
|
26630
|
+
/**
|
|
26631
|
+
* Operations counted in the totals whose CALLER attribution was shed at the
|
|
26632
|
+
* cardinality bound. Unrelated to the `unknown` PLANE: these calls know
|
|
26633
|
+
* which transport they arrived on, they just lost their group row.
|
|
26634
|
+
*/
|
|
26374
26635
|
unattributedCalls: number(),
|
|
26375
26636
|
procedures: array(RequestCensusProcedureSchema).readonly(),
|
|
26376
26637
|
groups: array(RequestCensusGroupSchema).readonly()
|
|
@@ -26393,10 +26654,11 @@ var DiagnosticIdSchema = _enum(["request-census"]);
|
|
|
26393
26654
|
* The layers of the level hierarchy, general → specific. The most specific
|
|
26394
26655
|
* layer that carries an explicit value wins.
|
|
26395
26656
|
*
|
|
26396
|
-
* `component`
|
|
26397
|
-
*
|
|
26398
|
-
*
|
|
26399
|
-
*
|
|
26657
|
+
* `component` became RESOLVABLE on 2026-08-27: a component is a declared log
|
|
26658
|
+
* CHANNEL (`stream-broker.webrtc`, `provider-reolink.baichuan`), named by
|
|
26659
|
+
* `scopeComponent`. It was declared-but-dark in the first slice precisely so
|
|
26660
|
+
* that turning it on would not force every consumer of this document to widen
|
|
26661
|
+
* a `levelSource` enum — which is what has now not happened.
|
|
26400
26662
|
*/
|
|
26401
26663
|
var LoggingScopeKindSchema = _enum([
|
|
26402
26664
|
"cluster",
|
|
@@ -26423,6 +26685,14 @@ var LoggingLevelLayerSchema = object({
|
|
|
26423
26685
|
scope: LoggingScopeKindSchema,
|
|
26424
26686
|
/** The node this layer speaks for; `null` on the cluster layer. */
|
|
26425
26687
|
nodeId: string().nullable(),
|
|
26688
|
+
/**
|
|
26689
|
+
* The declared channel this layer speaks for; `null` on every layer but
|
|
26690
|
+
* `component`. Never folded into `nodeId`: a component level is CLUSTER-WIDE
|
|
26691
|
+
* by design — the convention this repo settled on is one orchestrator-wide
|
|
26692
|
+
* setting, never per node (D52) — so a component layer that carried a node
|
|
26693
|
+
* would invite a per-node copy of a value that has no per-node meaning.
|
|
26694
|
+
*/
|
|
26695
|
+
component: string().nullable(),
|
|
26426
26696
|
/** Explicitly set here, or `null` when this layer inherits. */
|
|
26427
26697
|
level: LogLevelSchema$1.nullable()
|
|
26428
26698
|
});
|
|
@@ -26464,6 +26734,49 @@ var DiagnosticWindowPatchSchema = object({
|
|
|
26464
26734
|
reportEveryMs: number().int().positive().optional()
|
|
26465
26735
|
});
|
|
26466
26736
|
/**
|
|
26737
|
+
* A channel ARMED, as the document reports it.
|
|
26738
|
+
*
|
|
26739
|
+
* `armMs` is not echoed back: what an operator needs to see is the deadline
|
|
26740
|
+
* and the time left, because a diagnostic left running is itself an incident
|
|
26741
|
+
* and "armed for 10 minutes" said an hour ago is not an answer.
|
|
26742
|
+
*/
|
|
26743
|
+
var LogChannelWindowStateSchema = object({
|
|
26744
|
+
channel: string(),
|
|
26745
|
+
armed: boolean(),
|
|
26746
|
+
/** Epoch ms the window closes at. 0 when disarmed. */
|
|
26747
|
+
armedUntilMs: number(),
|
|
26748
|
+
/** Ms left before it expires on its own. 0 when disarmed. */
|
|
26749
|
+
remainingMs: number(),
|
|
26750
|
+
/**
|
|
26751
|
+
* The cameras it is narrowed to, or `null` for every camera.
|
|
26752
|
+
*
|
|
26753
|
+
* A channel declared `perDevice: false` can only ever report `null` here:
|
|
26754
|
+
* its lines do not carry `tags: { deviceId }`, so narrowing them would
|
|
26755
|
+
* produce a filter that silently matches nothing. The server REFUSES such a
|
|
26756
|
+
* patch rather than quietly widening it — ignoring the request would teach
|
|
26757
|
+
* the operator that per-camera filtering works on that channel when it does
|
|
26758
|
+
* not.
|
|
26759
|
+
*/
|
|
26760
|
+
deviceIds: array(number().int()).readonly().nullable()
|
|
26761
|
+
});
|
|
26762
|
+
/**
|
|
26763
|
+
* `armMs: 0` DISARMS. Same grammar as {@link DiagnosticWindowPatchSchema}, and
|
|
26764
|
+
* for the same reason: a channel is a window with a deadline, never a switch.
|
|
26765
|
+
*/
|
|
26766
|
+
var LogChannelWindowPatchSchema = object({
|
|
26767
|
+
channel: string().min(1),
|
|
26768
|
+
armMs: number().int().min(0),
|
|
26769
|
+
/**
|
|
26770
|
+
* Narrow to these numeric device ids. Absent or `null` = every camera.
|
|
26771
|
+
*
|
|
26772
|
+
* Numeric because the repo's own rule makes it possible: every log line
|
|
26773
|
+
* about a device carries `tags: { deviceId }` with the numeric id. That rule
|
|
26774
|
+
* was paid for with a 22% thumbnail gap and a 3-hour media blackout both
|
|
26775
|
+
* diagnosed by hand, and this is the first thing that collects on it.
|
|
26776
|
+
*/
|
|
26777
|
+
deviceIds: array(number().int()).readonly().nullable().optional()
|
|
26778
|
+
});
|
|
26779
|
+
/**
|
|
26467
26780
|
* A PATCH, and patches MERGE.
|
|
26468
26781
|
*
|
|
26469
26782
|
* A field absent from the patch is left exactly as it was — arming a
|
|
@@ -26482,7 +26795,14 @@ var LoggingSettingsPatchSchema = object({
|
|
|
26482
26795
|
* Only the diagnostics NAMED here change. An armed window that is not listed
|
|
26483
26796
|
* keeps running — a patch is never a full replacement.
|
|
26484
26797
|
*/
|
|
26485
|
-
diagnostics: array(DiagnosticWindowPatchSchema).readonly().optional()
|
|
26798
|
+
diagnostics: array(DiagnosticWindowPatchSchema).readonly().optional(),
|
|
26799
|
+
/**
|
|
26800
|
+
* Only the channels NAMED here change. An armed channel that is not listed
|
|
26801
|
+
* keeps running — same rule as `diagnostics`, because a patch that silently
|
|
26802
|
+
* disarmed the channels it did not mention would make the Levels page and
|
|
26803
|
+
* the Diagnostics page fight over the same value.
|
|
26804
|
+
*/
|
|
26805
|
+
channels: array(LogChannelWindowPatchSchema).readonly().optional()
|
|
26486
26806
|
});
|
|
26487
26807
|
/**
|
|
26488
26808
|
* Which LAYER of the hierarchy is addressed. Absent = the cluster layer.
|
|
@@ -26495,9 +26815,22 @@ var LoggingSettingsPatchSchema = object({
|
|
|
26495
26815
|
* authority over the whole hierarchy and answers for every layer, so the
|
|
26496
26816
|
* layer selector needs a name the transport does not already own.
|
|
26497
26817
|
*/
|
|
26498
|
-
var GetLoggingSettingsInputSchema = object({
|
|
26818
|
+
var GetLoggingSettingsInputSchema = object({
|
|
26819
|
+
scopeNodeId: string().optional(),
|
|
26820
|
+
/**
|
|
26821
|
+
* The declared CHANNEL this document is addressed at, when the caller wants
|
|
26822
|
+
* the `component` layer. Absent = the node/cluster hierarchy only.
|
|
26823
|
+
*
|
|
26824
|
+
* Naming it separately rather than overloading `scopeNodeId` keeps the two
|
|
26825
|
+
* axes from collapsing: a component level is cluster-wide, a node level is
|
|
26826
|
+
* not, and one selector for both would make "which of these two did I just
|
|
26827
|
+
* set" unanswerable — the exact ambiguity `explicit` exists to remove.
|
|
26828
|
+
*/
|
|
26829
|
+
scopeComponent: string().optional()
|
|
26830
|
+
});
|
|
26499
26831
|
var SetLoggingSettingsInputSchema = object({
|
|
26500
26832
|
scopeNodeId: string().optional(),
|
|
26833
|
+
scopeComponent: string().optional(),
|
|
26501
26834
|
patch: LoggingSettingsPatchSchema
|
|
26502
26835
|
});
|
|
26503
26836
|
/**
|
|
@@ -26512,9 +26845,20 @@ var SetLoggingSettingsInputSchema = object({
|
|
|
26512
26845
|
var LoggingSettingsStateSchema = object({
|
|
26513
26846
|
/** The layer this document was read at. `null` = the cluster layer. */
|
|
26514
26847
|
scopeNodeId: string().nullable(),
|
|
26848
|
+
/** The channel this document was read at. `null` = no component layer. */
|
|
26849
|
+
scopeComponent: string().nullable(),
|
|
26515
26850
|
effective: LoggingEffectiveSchema,
|
|
26516
26851
|
explicit: LoggingExplicitSchema,
|
|
26517
26852
|
activeWindows: array(DiagnosticWindowSchema).readonly(),
|
|
26853
|
+
/**
|
|
26854
|
+
* Every channel the cluster's addons DECLARE, gathered from the
|
|
26855
|
+
* `log-channels` providers. Not stored anywhere: assembled per read, so a
|
|
26856
|
+
* channel added by a redeployed addon appears without anybody editing a
|
|
26857
|
+
* list, and a channel whose addon is gone stops being offered.
|
|
26858
|
+
*/
|
|
26859
|
+
channels: array(LogChannelDescriptorSchema).readonly(),
|
|
26860
|
+
/** The channels ARMED right now, each with its deadline. */
|
|
26861
|
+
activeChannels: array(LogChannelWindowStateSchema).readonly(),
|
|
26518
26862
|
persisted: boolean()
|
|
26519
26863
|
});
|
|
26520
26864
|
method(_void(), FeatureManifestSchema), method(_void(), HealthStatusSchema), method(_void(), FeatureManifestSchema), method(_void(), array(NetworkAddressSchema).readonly()), method(_void(), unknown().nullable(), { auth: "admin" }), method(record(string(), unknown()), _null(), {
|
|
@@ -28501,6 +28845,12 @@ Object.freeze({
|
|
|
28501
28845
|
addonId: null,
|
|
28502
28846
|
access: "view"
|
|
28503
28847
|
},
|
|
28848
|
+
"dataStoreProvider.aggregate": {
|
|
28849
|
+
capName: "data-store-provider",
|
|
28850
|
+
capScope: "system",
|
|
28851
|
+
addonId: null,
|
|
28852
|
+
access: "view"
|
|
28853
|
+
},
|
|
28504
28854
|
"dataStoreProvider.count": {
|
|
28505
28855
|
capName: "data-store-provider",
|
|
28506
28856
|
capScope: "system",
|
|
@@ -28915,6 +29265,12 @@ Object.freeze({
|
|
|
28915
29265
|
addonId: null,
|
|
28916
29266
|
access: "view"
|
|
28917
29267
|
},
|
|
29268
|
+
"deviceManager.getChildrenBatch": {
|
|
29269
|
+
capName: "device-manager",
|
|
29270
|
+
capScope: "system",
|
|
29271
|
+
addonId: null,
|
|
29272
|
+
access: "view"
|
|
29273
|
+
},
|
|
28918
29274
|
"deviceManager.getConfigSchema": {
|
|
28919
29275
|
capName: "device-manager",
|
|
28920
29276
|
capScope: "system",
|
|
@@ -29965,6 +30321,18 @@ Object.freeze({
|
|
|
29965
30321
|
addonId: null,
|
|
29966
30322
|
access: "create"
|
|
29967
30323
|
},
|
|
30324
|
+
"logChannels.apply": {
|
|
30325
|
+
capName: "log-channels",
|
|
30326
|
+
capScope: "system",
|
|
30327
|
+
addonId: null,
|
|
30328
|
+
access: "create"
|
|
30329
|
+
},
|
|
30330
|
+
"logChannels.list": {
|
|
30331
|
+
capName: "log-channels",
|
|
30332
|
+
capScope: "system",
|
|
30333
|
+
addonId: null,
|
|
30334
|
+
access: "view"
|
|
30335
|
+
},
|
|
29968
30336
|
"logDestination.query": {
|
|
29969
30337
|
capName: "log-destination",
|
|
29970
30338
|
capScope: "system",
|
|
@@ -32119,6 +32487,12 @@ Object.freeze({
|
|
|
32119
32487
|
addonId: null,
|
|
32120
32488
|
access: "create"
|
|
32121
32489
|
},
|
|
32490
|
+
"settingsStore.aggregate": {
|
|
32491
|
+
capName: "settings-store",
|
|
32492
|
+
capScope: "system",
|
|
32493
|
+
addonId: null,
|
|
32494
|
+
access: "view"
|
|
32495
|
+
},
|
|
32122
32496
|
"settingsStore.count": {
|
|
32123
32497
|
capName: "settings-store",
|
|
32124
32498
|
capScope: "system",
|
|
@@ -33698,6 +34072,11 @@ Object.freeze({
|
|
|
33698
34072
|
form: "single",
|
|
33699
34073
|
optional: false
|
|
33700
34074
|
}],
|
|
34075
|
+
"deviceManager.getChildrenBatch": [{
|
|
34076
|
+
name: "parentDeviceIds",
|
|
34077
|
+
form: "array",
|
|
34078
|
+
optional: false
|
|
34079
|
+
}],
|
|
33701
34080
|
"deviceManager.getConfigSchema": [{
|
|
33702
34081
|
name: "deviceId",
|
|
33703
34082
|
form: "single",
|