@camstack/addon-remote-storage 1.2.23 → 1.2.24

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/s3.addon.js CHANGED
@@ -2,7 +2,7 @@ Object.defineProperties(exports, {
2
2
  __esModule: { value: true },
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
- const require_shared = require("./shared-COlcUch_.js");
5
+ const require_shared = require("./shared-CAxkUIT8.js");
6
6
  let node_stream = require("node:stream");
7
7
  let _aws_sdk_client_s3 = require("@aws-sdk/client-s3");
8
8
  let _aws_sdk_lib_storage = require("@aws-sdk/lib-storage");
package/dist/s3.addon.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { c as BaseAddon, i as rearmIdleAbort, n as getOptionalBasePath, o as scheduleIdleAbort, s as storageProviderCapability, t as createSessionId } from "./shared-C5iPm_0G.mjs";
1
+ import { c as BaseAddon, i as rearmIdleAbort, n as getOptionalBasePath, o as scheduleIdleAbort, s as storageProviderCapability, t as createSessionId } from "./shared-CMeaUSWI.mjs";
2
2
  import { PassThrough } from "node:stream";
3
3
  import { DeleteObjectCommand, GetObjectCommand, HeadBucketCommand, HeadObjectCommand, ListObjectsV2Command, PutObjectCommand, S3Client } from "@aws-sdk/client-s3";
4
4
  import { Upload } from "@aws-sdk/lib-storage";
@@ -2,7 +2,7 @@ Object.defineProperties(exports, {
2
2
  __esModule: { value: true },
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
- const require_shared = require("./shared-COlcUch_.js");
5
+ const require_shared = require("./shared-CAxkUIT8.js");
6
6
  let ssh2 = require("ssh2");
7
7
  let node_path = require("node:path");
8
8
  node_path = require_shared.__toESM(node_path);
@@ -1,4 +1,4 @@
1
- import { a as safeJoinRemotePath, c as BaseAddon, i as rearmIdleAbort, o as scheduleIdleAbort, r as getRequiredBasePath, s as storageProviderCapability, t as createSessionId } from "./shared-C5iPm_0G.mjs";
1
+ import { a as safeJoinRemotePath, c as BaseAddon, i as rearmIdleAbort, o as scheduleIdleAbort, r as getRequiredBasePath, s as storageProviderCapability, t as createSessionId } from "./shared-CMeaUSWI.mjs";
2
2
  import { Client } from "ssh2";
3
3
  import * as path from "node:path";
4
4
  //#region src/providers/sftp/sftp-config-schema.ts
@@ -18647,6 +18647,12 @@ var CameraStatusSchema = object({
18647
18647
  /** Unix timestamp (ms) when this snapshot was composed server-side. */
18648
18648
  fetchedAt: number()
18649
18649
  });
18650
+ var InferenceDeviceExclusionReasonSchema = _enum([
18651
+ "disabled",
18652
+ "unavailable",
18653
+ "cannot-host-camera-root",
18654
+ "accelerator-preferred"
18655
+ ]);
18650
18656
  var NodeInferenceDeviceSchema = object({
18651
18657
  /** Stable per-node device key, e.g. `openvino:npu`, `edgetpu:usb`, `cpu`. */
18652
18658
  key: string(),
@@ -18677,7 +18683,17 @@ var NodeInferenceDeviceSchema = object({
18677
18683
  * available per format; this is the stored selection that becomes the
18678
18684
  * default for EVERY camera landing on this accelerator.
18679
18685
  */
18680
- steps: record(string(), DeviceStepConfigSchema).optional()
18686
+ steps: record(string(), DeviceStepConfigSchema).optional(),
18687
+ /**
18688
+ * `null` when the device IS a camera-root candidate on this node; otherwise
18689
+ * the reason the dispatcher drops it. Computed by the SAME
18690
+ * `resolveInferenceDeviceEligibility` the dispatcher runs, so this view can
18691
+ * never disagree with the election — deriving it in the UI from
18692
+ * `enabled`/`available` would silently miss `cannot-host-camera-root` (needs
18693
+ * the node's model catalog) and `accelerator-preferred` (needs the node-wide
18694
+ * "an accelerator is serving" predicate).
18695
+ */
18696
+ exclusion: InferenceDeviceExclusionReasonSchema.nullable()
18681
18697
  });
18682
18698
  var NodeInferenceDevicesSchema = object({
18683
18699
  nodeId: string(),
@@ -22480,7 +22496,12 @@ var ListResultSchema = object({
22480
22496
  probedAt: number()
22481
22497
  });
22482
22498
  var PreferredSchema = LocalInterfaceSchema.nullable();
22483
- var GetConnectionEndpointsResultSchema = object({ endpoints: array(object({
22499
+ /**
22500
+ * Candidate base URL for the SDK to race on connect. Order matters —
22501
+ * the SDK should attempt these top-to-bottom with a short per-candidate
22502
+ * timeout (e.g. 1500ms) and cache the winner for the session.
22503
+ */
22504
+ var ConnectionEndpointSchema = object({
22484
22505
  /** Operator-facing label (e.g. "LAN — en0", "Public tunnel"). */
22485
22506
  label: string(),
22486
22507
  /** Fully-formed base URL with scheme + host + port. */
@@ -22523,7 +22544,42 @@ var GetConnectionEndpointsResultSchema = object({ endpoints: array(object({
22523
22544
  * ordering between polls.
22524
22545
  */
22525
22546
  priority: number()
22526
- })).readonly() });
22547
+ });
22548
+ /**
22549
+ * Where the advertised local port came from. Ordered most → least
22550
+ * authoritative, and the whole point of returning it: a client must be able to
22551
+ * tell a FACT about the hub's socket from an echo of its own guess.
22552
+ */
22553
+ var LocalPortSourceEnum = _enum([
22554
+ "server-config",
22555
+ "server-env",
22556
+ "caller-hint",
22557
+ "default"
22558
+ ]);
22559
+ /** The port every LAN/loopback `baseUrl` in the same result was built with. */
22560
+ var AdvertisedLocalPortSchema = object({
22561
+ port: number().int().min(1).max(65535),
22562
+ source: LocalPortSourceEnum
22563
+ });
22564
+ var GetConnectionEndpointsResultSchema = object({
22565
+ endpoints: array(ConnectionEndpointSchema).readonly(),
22566
+ /**
22567
+ * The port the hub built the LAN/loopback URLs with, and where that number
22568
+ * came from.
22569
+ *
22570
+ * Returned rather than merely applied, because "the URL is right" and "the
22571
+ * client can KNOW the URL is right" are different properties. A client that
22572
+ * only sees a corrected URL cannot distinguish a hub that fixed the port from
22573
+ * a hub that echoed the port the client sent, so it cannot decide whether to
22574
+ * race the candidate or discard it. With `source` it can: anything but
22575
+ * `caller-hint` is the hub's own socket.
22576
+ *
22577
+ * Absent on hubs predating this field — a client that finds it missing is
22578
+ * talking to an echoing hub and must degrade exactly as it does for
22579
+ * `caller-hint`.
22580
+ */
22581
+ localPort: AdvertisedLocalPortSchema
22582
+ });
22527
22583
  /**
22528
22584
  * The chosen outbound endpoint for notification artifacts. `baseUrl: null` =
22529
22585
  * AUTO (resolved from the candidate ranking at send time); `resolved` reports
@@ -22544,8 +22600,13 @@ var AllowedAddressesSchema = object({
22544
22600
  */
22545
22601
  addresses: array(string()).readonly() });
22546
22602
  method(_void(), ListResultSchema), method(_void(), PreferredSchema), method(object({
22547
- /** Local hub HTTP port to use in base URLs. */
22548
- port: number().int().min(1).max(65535),
22603
+ /**
22604
+ * LEGACY HINT — do not send from new code. Kept optional so clients
22605
+ * written against the echoing contract keep working; the hub uses it
22606
+ * only when it cannot read its own port, and says so via
22607
+ * `localPort.source === 'caller-hint'`.
22608
+ */
22609
+ port: number().int().min(1).max(65535).optional(),
22549
22610
  /** Include `http(s)://127.0.0.1:<port>` as the lowest-priority
22550
22611
  * candidate. Default `true`. */
22551
22612
  includeLoopback: boolean().optional(),
@@ -18624,6 +18624,12 @@ var CameraStatusSchema = object({
18624
18624
  /** Unix timestamp (ms) when this snapshot was composed server-side. */
18625
18625
  fetchedAt: number()
18626
18626
  });
18627
+ var InferenceDeviceExclusionReasonSchema = _enum([
18628
+ "disabled",
18629
+ "unavailable",
18630
+ "cannot-host-camera-root",
18631
+ "accelerator-preferred"
18632
+ ]);
18627
18633
  var NodeInferenceDeviceSchema = object({
18628
18634
  /** Stable per-node device key, e.g. `openvino:npu`, `edgetpu:usb`, `cpu`. */
18629
18635
  key: string(),
@@ -18654,7 +18660,17 @@ var NodeInferenceDeviceSchema = object({
18654
18660
  * available per format; this is the stored selection that becomes the
18655
18661
  * default for EVERY camera landing on this accelerator.
18656
18662
  */
18657
- steps: record(string(), DeviceStepConfigSchema).optional()
18663
+ steps: record(string(), DeviceStepConfigSchema).optional(),
18664
+ /**
18665
+ * `null` when the device IS a camera-root candidate on this node; otherwise
18666
+ * the reason the dispatcher drops it. Computed by the SAME
18667
+ * `resolveInferenceDeviceEligibility` the dispatcher runs, so this view can
18668
+ * never disagree with the election — deriving it in the UI from
18669
+ * `enabled`/`available` would silently miss `cannot-host-camera-root` (needs
18670
+ * the node's model catalog) and `accelerator-preferred` (needs the node-wide
18671
+ * "an accelerator is serving" predicate).
18672
+ */
18673
+ exclusion: InferenceDeviceExclusionReasonSchema.nullable()
18658
18674
  });
18659
18675
  var NodeInferenceDevicesSchema = object({
18660
18676
  nodeId: string(),
@@ -22457,7 +22473,12 @@ var ListResultSchema = object({
22457
22473
  probedAt: number()
22458
22474
  });
22459
22475
  var PreferredSchema = LocalInterfaceSchema.nullable();
22460
- var GetConnectionEndpointsResultSchema = object({ endpoints: array(object({
22476
+ /**
22477
+ * Candidate base URL for the SDK to race on connect. Order matters —
22478
+ * the SDK should attempt these top-to-bottom with a short per-candidate
22479
+ * timeout (e.g. 1500ms) and cache the winner for the session.
22480
+ */
22481
+ var ConnectionEndpointSchema = object({
22461
22482
  /** Operator-facing label (e.g. "LAN — en0", "Public tunnel"). */
22462
22483
  label: string(),
22463
22484
  /** Fully-formed base URL with scheme + host + port. */
@@ -22500,7 +22521,42 @@ var GetConnectionEndpointsResultSchema = object({ endpoints: array(object({
22500
22521
  * ordering between polls.
22501
22522
  */
22502
22523
  priority: number()
22503
- })).readonly() });
22524
+ });
22525
+ /**
22526
+ * Where the advertised local port came from. Ordered most → least
22527
+ * authoritative, and the whole point of returning it: a client must be able to
22528
+ * tell a FACT about the hub's socket from an echo of its own guess.
22529
+ */
22530
+ var LocalPortSourceEnum = _enum([
22531
+ "server-config",
22532
+ "server-env",
22533
+ "caller-hint",
22534
+ "default"
22535
+ ]);
22536
+ /** The port every LAN/loopback `baseUrl` in the same result was built with. */
22537
+ var AdvertisedLocalPortSchema = object({
22538
+ port: number().int().min(1).max(65535),
22539
+ source: LocalPortSourceEnum
22540
+ });
22541
+ var GetConnectionEndpointsResultSchema = object({
22542
+ endpoints: array(ConnectionEndpointSchema).readonly(),
22543
+ /**
22544
+ * The port the hub built the LAN/loopback URLs with, and where that number
22545
+ * came from.
22546
+ *
22547
+ * Returned rather than merely applied, because "the URL is right" and "the
22548
+ * client can KNOW the URL is right" are different properties. A client that
22549
+ * only sees a corrected URL cannot distinguish a hub that fixed the port from
22550
+ * a hub that echoed the port the client sent, so it cannot decide whether to
22551
+ * race the candidate or discard it. With `source` it can: anything but
22552
+ * `caller-hint` is the hub's own socket.
22553
+ *
22554
+ * Absent on hubs predating this field — a client that finds it missing is
22555
+ * talking to an echoing hub and must degrade exactly as it does for
22556
+ * `caller-hint`.
22557
+ */
22558
+ localPort: AdvertisedLocalPortSchema
22559
+ });
22504
22560
  /**
22505
22561
  * The chosen outbound endpoint for notification artifacts. `baseUrl: null` =
22506
22562
  * AUTO (resolved from the candidate ranking at send time); `resolved` reports
@@ -22521,8 +22577,13 @@ var AllowedAddressesSchema = object({
22521
22577
  */
22522
22578
  addresses: array(string()).readonly() });
22523
22579
  method(_void(), ListResultSchema), method(_void(), PreferredSchema), method(object({
22524
- /** Local hub HTTP port to use in base URLs. */
22525
- port: number().int().min(1).max(65535),
22580
+ /**
22581
+ * LEGACY HINT — do not send from new code. Kept optional so clients
22582
+ * written against the echoing contract keep working; the hub uses it
22583
+ * only when it cannot read its own port, and says so via
22584
+ * `localPort.source === 'caller-hint'`.
22585
+ */
22586
+ port: number().int().min(1).max(65535).optional(),
22526
22587
  /** Include `http(s)://127.0.0.1:<port>` as the lowest-priority
22527
22588
  * candidate. Default `true`. */
22528
22589
  includeLoopback: boolean().optional(),
@@ -2,7 +2,7 @@ Object.defineProperties(exports, {
2
2
  __esModule: { value: true },
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
- const require_shared = require("./shared-COlcUch_.js");
5
+ const require_shared = require("./shared-CAxkUIT8.js");
6
6
  let node_stream = require("node:stream");
7
7
  let webdav = require("webdav");
8
8
  //#region src/providers/webdav/webdav-config-schema.ts
@@ -1,4 +1,4 @@
1
- import { a as safeJoinRemotePath, c as BaseAddon, i as rearmIdleAbort, o as scheduleIdleAbort, r as getRequiredBasePath, s as storageProviderCapability, t as createSessionId } from "./shared-C5iPm_0G.mjs";
1
+ import { a as safeJoinRemotePath, c as BaseAddon, i as rearmIdleAbort, o as scheduleIdleAbort, r as getRequiredBasePath, s as storageProviderCapability, t as createSessionId } from "./shared-CMeaUSWI.mjs";
2
2
  import { PassThrough } from "node:stream";
3
3
  import { AuthType, createClient } from "webdav";
4
4
  //#region src/providers/webdav/webdav-config-schema.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-remote-storage",
3
- "version": "1.2.23",
3
+ "version": "1.2.24",
4
4
  "description": "Remote storage providers (SFTP, S3, WebDAV) — unifies remote backends behind the storage-provider cap",
5
5
  "keywords": [
6
6
  "camstack",