@plurnk/plurnk-schemes-http 1.14.1 → 1.15.0
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/README.md +3 -4
- package/SPEC.md +9 -9
- package/dist/Http.d.ts.map +1 -1
- package/dist/Http.js +93 -464
- package/dist/Http.js.map +1 -1
- package/dist/HttpGet.d.ts +35 -0
- package/dist/HttpGet.d.ts.map +1 -0
- package/dist/HttpGet.js +299 -0
- package/dist/HttpGet.js.map +1 -0
- package/dist/HttpRequester.d.ts +23 -0
- package/dist/HttpRequester.d.ts.map +1 -0
- package/dist/HttpRequester.js +171 -0
- package/dist/HttpRequester.js.map +1 -0
- package/dist/LiveAcquisitions.d.ts +8 -0
- package/dist/LiveAcquisitions.d.ts.map +1 -0
- package/dist/LiveAcquisitions.js +27 -0
- package/dist/LiveAcquisitions.js.map +1 -0
- package/dist/WebFetcher.d.ts +2 -2
- package/dist/WebFetcher.d.ts.map +1 -1
- package/dist/WebFetcher.js +1 -1
- package/dist/WebFetcher.js.map +1 -1
- package/dist/Ws.d.ts.map +1 -1
- package/dist/Ws.js +5 -7
- package/dist/Ws.js.map +1 -1
- package/dist/http-names.d.ts +5 -0
- package/dist/http-names.d.ts.map +1 -0
- package/dist/http-names.js +6 -0
- package/dist/http-names.js.map +1 -0
- package/docs/https.md +8 -7
- package/docs/wss.md +1 -2
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -13,11 +13,10 @@ authored against the DB-free
|
|
|
13
13
|
| `## READ0 (http(s)://…)` | Fetch or reuse/revalidate a GET representation, then stream the selected response channel |
|
|
14
14
|
| `## READ0 (http(s)://…) <scope>` | Apply the standard entry READ to an already-materialized response without refetching |
|
|
15
15
|
| `## FIND0 (http(s)://…)` with matcher body | Materialize an exact URL when required, then use the universal entry query and matcher |
|
|
16
|
-
| `## SEND0
|
|
16
|
+
| `## SEND0 (http(s)://…)` with body | POST the body and stream the response |
|
|
17
17
|
| `## EDIT0 (http(s)://…)` with body | PUT a whole-resource replacement; line-scoped HTTP edits are invalid |
|
|
18
|
-
| `## KILL0 (http(s)://…)` |
|
|
19
|
-
| `##
|
|
20
|
-
| `## SEND0 [410] (http(s)://…)` | Delete the local stored response entry |
|
|
18
|
+
| `## KILL0 (http(s)://…)` | Cancel a live acquisition of the address, or forget its stored response |
|
|
19
|
+
| `## KILL0 (http(s)://…) {remote}` | DELETE the remote resource and stream the response |
|
|
21
20
|
|
|
22
21
|
A path-pattern FIND surveys already-materialized web entries; it does not crawl
|
|
23
22
|
or discover the remote web. Exact matcher FIND shares the standard flat
|
package/SPEC.md
CHANGED
|
@@ -44,11 +44,10 @@ preserved exactly.
|
|
|
44
44
|
| Exact `## READ0 (url) <scope?>` | GET unless a fresh GET copy is usable | Prepare one complete canonical representation, then let core select and project it |
|
|
45
45
|
| Exact `## FIND0 (url)` | GET only when acquisition is required | Use the same preparation, then universal query, matcher, weighting, and pagination |
|
|
46
46
|
| `## FIND0 (pattern-url)` | None | Query already-materialized web entries; a path pattern does not discover the remote web |
|
|
47
|
-
| `## SEND0
|
|
47
|
+
| `## SEND0 (url)` with body | POST | Stream and persist the response under the addressed URL |
|
|
48
48
|
| `## EDIT0 (url)` with body | PUT | Replace the whole remote resource; a line marker is invalid |
|
|
49
|
-
| `## KILL0 (url)` |
|
|
50
|
-
| `##
|
|
51
|
-
| `## SEND0 [499] (url)` | Cancellation is engine-routed | The routed subscription handle aborts the live owner; scheme dispatch is a `200` no-op |
|
|
49
|
+
| `## KILL0 (url)` | None | {§http-kill}: cancel the worker's live acquisition of the URL, else delete the local stored entry |
|
|
50
|
+
| `## KILL0 (url) {remote}` | DELETE | Delete the remote resource and stream its response; other metadata blocks are its headers |
|
|
52
51
|
|
|
53
52
|
Finite GET uses scope-blind representation preparation; POST, PUT, DELETE,
|
|
54
53
|
and genuinely live GET responses retain the subscription path. Request
|
|
@@ -232,8 +231,8 @@ an origin is first being read.
|
|
|
232
231
|
| Finite empty text response | `204` |
|
|
233
232
|
| Finite binary response has no readable projection | `415` (`binary-response-unsupported`) |
|
|
234
233
|
| Binary projection input exceeds the configured byte bound | `413` (`projection-input-limit`) |
|
|
235
|
-
|
|
|
236
|
-
|
|
|
234
|
+
| `KILL` with no live acquisition | Exact entry-delete result |
|
|
235
|
+
| `KILL` of a live acquisition | `200`; the owner settles `499` through its aborted signal |
|
|
237
236
|
| Client-cancelled finite acquisition | `499` (`cancelled`) |
|
|
238
237
|
| SSE after acquisition | `102` initial; terminal selected-channel result |
|
|
239
238
|
| SSE cancellation after acquisition | `102` initial; terminal `499` |
|
|
@@ -420,7 +419,9 @@ body, TTL, and validators together.
|
|
|
420
419
|
POST, PUT, and DELETE responses retain their method marker but cannot satisfy a
|
|
421
420
|
later GET or exact-FIND acquisition. An unmarked authored entry and an eligible
|
|
422
421
|
stored GET remain visible to universal FIND as durable evidence; exact HTTP
|
|
423
|
-
preparation applies the policy above.
|
|
422
|
+
preparation applies the policy above. A metadata-less `KILL` deletes the stored entry ({§http-kill}).
|
|
423
|
+
|
|
424
|
+
§http-kill **KILL follows the entry rule; the remote DELETE is its own spelling.** `## KILL0 (url)` cancels the acting worker's live acquisition of that URL when one is in flight — GET, SSE, or a mutation — by aborting the controller the scheme tracks per worker and URL, and the owner settles itself as `499` cancelled; with nothing in flight it deletes the local stored entry so the next READ must acquire again. Only `## KILL0 (url) {remote}` sends the HTTP DELETE, and its remaining metadata blocks are that request's headers. A KILL never reaches the remote by accident.
|
|
424
425
|
|
|
425
426
|
### §sse Server-sent events
|
|
426
427
|
|
|
@@ -484,8 +485,7 @@ stateDiagram-v2
|
|
|
484
485
|
| `## READ0 (ws(s)://…)` | Claim, seed/subscribe, construct `CONNECTING`, then return `102` after native `open` plus durable activation |
|
|
485
486
|
| Concurrent duplicate READ | `409` in `claimed`, `connecting`, `open`, or `settling`; cleanup releases the only claim |
|
|
486
487
|
| `## EDIT0 (ws(s)://…)` | Send one whole text frame only for an open owner; line ranges and multi-statement batches are rejected |
|
|
487
|
-
| `## SEND0
|
|
488
|
-
| `## SEND0 [499] (ws(s)://…)` | Engine-routed cancellation closes the owning READ; scheme dispatch returns `200` |
|
|
488
|
+
| `## SEND0 (ws(s)://…)` with body | Send only for owner `open` plus native `readyState=OPEN`; absent or non-open owner is `409`; send throw is `502` |
|
|
489
489
|
| `## KILL0 (ws(s)://…)` | Close/cancel the claimed owner; no owner is `404`; an attempted close throw is `502` |
|
|
490
490
|
| Inbound frame after native `open` | Join the owner's persistence chain; the next write begins only after the preceding write succeeds |
|
|
491
491
|
| Binary frame after native `open` | Retain the text prefix, prune the binary and later frames, settle `415 binary-frame-unsupported`, close with private-use code `4003` |
|
package/dist/Http.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Http.d.ts","sourceRoot":"","sources":["../src/Http.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"Http.d.ts","sourceRoot":"","sources":["../src/Http.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,SAAS,EAA6C,iBAAiB,EAAE,cAAc,EAAE,aAAa,EAAE,gCAAgC,EAAE,+BAA+B,EAAE,aAAa,EAAE,qBAAqB,EAAE,aAAa,EAAmF,MAAM,wBAAwB,CAAC;AAsL9V,MAAM,CAAC,OAAO,OAAO,IAAK,YAAW,aAAa;;IAC9C,MAAM,CAAC,QAAQ,EAAE,cAAc,CAgC7B;IAUF,cAKC;IAEK,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC,CAE3B;IAKK,qBAAqB,CACvB,OAAO,EAAE,gCAAgC,EACzC,GAAG,EAAE,SAAS,GACf,OAAO,CAAC,+BAA+B,CAAC,CAS1C;IAIK,SAAS,CAAC,UAAU,EAAE,SAAS,qBAAqB,EAAE,EAAE,GAAG,EAAE,SAAS,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAqCxG;IAEK,IAAI,CAAC,SAAS,EAAE,qBAAqB,EAAE,GAAG,EAAE,SAAS,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAEvF;IAKK,IAAI,CAAC,SAAS,EAAE,aAAa,EAAE,GAAG,EAAE,SAAS,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAqB/E;IAIK,IAAI,CAAC,SAAS,EAAE,aAAa,EAAE,GAAG,EAAE,SAAS,GAAG,OAAO,CAAC,iBAAiB,CAAC,CA0B/E;CAijBJ"}
|