Number of changes queued while disconnected, waiting to be replayed (see server.websocket.autoReconnect).
Optionalevent: ClientEventProtectedabandonFails the queued changes and the requests waiting for the reconnection.
ProtectedanswerSettles the oldest request waiting on key, or all of them, with the server's answer.
ProtectedassertProtectedbuildProtectedbuildProtectedbuildProtectedbuildProtectedbuildProtectedbuildProtectedbuildProtectedbuildProtectedchunkProtectedclearProtectedclearProtectedclearProtectedcloseProtectedconnectProtecteddispatchProtecteddrainProtectedenqueueOptionalrequestedMimeTypes: string[]ProtectedfailA handshake step failed: init() waits on initialized, so it must hear of it, not only the error listeners
ProtectedgiveReconnection attempts exhausted: reject the queue and the requests waiting for the reconnection, emit "error", and reset the attempt counter so the next change (or drop) gets a fresh retry budget.
ProtectedinitProtectedisProtectedisA network drop (1006, also what each failed reconnection attempt reports) once connected,
with autoReconnect on: the changes are kept and replayed, so it is a state, not an error.
Reported as an error, it opened the canvas error modal over the ink every few seconds.
ProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmanageProtectedmergeProtectedmessageProtectedonRuns once per successful connection, whoever triggered it. Cancels any reconnect attempt still scheduled, replays the offline queue, and only then lets the requests waiting for the reconnection go: one sent before the replay would read content the server does not have yet.
ProtectedopenProtectedrejectProtectedrequestProtectedresetProtectedresolveSettle completion-signal promises (no payload) as resolved rather than rejected — used on a
deliberate close (close()/newSession()), which isn't an error: the operation the caller
was waiting on (init, idle) is simply moot now, not failed.
ProtectedscheduleProtectedsendSends a change to the content. While disconnected it is queued and replayed in order once reconnected, rather than lost: the server must end up with every change the canvas made.
ProtectedsendOptionalrequestedMimeTypes: string[]ProtectedsendSends one step of the server's history; nothing when it changes nothing.
ProtectedsendProtectedsendSends build's message once per group of strokeIds that fits in a frame; nothing for no id.
ProtectedsettleSettles every request waiting on the server: none is answered now, so a later answer must not settle another one
ProtectedstartProtectedtoProtectedwaitRegisters a request under the key its answer will be matched on, after those already waiting there.
Called once the request is sent, not before: a request still waiting for a reconnection must not
be failed by the close of a reconnection attempt. The answer cannot be missed — it arrives in a
later message event, after the microtask that registers it.
ProtectedwaitResolves once the reconnect loop has reconnected and replayed the queue; rejects if it gives up.
ProtectedboundProtectedboundProtectedboundProtectedclosingProtectedconnectingProtected OptionalcurrentProtected OptionalcurrentProtectedexportProtectedhasSet on the first successful connection: a drop after it is recoverable, one before is not
ProtectedloggerProtectedmaxLargest message sent in one frame, in characters of its JSON. The backend closes the connection (1009) on an incoming message over 500 KB; half of that leaves room to spare.
ProtectedmessageRoutes each message the server sends; overriding a manage* method changes what its entry does.
ProtectedofflineProtectedpendingEvery request waiting on the server, under the key its answer is matched on (gesture:<strokeId>,
export:<mimeType>, math:<action>:<blockId>, idle, support), oldest first: the server
answers the requests of one key in order.
ProtectedpingProtected OptionalpingProtectedreconnectProtected OptionalreconnectionSettled once the reconnect loop has reconnected and replayed the queue, or has given up.
Protected OptionalreconnectProtected OptionalsessionProtectedsocket
True while the connection is down after a first one succeeded, whether changes are queued or not; false again once reconnected.
offlineQueueLengthtells how many changes wait.