@hile/message-ipc 4.0.0 → 4.0.2

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.
Files changed (3) hide show
  1. package/AI.md +6 -0
  2. package/README.md +2 -0
  3. package/package.json +3 -3
package/AI.md CHANGED
@@ -130,6 +130,7 @@ Use the message packages for request/response messaging over WebSocket, process
130
130
  - Do not use `stream()` for normal single-result calls.
131
131
  - Do not rely on message IDs for business idempotency. They are transport IDs.
132
132
  - Do not bypass `defineMessage()` for file-loaded handlers.
133
+ - Do not pass zero, fractional, non-finite, or oversized message timeouts. Explicit timeout values must be safe integers from `1` through `2_147_483_647` milliseconds.
133
134
 
134
135
  ## Install
135
136
 
@@ -160,7 +161,11 @@ import { MessageWorkerThread } from '@hile/message-worker-thread'
160
161
  - `MessageLoader` maps `*.msg.*` files to routes using `@hile/loader`.
161
162
  - `MessageLoader.dispatch(path, data, extras?)` invokes the matched handler.
162
163
  - `MessageModem._send()` returns a `Promise`.
164
+ - `MessageModem._send()` and `_push()` use a `30_000` ms timeout when none is provided. An explicit timeout must be a safe integer from `1` through `2_147_483_647`; invalid values throw `TypeError` before a message is sent.
163
165
  - `MessageModem._stream()` returns a Node `Readable` in object mode.
166
+ - Stream `timeout` and `idleTimeout` values use the same `1` through `2_147_483_647` ms range. The stream `window` must be a safe integer from `1` through `64` and defaults to `1`.
167
+ - Each modem schedules request, total-stream, and idle-stream deadlines through one internal deadline scheduler. This reduces active Node.js timers without changing timeout, cancellation, ordering, or error semantics.
168
+ - `@hile/message-ws` keeps public `decodeMessageFrame()` payloads isolated from caller-owned input by default. Its owned WebSocket `RawData` path uses a zero-copy binary Flight payload view internally.
164
169
  - A stream request requires `exec()` to return an async iterable.
165
170
  - `Application.call(namespace, url, data, options?)` returns a promise.
166
171
  - `Application.stream(namespace, url, data, options?)` returns a readable stream.
@@ -180,6 +185,7 @@ import { MessageWorkerThread } from '@hile/message-worker-thread'
180
185
  - Message files default-export `defineMessage(...)`.
181
186
  - RPC callers use `await app.call(...)`.
182
187
  - Streaming handlers are async generators.
188
+ - Custom modem timeout values use the documented safe-integer range.
183
189
  - Registry is started before application nodes need discovery.
184
190
  - Micro apps use stable namespaces and advertise reachable hosts.
185
191
 
package/README.md CHANGED
@@ -69,6 +69,7 @@ const result = await app.call('example.service', '/ping', { hello: 'world' })
69
69
  - Do not use `stream()` for normal single-result calls.
70
70
  - Do not rely on message IDs for business idempotency. They are transport IDs.
71
71
  - Do not bypass `defineMessage()` for file-loaded handlers.
72
+ - Do not pass zero, fractional, non-finite, or oversized message timeouts. Explicit timeout values must be safe integers from `1` through `2_147_483_647` milliseconds.
72
73
 
73
74
  - Appending a secondary response getter to `client.request('/x', data)`
74
75
  - Returning a plain object from a handler called through `stream()`.
@@ -80,6 +81,7 @@ const result = await app.call('example.service', '/ping', { hello: 'world' })
80
81
  - Message files default-export `defineMessage(...)`.
81
82
  - RPC callers use `await app.call(...)`.
82
83
  - Streaming handlers are async generators.
84
+ - Custom modem timeout values use the documented safe-integer range.
83
85
  - Registry is started before application nodes need discovery.
84
86
  - Micro apps use stable namespaces and advertise reachable hosts.
85
87
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hile/message-ipc",
3
- "version": "4.0.0",
3
+ "version": "4.0.2",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "scripts": {
@@ -23,7 +23,7 @@
23
23
  "vitest": "^4.0.18"
24
24
  },
25
25
  "dependencies": {
26
- "@hile/message-modem": "^4.0.0"
26
+ "@hile/message-modem": "^4.0.2"
27
27
  },
28
- "gitHead": "b46cb7f3705a226f58e4d65a2ff985ea54b9a159"
28
+ "gitHead": "46d7bcfc78a914aa2af8cd96e41b08511f5af38e"
29
29
  }