@camstack/addon-provider-dreame 0.2.32 → 0.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 CHANGED
@@ -78950,17 +78950,60 @@ var SetSiteLocationInputSchema = object({
78950
78950
  longitude: number().min(-180).max(180)
78951
78951
  }).nullable();
78952
78952
  /**
78953
- * One `(procedure, user-agent, ip, principal)` tuple of the HTTP request
78953
+ * The TRANSPORT a call arrived on.
78954
+ *
78955
+ * Every counted call carries exactly one of these, and `unknown` is a PLANE
78956
+ * rather than a gap: a plane that cannot attribute a call declares it here, so
78957
+ * the call lands in a named bucket instead of vanishing. `planes` summing to
78958
+ * `procedureCalls` is what makes "the sum of the planes explains the total"
78959
+ * checkable rather than asserted.
78960
+ *
78961
+ * - `http` — the Fastify tRPC plugin (`/trpc/*`), one context per request.
78962
+ * - `ws` — `applyWSSHandler`, counted per OPERATION rather than per
78963
+ * connection; the viewer talks to the hub over `wsLink`
78964
+ * exclusively, so this is the plane the HTTP census could not see.
78965
+ * - `mesh` — the in-process `$core-caps` bridge (`createCaller`), which
78966
+ * never touches a socket and therefore never touched a census.
78967
+ * - `unknown` — counted, plane undecidable. No hook produces it today, and
78968
+ * that is exactly what its `0` asserts: every plane the hub has can name
78969
+ * itself. It is an output bucket, never a knob — a call that arrives on a
78970
+ * plane nobody instrumented lands here instead of vanishing from the total.
78971
+ */
78972
+ var TransportPlaneSchema = _enum([
78973
+ "http",
78974
+ "ws",
78975
+ "mesh",
78976
+ "unknown"
78977
+ ]);
78978
+ /**
78979
+ * Calls per plane. Every key is always present, `0` included — an absent plane
78980
+ * reads as "not instrumented", which is the one thing this census must never
78981
+ * make an operator wonder about.
78982
+ */
78983
+ var TransportPlaneCountsSchema = object({
78984
+ http: number(),
78985
+ ws: number(),
78986
+ mesh: number(),
78987
+ unknown: number()
78988
+ });
78989
+ /**
78990
+ * One `(plane, procedure, user-agent, ip, principal)` tuple of the transport
78954
78991
  * census. `principal` is the DERIVED identity (`apocaliss92 (admin)`,
78955
78992
  * `scoped:1a2b3c4d (scoped-token)`, `anonymous`) that the tRPC error log
78956
78993
  * already prints - never a token, never an `Authorization` header.
78994
+ *
78995
+ * `subscriptions` is counted APART from `calls`: a subscription is opened once
78996
+ * and lives for hours, so folding it into a call count makes one long-lived
78997
+ * stream look like a storm.
78957
78998
  */
78958
78999
  var RequestCensusGroupSchema = object({
79000
+ plane: TransportPlaneSchema,
78959
79001
  procedure: string(),
78960
79002
  userAgent: string(),
78961
79003
  ip: string(),
78962
79004
  principal: string(),
78963
79005
  calls: number(),
79006
+ subscriptions: number(),
78964
79007
  perMin: number()
78965
79008
  });
78966
79009
  /**
@@ -78973,6 +79016,14 @@ var RequestCensusGroupSchema = object({
78973
79016
  var RequestCensusProcedureSchema = object({
78974
79017
  procedure: string(),
78975
79018
  calls: number(),
79019
+ /**
79020
+ * The same total, split by transport. THIS is the row that answers the
79021
+ * question the census exists for: one look at `deviceManager.listAll` says
79022
+ * which plane carried the 4 960, without joining two log lines by eye.
79023
+ */
79024
+ planes: TransportPlaneCountsSchema,
79025
+ /** Subscription STARTS on this procedure. Never folded into `calls`. */
79026
+ subscriptions: number(),
78976
79027
  perMin: number()
78977
79028
  });
78978
79029
  /**
@@ -79000,14 +79051,45 @@ var RequestCensusStatusSchema = object({
79000
79051
  */
79001
79052
  procedureCalls: number(),
79002
79053
  /**
79054
+ * `procedureCalls` split by transport. The four keys sum to
79055
+ * `procedureCalls` by construction - {@link RequestCensusSnapshotSchema}'s
79056
+ * `planesExplainTotal` is that identity, checked rather than assumed.
79057
+ */
79058
+ planes: TransportPlaneCountsSchema,
79059
+ /**
79060
+ * True iff `planes` sums to `procedureCalls`. False means a call was counted
79061
+ * on no plane at all - which is a RESULT (a plane is missing from the
79062
+ * instrument), not a failure, and it has to be visible to be read as one.
79063
+ */
79064
+ planesExplainTotal: boolean(),
79065
+ /**
79003
79066
  * tRPC WebSocket connections opened during the window. NOT calls - the WS
79004
- * transport resolves one context per connection - but the number that says
79005
- * whether a plane this census cannot see was busy while HTTP was quiet.
79067
+ * adapter resolves one context per connection - kept because a plane's call
79068
+ * count of zero against 37 open connections says something different from a
79069
+ * plane with no connections at all.
79006
79070
  */
79007
79071
  wsConnections: number(),
79072
+ /**
79073
+ * Client frames the WS plane looked at. `wsMessages` far above
79074
+ * `planes.ws + subscriptions` means most traffic is not operations
79075
+ * (keepalives, connection params) - which is itself an answer.
79076
+ */
79077
+ wsMessages: number(),
79078
+ /**
79079
+ * Subscription STARTS across every plane, excluded from `procedureCalls` on
79080
+ * purpose: one live-events stream opened at boot and held for six hours is
79081
+ * one subscription, and counting it as a call would let a quiet plane
79082
+ * masquerade as the storm.
79083
+ */
79084
+ subscriptions: number(),
79085
+ /** `subscription.stop` frames. Starts minus stops is what is still open. */
79086
+ subscriptionStops: number(),
79008
79087
  distinctGroups: number(),
79009
- /** Calls counted in the totals whose group attribution was shed at the
79010
- * cardinality bound. */
79088
+ /**
79089
+ * Operations counted in the totals whose CALLER attribution was shed at the
79090
+ * cardinality bound. Unrelated to the `unknown` PLANE: these calls know
79091
+ * which transport they arrived on, they just lost their group row.
79092
+ */
79011
79093
  unattributedCalls: number(),
79012
79094
  procedures: array(RequestCensusProcedureSchema).readonly(),
79013
79095
  groups: array(RequestCensusGroupSchema).readonly()
package/dist/addon.mjs CHANGED
@@ -78950,17 +78950,60 @@ var SetSiteLocationInputSchema = object({
78950
78950
  longitude: number().min(-180).max(180)
78951
78951
  }).nullable();
78952
78952
  /**
78953
- * One `(procedure, user-agent, ip, principal)` tuple of the HTTP request
78953
+ * The TRANSPORT a call arrived on.
78954
+ *
78955
+ * Every counted call carries exactly one of these, and `unknown` is a PLANE
78956
+ * rather than a gap: a plane that cannot attribute a call declares it here, so
78957
+ * the call lands in a named bucket instead of vanishing. `planes` summing to
78958
+ * `procedureCalls` is what makes "the sum of the planes explains the total"
78959
+ * checkable rather than asserted.
78960
+ *
78961
+ * - `http` — the Fastify tRPC plugin (`/trpc/*`), one context per request.
78962
+ * - `ws` — `applyWSSHandler`, counted per OPERATION rather than per
78963
+ * connection; the viewer talks to the hub over `wsLink`
78964
+ * exclusively, so this is the plane the HTTP census could not see.
78965
+ * - `mesh` — the in-process `$core-caps` bridge (`createCaller`), which
78966
+ * never touches a socket and therefore never touched a census.
78967
+ * - `unknown` — counted, plane undecidable. No hook produces it today, and
78968
+ * that is exactly what its `0` asserts: every plane the hub has can name
78969
+ * itself. It is an output bucket, never a knob — a call that arrives on a
78970
+ * plane nobody instrumented lands here instead of vanishing from the total.
78971
+ */
78972
+ var TransportPlaneSchema = _enum([
78973
+ "http",
78974
+ "ws",
78975
+ "mesh",
78976
+ "unknown"
78977
+ ]);
78978
+ /**
78979
+ * Calls per plane. Every key is always present, `0` included — an absent plane
78980
+ * reads as "not instrumented", which is the one thing this census must never
78981
+ * make an operator wonder about.
78982
+ */
78983
+ var TransportPlaneCountsSchema = object({
78984
+ http: number(),
78985
+ ws: number(),
78986
+ mesh: number(),
78987
+ unknown: number()
78988
+ });
78989
+ /**
78990
+ * One `(plane, procedure, user-agent, ip, principal)` tuple of the transport
78954
78991
  * census. `principal` is the DERIVED identity (`apocaliss92 (admin)`,
78955
78992
  * `scoped:1a2b3c4d (scoped-token)`, `anonymous`) that the tRPC error log
78956
78993
  * already prints - never a token, never an `Authorization` header.
78994
+ *
78995
+ * `subscriptions` is counted APART from `calls`: a subscription is opened once
78996
+ * and lives for hours, so folding it into a call count makes one long-lived
78997
+ * stream look like a storm.
78957
78998
  */
78958
78999
  var RequestCensusGroupSchema = object({
79000
+ plane: TransportPlaneSchema,
78959
79001
  procedure: string(),
78960
79002
  userAgent: string(),
78961
79003
  ip: string(),
78962
79004
  principal: string(),
78963
79005
  calls: number(),
79006
+ subscriptions: number(),
78964
79007
  perMin: number()
78965
79008
  });
78966
79009
  /**
@@ -78973,6 +79016,14 @@ var RequestCensusGroupSchema = object({
78973
79016
  var RequestCensusProcedureSchema = object({
78974
79017
  procedure: string(),
78975
79018
  calls: number(),
79019
+ /**
79020
+ * The same total, split by transport. THIS is the row that answers the
79021
+ * question the census exists for: one look at `deviceManager.listAll` says
79022
+ * which plane carried the 4 960, without joining two log lines by eye.
79023
+ */
79024
+ planes: TransportPlaneCountsSchema,
79025
+ /** Subscription STARTS on this procedure. Never folded into `calls`. */
79026
+ subscriptions: number(),
78976
79027
  perMin: number()
78977
79028
  });
78978
79029
  /**
@@ -79000,14 +79051,45 @@ var RequestCensusStatusSchema = object({
79000
79051
  */
79001
79052
  procedureCalls: number(),
79002
79053
  /**
79054
+ * `procedureCalls` split by transport. The four keys sum to
79055
+ * `procedureCalls` by construction - {@link RequestCensusSnapshotSchema}'s
79056
+ * `planesExplainTotal` is that identity, checked rather than assumed.
79057
+ */
79058
+ planes: TransportPlaneCountsSchema,
79059
+ /**
79060
+ * True iff `planes` sums to `procedureCalls`. False means a call was counted
79061
+ * on no plane at all - which is a RESULT (a plane is missing from the
79062
+ * instrument), not a failure, and it has to be visible to be read as one.
79063
+ */
79064
+ planesExplainTotal: boolean(),
79065
+ /**
79003
79066
  * tRPC WebSocket connections opened during the window. NOT calls - the WS
79004
- * transport resolves one context per connection - but the number that says
79005
- * whether a plane this census cannot see was busy while HTTP was quiet.
79067
+ * adapter resolves one context per connection - kept because a plane's call
79068
+ * count of zero against 37 open connections says something different from a
79069
+ * plane with no connections at all.
79006
79070
  */
79007
79071
  wsConnections: number(),
79072
+ /**
79073
+ * Client frames the WS plane looked at. `wsMessages` far above
79074
+ * `planes.ws + subscriptions` means most traffic is not operations
79075
+ * (keepalives, connection params) - which is itself an answer.
79076
+ */
79077
+ wsMessages: number(),
79078
+ /**
79079
+ * Subscription STARTS across every plane, excluded from `procedureCalls` on
79080
+ * purpose: one live-events stream opened at boot and held for six hours is
79081
+ * one subscription, and counting it as a call would let a quiet plane
79082
+ * masquerade as the storm.
79083
+ */
79084
+ subscriptions: number(),
79085
+ /** `subscription.stop` frames. Starts minus stops is what is still open. */
79086
+ subscriptionStops: number(),
79008
79087
  distinctGroups: number(),
79009
- /** Calls counted in the totals whose group attribution was shed at the
79010
- * cardinality bound. */
79088
+ /**
79089
+ * Operations counted in the totals whose CALLER attribution was shed at the
79090
+ * cardinality bound. Unrelated to the `unknown` PLANE: these calls know
79091
+ * which transport they arrived on, they just lost their group row.
79092
+ */
79011
79093
  unattributedCalls: number(),
79012
79094
  procedures: array(RequestCensusProcedureSchema).readonly(),
79013
79095
  groups: array(RequestCensusGroupSchema).readonly()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-dreame",
3
- "version": "0.2.32",
3
+ "version": "0.2.33",
4
4
  "description": "Dreame robot-vacuum / lawn-mower device-provider addon for CamStack — wraps the @apocaliss92/nodedreame Dreamehome cloud client",
5
5
  "keywords": [
6
6
  "camstack",