@camstack/addon-agent-ui 1.2.49 → 1.2.50
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 +219 -5
- package/package.json +1 -1
package/dist/addon.js
CHANGED
|
@@ -8021,6 +8021,20 @@ var RelocateJobSchema = object({
|
|
|
8021
8021
|
* in its row, not in its name, so `MediaRelocateEngine` never reconciles one.
|
|
8022
8022
|
*/
|
|
8023
8023
|
rowsReconciled: number().int().nonnegative().optional(),
|
|
8024
|
+
/**
|
|
8025
|
+
* Rows this run FORGOT because the file they name is not on disk.
|
|
8026
|
+
*
|
|
8027
|
+
* The mover derived the path from the row's own fields and `stat`ed it; an
|
|
8028
|
+
* ENOENT there is a per-path confirmation that the segment is gone (D296),
|
|
8029
|
+
* and the durable row is dropped through the same channel eviction uses. It
|
|
8030
|
+
* is reported for the same reason `rowsReconciled` is: this is a durable
|
|
8031
|
+
* mutation nobody asked for, and a migration that quietly erases hour rows is
|
|
8032
|
+
* the same failure as one that quietly skips them (D295).
|
|
8033
|
+
*
|
|
8034
|
+
* The production drain of 2026-08-30 would have reported 11 074 here — the
|
|
8035
|
+
* ledger claimed 5.65 GB of footage that no longer existed.
|
|
8036
|
+
*/
|
|
8037
|
+
rowsForgotten: number().int().nonnegative().optional(),
|
|
8024
8038
|
startedAt: number(),
|
|
8025
8039
|
finishedAt: number().nullable(),
|
|
8026
8040
|
error: string().nullable()
|
|
@@ -8384,6 +8398,91 @@ var RelocateResidueSchema = object({
|
|
|
8384
8398
|
segments: number().int().nonnegative(),
|
|
8385
8399
|
bytes: number().int().nonnegative()
|
|
8386
8400
|
}).nullable();
|
|
8401
|
+
/**
|
|
8402
|
+
* Ask one location whether its durable hour rows describe the disk — the walk
|
|
8403
|
+
* (D319).
|
|
8404
|
+
*
|
|
8405
|
+
* `apply` DEFAULTS TO FALSE and that default is the product: the operator's
|
|
8406
|
+
* missing tool is the question, and the dry run is how they sanity-check the
|
|
8407
|
+
* destructive run before authorising it.
|
|
8408
|
+
*/
|
|
8409
|
+
var LedgerWalkInputSchema = object({
|
|
8410
|
+
locationId: string().min(1),
|
|
8411
|
+
/** Forget the confirmed-absent rows, rather than only counting them. */
|
|
8412
|
+
apply: boolean().optional(),
|
|
8413
|
+
/** Narrow to one camera. */
|
|
8414
|
+
deviceId: number().int().positive().optional(),
|
|
8415
|
+
/** Narrow to these recording profiles; empty/absent = every profile. */
|
|
8416
|
+
profiles: array(string().min(1)).optional()
|
|
8417
|
+
});
|
|
8418
|
+
/** Why a whole walk did nothing. Every one leaves the ledger untouched. */
|
|
8419
|
+
var LedgerWalkRefusalSchema = _enum([
|
|
8420
|
+
"location-unknown",
|
|
8421
|
+
"source-writable",
|
|
8422
|
+
"no-ledger",
|
|
8423
|
+
"archive-unreadable",
|
|
8424
|
+
"anchor-absent",
|
|
8425
|
+
"anchor-unreadable",
|
|
8426
|
+
"anchor-moved"
|
|
8427
|
+
]);
|
|
8428
|
+
_enum([
|
|
8429
|
+
"live-tail",
|
|
8430
|
+
"listing-error",
|
|
8431
|
+
"path-mismatch",
|
|
8432
|
+
"durable-refused"
|
|
8433
|
+
]);
|
|
8434
|
+
/** Every skip reason, always present, always a number — so a reason that never
|
|
8435
|
+
* fired reports as zero rather than absent and the report shape is constant
|
|
8436
|
+
* between passes. Spelled out rather than `z.record` for exactly that. */
|
|
8437
|
+
var LedgerWalkSkipCountsSchema = object({
|
|
8438
|
+
"live-tail": number().int().nonnegative(),
|
|
8439
|
+
"listing-error": number().int().nonnegative(),
|
|
8440
|
+
"path-mismatch": number().int().nonnegative(),
|
|
8441
|
+
"durable-refused": number().int().nonnegative()
|
|
8442
|
+
});
|
|
8443
|
+
/** One camera's share of a walk, so a report names cameras and not rows. */
|
|
8444
|
+
var LedgerWalkDeviceReportSchema = object({
|
|
8445
|
+
deviceId: number().int(),
|
|
8446
|
+
hoursWalked: number().int().nonnegative(),
|
|
8447
|
+
hoursMissing: number().int().nonnegative(),
|
|
8448
|
+
ghostSegments: number().int().nonnegative(),
|
|
8449
|
+
ghostBytes: number().int().nonnegative(),
|
|
8450
|
+
forgottenSegments: number().int().nonnegative(),
|
|
8451
|
+
orphanFiles: number().int().nonnegative()
|
|
8452
|
+
});
|
|
8453
|
+
/**
|
|
8454
|
+
* What one walk claimed, listed, found and (only when armed) forgot.
|
|
8455
|
+
*
|
|
8456
|
+
* `archiveSegments` is the **M** and `segmentsClaimed` the **N** (D295), so a
|
|
8457
|
+
* walk that saw a fraction of the location is visible in its own report rather
|
|
8458
|
+
* than in the absence of one.
|
|
8459
|
+
*/
|
|
8460
|
+
var LedgerWalkReportSchema = object({
|
|
8461
|
+
locationId: string(),
|
|
8462
|
+
applied: boolean(),
|
|
8463
|
+
refused: LedgerWalkRefusalSchema.nullable(),
|
|
8464
|
+
archiveSegments: number().int().nonnegative().nullable(),
|
|
8465
|
+
archiveBytes: number().int().nonnegative().nullable(),
|
|
8466
|
+
hoursClaimed: number().int().nonnegative(),
|
|
8467
|
+
hoursWalked: number().int().nonnegative(),
|
|
8468
|
+
hoursMissing: number().int().nonnegative(),
|
|
8469
|
+
/** `readdir` calls issued — the cost, stated in the unit that is paid. */
|
|
8470
|
+
listings: number().int().nonnegative(),
|
|
8471
|
+
segmentsClaimed: number().int().nonnegative(),
|
|
8472
|
+
ghostSegments: number().int().nonnegative(),
|
|
8473
|
+
ghostBytes: number().int().nonnegative(),
|
|
8474
|
+
ghostHoursWhole: number().int().nonnegative(),
|
|
8475
|
+
forgottenSegments: number().int().nonnegative(),
|
|
8476
|
+
forgottenBytes: number().int().nonnegative(),
|
|
8477
|
+
/** Files under a claimed hour that no durable row names. Never deleted. */
|
|
8478
|
+
orphanFiles: number().int().nonnegative(),
|
|
8479
|
+
orphanSample: array(string()).readonly(),
|
|
8480
|
+
hoursSkipped: number().int().nonnegative(),
|
|
8481
|
+
skippedByReason: LedgerWalkSkipCountsSchema,
|
|
8482
|
+
/** The walk stopped at its per-pass hour bound with claims unwalked. */
|
|
8483
|
+
bounded: boolean(),
|
|
8484
|
+
byDevice: array(LedgerWalkDeviceReportSchema).readonly()
|
|
8485
|
+
});
|
|
8387
8486
|
/** How many rows a media pass would still act on against a given target — the
|
|
8388
8487
|
* media lane's denominator AND its residue, from ONE derivation so the two can
|
|
8389
8488
|
* never disagree. `null` = the count could not be taken. */
|
|
@@ -18657,13 +18756,15 @@ var ListGroupsPageSchema = object({
|
|
|
18657
18756
|
groups: array(AnalyticsGroupRecordSchema).readonly(),
|
|
18658
18757
|
nextCursor: string().nullable()
|
|
18659
18758
|
});
|
|
18759
|
+
var KEY_EVENTS_DEFAULT_LIMIT = 50;
|
|
18760
|
+
var KEY_EVENTS_MAX_LIMIT = 200;
|
|
18660
18761
|
var KeyEventQueryInput = object({
|
|
18661
18762
|
deviceId: number(),
|
|
18662
18763
|
/** Window lower bound (track firstSeen ≥ since). */
|
|
18663
18764
|
since: number(),
|
|
18664
18765
|
/** Window upper bound (track firstSeen ≤ until). */
|
|
18665
18766
|
until: number(),
|
|
18666
|
-
limit: number().int().min(1).max(
|
|
18767
|
+
limit: number().int().min(1).max(KEY_EVENTS_MAX_LIMIT).default(KEY_EVENTS_DEFAULT_LIMIT),
|
|
18667
18768
|
/** Drop tracks scoring below this importance. */
|
|
18668
18769
|
minImportance: number().min(0).max(1).optional(),
|
|
18669
18770
|
/** Restrict to a single class (e.g. 'person'). */
|
|
@@ -18685,6 +18786,32 @@ var KeyEventSchema = object({
|
|
|
18685
18786
|
...TrackFlagFields,
|
|
18686
18787
|
...TrackRetrainFields
|
|
18687
18788
|
});
|
|
18789
|
+
/** `getKeyEvents`' window and filters, asked of a SET of cameras at once. */
|
|
18790
|
+
var KeyEventBatchQueryInput = object({
|
|
18791
|
+
deviceIds: array(number()).min(1).max(200),
|
|
18792
|
+
since: number(),
|
|
18793
|
+
until: number(),
|
|
18794
|
+
/** Applied PER CAMERA, exactly as `getKeyEvents.limit` is — never a total
|
|
18795
|
+
* across the set, which would let a busy camera starve a quiet one of its
|
|
18796
|
+
* rows and change what the merged feed contains. */
|
|
18797
|
+
limit: number().int().min(1).max(KEY_EVENTS_MAX_LIMIT).default(KEY_EVENTS_DEFAULT_LIMIT),
|
|
18798
|
+
minImportance: number().min(0).max(1).optional(),
|
|
18799
|
+
classFilter: string().optional()
|
|
18800
|
+
});
|
|
18801
|
+
/**
|
|
18802
|
+
* One camera's key events in a batch answer.
|
|
18803
|
+
*
|
|
18804
|
+
* The row exists for every requested id. `getKeyEvents` degrades to `[]` on
|
|
18805
|
+
* error rather than throwing, so a camera whose store read failed and one with
|
|
18806
|
+
* no events in the window were ALREADY indistinguishable per camera — the
|
|
18807
|
+
* batch does not make that worse, and the row keeps the deviceId the single
|
|
18808
|
+
* method's output never carried (the caller used to stamp it from the fan-out
|
|
18809
|
+
* key, which only worked because there was one query per camera).
|
|
18810
|
+
*/
|
|
18811
|
+
var KeyEventsForDeviceSchema = object({
|
|
18812
|
+
deviceId: number(),
|
|
18813
|
+
events: array(KeyEventSchema).readonly()
|
|
18814
|
+
});
|
|
18688
18815
|
object({
|
|
18689
18816
|
trackId: string(),
|
|
18690
18817
|
className: string(),
|
|
@@ -18954,7 +19081,7 @@ DeviceType.Camera, method(object({ deviceId: number() }), array(TrackSchema).rea
|
|
|
18954
19081
|
until: number().optional(),
|
|
18955
19082
|
kinds: array(string()).optional(),
|
|
18956
19083
|
limit: number().int().min(1).max(MAX_EVENT_QUERY_LIMIT).default(DEFAULT_EVENT_QUERY_LIMIT)
|
|
18957
|
-
}), array(SensorEventSchema).readonly()), method(KeyEventQueryInput, array(KeyEventSchema).readonly()), method(object({
|
|
19084
|
+
}), array(SensorEventSchema).readonly()), method(KeyEventQueryInput, array(KeyEventSchema).readonly()), method(KeyEventBatchQueryInput, array(KeyEventsForDeviceSchema).readonly()), method(object({
|
|
18958
19085
|
deviceId: number(),
|
|
18959
19086
|
since: number(),
|
|
18960
19087
|
until: number(),
|
|
@@ -26606,6 +26733,9 @@ method(object({
|
|
|
26606
26733
|
}), method(RelocateResidueInputSchema, RelocateResidueSchema, {
|
|
26607
26734
|
kind: "query",
|
|
26608
26735
|
auth: "admin"
|
|
26736
|
+
}), method(LedgerWalkInputSchema, LedgerWalkReportSchema, {
|
|
26737
|
+
kind: "mutation",
|
|
26738
|
+
auth: "admin"
|
|
26609
26739
|
}), method(object({ jobId: string() }), object({ cancelled: boolean() }), {
|
|
26610
26740
|
kind: "mutation",
|
|
26611
26741
|
auth: "admin"
|
|
@@ -26997,7 +27127,26 @@ var SceneMonitorStatusSchema = object({
|
|
|
26997
27127
|
monitors: array(SceneMonitorSchema),
|
|
26998
27128
|
lastFetchedAt: number()
|
|
26999
27129
|
});
|
|
27000
|
-
|
|
27130
|
+
/**
|
|
27131
|
+
* One camera's row in a `listScenesBatch` answer.
|
|
27132
|
+
*
|
|
27133
|
+
* `status` is NULLABLE and the nullability is the whole point. `scene-monitor`
|
|
27134
|
+
* is a `defaultActive` wrapper, so every camera is asked; a camera whose
|
|
27135
|
+
* provider is absent (pipeline-analytics not deployed, the post-processing node
|
|
27136
|
+
* down) cannot answer, and that is not the same fact as a camera with no scenes
|
|
27137
|
+
* configured. Fanned out per camera the difference was visible — one query
|
|
27138
|
+
* errored while the others resolved — and a batch that returned only the rows
|
|
27139
|
+
* it managed would have destroyed it, silently, by making an unreachable camera
|
|
27140
|
+
* indistinguishable from one that answered `monitors: []`.
|
|
27141
|
+
*
|
|
27142
|
+
* So: EVERY requested deviceId gets a row. `status: null` means "this camera
|
|
27143
|
+
* could not be read"; `status.monitors: []` means "read, and it has none".
|
|
27144
|
+
*/
|
|
27145
|
+
var SceneMonitorStatusForDeviceSchema = object({
|
|
27146
|
+
deviceId: number(),
|
|
27147
|
+
status: SceneMonitorStatusSchema.nullable()
|
|
27148
|
+
});
|
|
27149
|
+
DeviceType.Camera, method(object({ deviceId: number() }), SceneMonitorStatusSchema), method(object({ deviceIds: array(number()).min(1).max(200) }), array(SceneMonitorStatusForDeviceSchema).readonly()), method(object({
|
|
27001
27150
|
deviceId: number(),
|
|
27002
27151
|
label: string(),
|
|
27003
27152
|
roi: MaskRectShapeSchema,
|
|
@@ -28321,6 +28470,27 @@ var CameraOccupancySnapshotSchema = object({
|
|
|
28321
28470
|
stationaryObjects: array(StationaryObjectSchema).readonly().optional()
|
|
28322
28471
|
});
|
|
28323
28472
|
/**
|
|
28473
|
+
* One camera's row in a `getCurrentSnapshotBatch` answer.
|
|
28474
|
+
*
|
|
28475
|
+
* THREE outcomes, and the single-camera method could only express two of them
|
|
28476
|
+
* because `snapshot: null` was already spoken for:
|
|
28477
|
+
*
|
|
28478
|
+
* - `read: 'read'`, `snapshot` present — the live occupancy reading.
|
|
28479
|
+
* - `read: 'read'`, `snapshot: null` — read, and this camera has no reading
|
|
28480
|
+
* yet: no frame since boot, and no parked-object registry to hydrate from.
|
|
28481
|
+
* - `read: 'unreadable'` — the owner could not answer for this
|
|
28482
|
+
* camera. `snapshot` is null, and it does NOT mean "nothing parked here".
|
|
28483
|
+
*
|
|
28484
|
+
* Collapsing the last two is the failure this field exists to prevent: a
|
|
28485
|
+
* hydration that threw would otherwise render as an empty Stationary section,
|
|
28486
|
+
* which is a definite claim about a camera nobody could read.
|
|
28487
|
+
*/
|
|
28488
|
+
var CameraOccupancySnapshotForDeviceSchema = object({
|
|
28489
|
+
deviceId: number(),
|
|
28490
|
+
read: _enum(["read", "unreadable"]),
|
|
28491
|
+
snapshot: CameraOccupancySnapshotSchema.nullable()
|
|
28492
|
+
});
|
|
28493
|
+
/**
|
|
28324
28494
|
* Time-series resolution. The history methods return one bucket per
|
|
28325
28495
|
* step over the requested range. Smaller resolutions cost more
|
|
28326
28496
|
* memory + bandwidth; bound to discrete steps so caller cannot ask
|
|
@@ -28344,7 +28514,7 @@ var HistoryPointSchema = object({
|
|
|
28344
28514
|
/** Object count averaged over the bucket (rounded to nearest integer). */
|
|
28345
28515
|
count: number().int().nonnegative()
|
|
28346
28516
|
});
|
|
28347
|
-
DeviceType.Camera, method(object({ deviceId: number() }), CameraOccupancySnapshotSchema.nullable()), method(object({
|
|
28517
|
+
DeviceType.Camera, method(object({ deviceId: number() }), CameraOccupancySnapshotSchema.nullable()), method(object({ deviceIds: array(number()).min(1).max(200) }), array(CameraOccupancySnapshotForDeviceSchema).readonly()), method(object({
|
|
28348
28518
|
deviceId: number(),
|
|
28349
28519
|
zoneId: string(),
|
|
28350
28520
|
className: string().optional()
|
|
@@ -31649,6 +31819,12 @@ Object.freeze({
|
|
|
31649
31819
|
addonId: null,
|
|
31650
31820
|
access: "view"
|
|
31651
31821
|
},
|
|
31822
|
+
"pipelineAnalytics.getKeyEventsBatch": {
|
|
31823
|
+
capName: "pipeline-analytics",
|
|
31824
|
+
capScope: "device",
|
|
31825
|
+
addonId: null,
|
|
31826
|
+
access: "view"
|
|
31827
|
+
},
|
|
31652
31828
|
"pipelineAnalytics.getMotionEvents": {
|
|
31653
31829
|
capName: "pipeline-analytics",
|
|
31654
31830
|
capScope: "device",
|
|
@@ -32825,6 +33001,12 @@ Object.freeze({
|
|
|
32825
33001
|
addonId: null,
|
|
32826
33002
|
access: "view"
|
|
32827
33003
|
},
|
|
33004
|
+
"recording.reconcileLedgerAgainstDisk": {
|
|
33005
|
+
capName: "recording",
|
|
33006
|
+
capScope: "system",
|
|
33007
|
+
addonId: null,
|
|
33008
|
+
access: "create"
|
|
33009
|
+
},
|
|
32828
33010
|
"recording.refreshStorageLocationsForMigration": {
|
|
32829
33011
|
capName: "recording",
|
|
32830
33012
|
capScope: "system",
|
|
@@ -32951,6 +33133,12 @@ Object.freeze({
|
|
|
32951
33133
|
addonId: null,
|
|
32952
33134
|
access: "view"
|
|
32953
33135
|
},
|
|
33136
|
+
"sceneMonitor.listScenesBatch": {
|
|
33137
|
+
capName: "scene-monitor",
|
|
33138
|
+
capScope: "device",
|
|
33139
|
+
addonId: null,
|
|
33140
|
+
access: "view"
|
|
33141
|
+
},
|
|
32954
33142
|
"sceneMonitor.recheckNow": {
|
|
32955
33143
|
capName: "scene-monitor",
|
|
32956
33144
|
capScope: "device",
|
|
@@ -34307,6 +34495,12 @@ Object.freeze({
|
|
|
34307
34495
|
addonId: null,
|
|
34308
34496
|
access: "view"
|
|
34309
34497
|
},
|
|
34498
|
+
"zoneAnalytics.getCurrentSnapshotBatch": {
|
|
34499
|
+
capName: "zone-analytics",
|
|
34500
|
+
capScope: "device",
|
|
34501
|
+
addonId: null,
|
|
34502
|
+
access: "view"
|
|
34503
|
+
},
|
|
34310
34504
|
"zoneAnalytics.getUnzonedHistory": {
|
|
34311
34505
|
capName: "zone-analytics",
|
|
34312
34506
|
capScope: "device",
|
|
@@ -35311,6 +35505,11 @@ Object.freeze({
|
|
|
35311
35505
|
form: "single",
|
|
35312
35506
|
optional: false
|
|
35313
35507
|
}],
|
|
35508
|
+
"pipelineAnalytics.getKeyEventsBatch": [{
|
|
35509
|
+
name: "deviceIds",
|
|
35510
|
+
form: "array",
|
|
35511
|
+
optional: false
|
|
35512
|
+
}],
|
|
35314
35513
|
"pipelineAnalytics.getMotionEvents": [{
|
|
35315
35514
|
name: "deviceId",
|
|
35316
35515
|
form: "single",
|
|
@@ -35751,6 +35950,11 @@ Object.freeze({
|
|
|
35751
35950
|
form: "single",
|
|
35752
35951
|
optional: false
|
|
35753
35952
|
}],
|
|
35953
|
+
"recording.reconcileLedgerAgainstDisk": [{
|
|
35954
|
+
name: "deviceId",
|
|
35955
|
+
form: "single",
|
|
35956
|
+
optional: true
|
|
35957
|
+
}],
|
|
35754
35958
|
"recording.relocateFootage": [{
|
|
35755
35959
|
name: "deviceId",
|
|
35756
35960
|
form: "single",
|
|
@@ -35816,6 +36020,11 @@ Object.freeze({
|
|
|
35816
36020
|
form: "single",
|
|
35817
36021
|
optional: false
|
|
35818
36022
|
}],
|
|
36023
|
+
"sceneMonitor.listScenesBatch": [{
|
|
36024
|
+
name: "deviceIds",
|
|
36025
|
+
form: "array",
|
|
36026
|
+
optional: false
|
|
36027
|
+
}],
|
|
35819
36028
|
"sceneMonitor.recheckNow": [{
|
|
35820
36029
|
name: "deviceId",
|
|
35821
36030
|
form: "single",
|
|
@@ -36077,6 +36286,11 @@ Object.freeze({
|
|
|
36077
36286
|
form: "single",
|
|
36078
36287
|
optional: false
|
|
36079
36288
|
}],
|
|
36289
|
+
"zoneAnalytics.getCurrentSnapshotBatch": [{
|
|
36290
|
+
name: "deviceIds",
|
|
36291
|
+
form: "array",
|
|
36292
|
+
optional: false
|
|
36293
|
+
}],
|
|
36080
36294
|
"zoneAnalytics.getUnzonedHistory": [{
|
|
36081
36295
|
name: "deviceId",
|
|
36082
36296
|
form: "single",
|
|
@@ -36630,7 +36844,7 @@ var AgentUIAddon = class extends BaseAddon {
|
|
|
36630
36844
|
capability: adminUiCapability,
|
|
36631
36845
|
provider: {
|
|
36632
36846
|
getStaticDir: async () => ({ staticDir: path.resolve(__dirname) }),
|
|
36633
|
-
getVersion: async () => ({ version: "1.2.
|
|
36847
|
+
getVersion: async () => ({ version: "1.2.50" })
|
|
36634
36848
|
}
|
|
36635
36849
|
}];
|
|
36636
36850
|
}
|