Sheetwrite

CAPABILITY / COLLABORATION PROTOCOL

Two clients, one protocol, no lost updates.

Two live clients against one sequencing server: ordered durable commits, duplicate acknowledgements, presence, offline queues that drain on reconnect, version-gap buffering, and conservative conflict recovery.

Clients
Two, fully isolated
Ordering
Server-sequenced versions
Durability
IndexedDB pending queues
Conflicts
Conservative rebase

LoadingStarting the in-page server…

Anaonline
Server version
v0
Pending
0
Committed total
Sees
  • no one yet
  1. Sync events appear here.
Bramonline
Server version
v0
Pending
0
Committed total
Sees
  • no one yet
  1. Sync events appear here.

In-page sequencing server

Head version v0

  1. Every commit request lands here with its sequencing decision.

Demo-onlyThis server lives in the page so the protocol is observable. It implements the same PersistenceAdapter + RemoteOperationSource pair your backend implements over its own transport and database.

Try itTake Bram offline, queue a few edits, and reconnect. Then hold a broadcast on Ana, commit from the server, and watch her conflict recover.

VERIFIED IN THIS SCENARIO

Every behavior above is the public contract.

  1. Convergence under ordering

    Every commit is sequenced once by the server and fanned out; both grids — including live formulas — converge to identical state.

  2. Loss without double-apply

    Drop an acknowledgement, retry with the same mutation id, and the server answers duplicate: applied exactly once, at the original version.

  3. Offline is a first-class state

    An offline client keeps committing into its durable IndexedDB queue; reconnecting drains the queue in order through the same protocol.

  4. Gaps and conflicts stay explicit

    Out-of-order broadcasts buffer until the gap closes; stale base versions surface as conflicts that recover through the documented rebase loop.

OWNERSHIP BOUNDARY

What Sheetwrite provides — and what your host owns.

Everything moving on this page is the real collaboration protocol running in your browser tab. The server is deliberately illustrative — the responsibilities below never move into Sheetwrite.

Sheetwriteships in the library
  • Sequencing protocol

    SyncCoordinator: optimistic local commits, ordered acknowledgements, echo deduplication, gap buffering, and fail-closed input limits.

  • Presence & conservative rebase

    PresenceCoordinator shares ephemeral selections; rebaseDocumentOperations transforms safe edits and reports explicit conflicts instead of guessing.

PersistenceAdapter + RemoteOperationSource

Your hostyou implement and deploy
  • Transport

    The in-page server here stands in for your WebSocket or realtime channel. Sheetwrite ships protocol contracts, not network code.

  • Durable server storage

    Server-side document state, revision history, and backups live in your database behind your PersistenceAdapter implementation.

  • Auth, authorization & deployment

    Who a collaborator is, what they may edit, and where the service runs are host decisions — presence identity is advisory UI state, never access control.