@graview/ship 0.1.2 → 0.1.3

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/live.js CHANGED
@@ -1,3 +1,5 @@
1
+ import { WIRE_PROTOCOL } from "@graview/core";
2
+ export { REFUSAL_REASONS } from "@graview/core";
1
3
  /**
2
4
  * THE LIVE WIRE (FR-05): the same store, pushed down a WebSocket.
3
5
  *
@@ -10,7 +12,11 @@
10
12
  * The protocol is numbered by `WIRE_PROTOCOL` (`@graview/core`), which
11
13
  * `hello` and `welcome` both say. The socket is an addition to protocol 1,
12
14
  * not a new protocol: every client of protocol 1 is still served, so the
13
- * number stays where it is (docs/stability.md, "The wire").
15
+ * number stays where it is (docs/stability.md, "The wire"). So did the
16
+ * `declaration` push (FR-43) and the skew messages and fields — `reload`,
17
+ * `wire`, `build` (FR-44): a protocol-1 client that does not know them
18
+ * ignores them, and raising the number would make every server with a
19
+ * `minProtocol` send every open tab a `reload` for nothing.
14
20
  *
15
21
  * Seqs mean what they mean on `GET /graview/since?seq=N`: the position of
16
22
  * an op in the store's log, and a client's seq is the last one it has. -1
@@ -22,6 +28,30 @@
22
28
  * here is told as the seat may be told it.
23
29
  */
24
30
  export const LIVE_PATH = "/graview/live";
31
+ /**
32
+ * THE CODEC'S NAME (FR-44). A host that serves two codecs on one path —
33
+ * its own older one and ship's, through a deploy — tells them apart before
34
+ * reading a word: `hello.wire` says it, and so does the WebSocket
35
+ * subprotocol `LIVE_SUBPROTOCOL` the client asks for. A hello that names
36
+ * another wire is answered `error` and not welcomed; one that names none is
37
+ * ship's, as every hello before this was.
38
+ */
39
+ export const LIVE_WIRE = "graview.ship";
40
+ /**
41
+ * The WebSocket subprotocol ship's client asks for, `graview.ship.<WIRE_PROTOCOL>`:
42
+ * `openRemote` hands it to the socket factory, `serveStore` answers it,
43
+ * and a Worker answers it with what `liveSubprotocol(request)` says.
44
+ */
45
+ export const LIVE_SUBPROTOCOL = `${LIVE_WIRE}.${WIRE_PROTOCOL}`;
46
+ /** The subprotocol to answer an upgrade with: `LIVE_SUBPROTOCOL` when the client offered it, else none. */
47
+ export function liveSubprotocol(request) {
48
+ const offered = (request.headers.get("sec-websocket-protocol") ?? "").split(",").map((one) => one.trim());
49
+ return offered.includes(LIVE_SUBPROTOCOL) ? LIVE_SUBPROTOCOL : undefined;
50
+ }
51
+ /** A message's size in UTF-8 bytes, as a host's cap counts it. */
52
+ export function bytesOf(text) {
53
+ return new TextEncoder().encode(text).length;
54
+ }
25
55
  /** Said as a person would read it: a short value, or "nothing". */
26
56
  export function sayValue(value) {
27
57
  if (value === undefined || value === null || value === "")
package/dist/live.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"live.js","sourceRoot":"","sources":["../src/live.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,CAAC,MAAM,SAAS,GAAG,eAAe,CAAC;AA8EzC,mEAAmE;AACnE,MAAM,UAAU,QAAQ,CAAC,KAAc;IACrC,IAAI,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,EAAE;QAAE,OAAO,SAAS,CAAC;IAC5E,IAAI,OAAO,KAAK,KAAK,QAAQ;QAAE,OAAO,IAAI,KAAK,CAAC,MAAM,GAAG,EAAE,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,KAAK,GAAG,CAAC;IAClG,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,KAAK,SAAS;QAAE,OAAO,MAAM,CAAC,KAAK,CAAC,CAAC;IAClF,MAAM,IAAI,GAAG,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC;IACnC,OAAO,IAAI,CAAC,MAAM,GAAG,EAAE,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE,CAAC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AAC,CAAC,CAAC,EAAE,CAAC;IAC/E,OAAO,GAAG,KAAK,CAAC,EAAE,YAAY,KAAK,CAAC,KAAK,OAAO,QAAQ,CAAC,KAAK,CAAC,MAAM,CAAC,sCAAsC,QAAQ,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,IAAI,qCAAqC,CAAC;AAChL,CAAC"}
package/dist/remote.d.ts CHANGED
@@ -1,4 +1,5 @@
1
- import { Store, type AnySchema, type FieldConflict, type GraviewApp, type MutationCall, type Operation, type PresenceChannel, type Principal, type Via } from "@graview/core";
1
+ import { Store, type AnySchema, type FieldConflict, type GraviewApp, type MutationCall, type Operation, type PresenceChannel, type Principal, type Via, type WireRefusal } from "@graview/core";
2
+ import type { StorageLike } from "./browser-adapter.js";
2
3
  /**
3
4
  * THE OTHER END OF THE WIRE: a store whose graph lives on a server.
4
5
  *
@@ -61,7 +62,12 @@ export interface RemoteOptions<S extends AnySchema> {
61
62
  * where a hosted store's own auth goes without the framework knowing it.
62
63
  */
63
64
  readonly headers?: Readonly<Record<string, string>>;
64
- /** What the calls come through, recorded on each op the server makes: `web` unless said (FR-06). */
65
+ /**
66
+ * What the calls come through: `web` unless said (FR-06). Sent as
67
+ * `SEAT_HEADERS.via`, which a server believes exactly where it believes
68
+ * the seat headers; a server that asks its own `seatOf` says the channel
69
+ * itself (FR-52).
70
+ */
65
71
  readonly via?: Via;
66
72
  /**
67
73
  * THE LIVE WIRE (FR-05): hold a WebSocket to the server's `LIVE_PATH`,
@@ -76,7 +82,46 @@ export interface RemoteOptions<S extends AnySchema> {
76
82
  * and its seat rides in the query, which only a store trusting seat
77
83
  * headers reads).
78
84
  */
79
- readonly socket?: (url: string, headers: Readonly<Record<string, string>>) => LiveSocketLike;
85
+ readonly socket?: (url: string, headers: Readonly<Record<string, string>>, protocols: readonly string[]) => LiveSocketLike;
86
+ /**
87
+ * ASK FOR SHIP'S CODEC BY NAME (FR-44): the platform socket sends
88
+ * `LIVE_SUBPROTOCOL` as its WebSocket subprotocol. Off by default,
89
+ * because a browser fails the handshake with a server that does not
90
+ * answer it; `serveStore` answers it, and a Worker answers it with
91
+ * `liveSubprotocol(request)`. A `socket` factory is handed the same
92
+ * list and decides itself. `hello.wire` names the codec either way.
93
+ */
94
+ readonly subprotocol?: boolean;
95
+ /**
96
+ * THE DECLARATION A VERSION NAMES (FR-43). Told `{ t: "declaration" }`,
97
+ * or welcomed on a version other than the one it opened on, the client
98
+ * asks this for the app at the server's version and opens again on it:
99
+ * `onDeclaration` hands over the new remote store, and the calls still
100
+ * on the way are offered again under it, or refused in words. The host
101
+ * says how: a TS app imports its next declaration, a document-declared
102
+ * app fetches and compiles its document. Absent, the client reloads the
103
+ * page as `reload` does, carrying what it had not sent.
104
+ */
105
+ readonly resolveApp?: (version: number) => GraviewApp<AnySchema> | Promise<GraviewApp<AnySchema>>;
106
+ /**
107
+ * THE HOST'S BUILD THIS PAGE RUNS (FR-44), an opaque string said in
108
+ * `hello`. A server on another build keeps serving it; `onBuild` is told
109
+ * once, so the page can offer a reload when it suits the person.
110
+ */
111
+ readonly build?: string;
112
+ /**
113
+ * WHERE UNSENT CALLS WAIT ACROSS A RELOAD (FR-44). When the server
114
+ * answers `reload`, every call not yet answered is written to `storage`
115
+ * under `key`, and the next `openRemote` with the same key offers them
116
+ * again once it is open. `sessionStorage` in a page, a `Map` in a test.
117
+ * Without it they are refused in words before the page reloads.
118
+ */
119
+ readonly carry?: {
120
+ readonly storage: StorageLike;
121
+ readonly key: string;
122
+ };
123
+ /** How to reload the page when the server asks: `location.reload()` in a page by default. */
124
+ readonly reloadPage?: () => void;
80
125
  /** How long `openRemote({ live: true })` waits for the socket's welcome before it opens polling. 3000 by default. */
81
126
  readonly openTimeoutMs?: number;
82
127
  /**
@@ -85,7 +130,48 @@ export interface RemoteOptions<S extends AnySchema> {
85
130
  * turns one off or on reaches this client like any other.
86
131
  */
87
132
  readonly enabledModules?: readonly string[];
133
+ /**
134
+ * How long to wait before each attempt to open the socket again (FR-49):
135
+ * a function of the attempt (0 first, reset once a socket is welcomed)
136
+ * that answers in milliseconds, or `{ min, max, factor }` for the
137
+ * jittered exponential default — `min * factor ** attempt`, at most
138
+ * `max`, give or take a quarter. 250, 10000 and 2 unless said.
139
+ */
140
+ readonly backoff?: RemoteBackoff;
141
+ /**
142
+ * How often the same presence is said again down the socket, in
143
+ * milliseconds (FR-49). A new place is said at once; an unchanged one, on
144
+ * the heartbeat, no oftener than this. Half of `PRESENCE_TTL_MS` unless
145
+ * said. A polling client says it with every poll, so `pollMs` paces it.
146
+ */
147
+ readonly presenceEveryMs?: number;
148
+ /**
149
+ * Whether anybody is looking (FR-49). While it answers false, this
150
+ * client's presence is not said — on the socket or the poll — and lapses
151
+ * where others see it. In a page it is `document.visibilityState` unless
152
+ * said; where there is no document, always true.
153
+ */
154
+ readonly visible?: () => boolean;
155
+ }
156
+ /** How a client is reaching its server now (FR-49): not yet, yes, or not at the moment. */
157
+ export type RemoteStatus = "connecting" | "online" | "offline";
158
+ /** What happened to a client since it opened, as counts for a host's beacon (FR-49). */
159
+ export interface RemoteCounters {
160
+ /** Times it was offline and came back online. */
161
+ readonly reconnects: number;
162
+ /** Times the server's ops landed under calls of this client's still pending. */
163
+ readonly rebases: number;
164
+ /** Stale writes: calls of this client's refused because a field moved since it last saw it. */
165
+ readonly conflicts: number;
166
+ /** Times it could not catch up and took the server's whole state (FR-53). */
167
+ readonly resyncs: number;
88
168
  }
169
+ /** A reconnect delay (FR-49): the attempt's own, in ms, or the bounds of the jittered default. */
170
+ export type RemoteBackoff = ((attempt: number) => number) | {
171
+ readonly min?: number;
172
+ readonly max?: number;
173
+ readonly factor?: number;
174
+ };
89
175
  /** A stale write, as this client is told of it: the fields that moved, and the person's two answers. */
90
176
  export interface RemoteConflict {
91
177
  /** In words: "Ana changed label to “Book the church hall” while you were editing; yours was …" */
@@ -113,8 +199,13 @@ export interface RemoteStore<S extends AnySchema> {
113
199
  * The change is taken back before the listener runs; what is left is
114
200
  * saying so, in the policy's own words. A conflict nobody listens for
115
201
  * with `onConflict` is told here too, in its sentence.
202
+ *
203
+ * The second argument says why as a code a program can branch on
204
+ * (FR-46): `forbidden`, `missing`, `invalid` or `limit`, with `wouldNeed`
205
+ * when the policy knows who could. Busy is never told here: a change the
206
+ * host asked to wait is kept, and sent again (FR-45).
116
207
  */
117
- onRefusal(listener: (reason: string) => void): () => void;
208
+ onRefusal(listener: (sentence: string, refusal: RemoteRefusal) => void): () => void;
118
209
  /**
119
210
  * Told when a change this browser had already shown was refused as a
120
211
  * stale write (FR-05): somebody changed a field it changes since this
@@ -126,8 +217,34 @@ export interface RemoteStore<S extends AnySchema> {
126
217
  revision(node: string, field: string): number;
127
218
  /** The last op of the server's this client has. */
128
219
  seq(): number;
220
+ /**
221
+ * THIS CLIENT'S OWN KEY in who is here, as the server built it from the
222
+ * seat (FR-47): said in the socket's welcome, or in the answer to a poll's
223
+ * `here`. Undefined until one of them has, or from a server before it.
224
+ * Who is here, as `presence` tells it, never includes it.
225
+ */
226
+ participant(): string | undefined;
129
227
  /** How everybody else's ops reach this client now: pushed down the socket, or on the poll. */
130
228
  transport(): "socket" | "poll";
229
+ /**
230
+ * Whether the server is being reached (FR-49). `online` once a welcome or
231
+ * an answer has landed; `offline` while a socket that was welcomed is down
232
+ * and nothing has been heard since, or when a poll or a call does not
233
+ * reach the server. A live client is `connecting` until its socket is
234
+ * welcomed or its first poll lands. An answer that refuses is an answer:
235
+ * the server was reached.
236
+ */
237
+ status(): RemoteStatus;
238
+ /** Told each time the status changes — the offline banner's switch. Returns the way to stop listening. */
239
+ onStatus(listener: (status: RemoteStatus) => void): () => void;
240
+ /** How often this client reconnected, rebased, met a conflict and resynced — counts only. */
241
+ counters(): RemoteCounters;
242
+ /**
243
+ * The calls sent and not yet answered: shown here and waiting for the
244
+ * server's verdict. A call made while the server cannot be reached counts
245
+ * here until it is back and has answered; it is not taken back meanwhile.
246
+ */
247
+ pending(): number;
131
248
  /**
132
249
  * Resolves once every call sent so far has been answered — accepted and
133
250
  * landed, or refused and taken back. A browser never waits for this; a
@@ -142,8 +259,34 @@ export interface RemoteStore<S extends AnySchema> {
142
259
  * the log.
143
260
  */
144
261
  readonly presence: PresenceChannel;
262
+ /**
263
+ * THE DECLARATION CHANGED ON THE SERVER (FR-43): handed a new remote
264
+ * store, opened on the server's migrated state under the app
265
+ * `resolveApp` gave for `version`, with this one's unanswered calls
266
+ * offered again on it. This one is closed: mount the new one. A call
267
+ * that no longer fits is told on the new store's `onRefusal` (or this
268
+ * one's, when nobody listens there), in words.
269
+ */
270
+ onDeclaration(listener: (next: RemoteStore<AnySchema>, version: number) => void): () => void;
271
+ /**
272
+ * THE SERVER RUNS ANOTHER BUILD (FR-44): told once, with its build, when
273
+ * its welcome names one other than `build`. A listener added after it
274
+ * was noticed is told at once. The client keeps working.
275
+ */
276
+ onBuild(listener: (build: string) => void): () => void;
145
277
  close(): void;
146
278
  }
279
+ /** A refusal as the client is told it: the reason, the sentence and who could (FR-46). */
280
+ export type RemoteRefusal = WireRefusal;
281
+ /**
282
+ * WHAT `send` THROWS, AND WHAT A TAKEN-BACK CHANGE WAS REFUSED WITH: the
283
+ * server's sentence as the message, and `refusal` for a program to branch
284
+ * on (FR-46).
285
+ */
286
+ export declare class RemoteRefusedError extends Error {
287
+ readonly refusal: RemoteRefusal;
288
+ constructor(refusal: RemoteRefusal);
289
+ }
147
290
  export declare function openRemote<S extends AnySchema>(options: RemoteOptions<S>): Promise<RemoteStore<S>>;
148
291
  /**
149
292
  * A principal as the headers a TRUSTED server reads (`trustSeatHeaders`):
@@ -1 +1 @@
1
- {"version":3,"file":"remote.d.ts","sourceRoot":"","sources":["../src/remote.ts"],"names":[],"mappings":"AAAA,OAAO,EAML,KAAK,EAGL,KAAK,SAAS,EACd,KAAK,aAAa,EAElB,KAAK,UAAU,EACf,KAAK,YAAY,EACjB,KAAK,SAAS,EAEd,KAAK,eAAe,EACpB,KAAK,SAAS,EACd,KAAK,GAAG,EACT,MAAM,eAAe,CAAC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