The backend server for Gumnut's session host, which basically provides centralized OT (Operational Transforms). Maybe CRDT one day, but for now it's OT.
In v1, everyone ends up on the same server. So we can probably have a public WebSocket/SSE that also cares about auth.
The design of this is broadly, a Go server which runs Node internally to manage sessions. Each session is run by a JS controller (at a version etc) and is snapshotted to a database every 'occasionally'.
Sessions are real things, they represent state provided to us by clients which they wish to edit; they don't appear from nothing, even for "create new thing", we expect to get some initial payload. That payload might arrive multiple times (race conditions). If it's not the initial payload, maybe we update the current state - we "missed" something that's canonical.
Q: do we combine that initial payload with our view of history of that object (e.g., attribution). : A: Probably not for v1; we clear object state and the initial state is always "server initiated". The edit session stores attribution but may not announce it.
Q: What does the initial payload look like : A: It has to be "developer-friendly", so probably a big JSON blob
- some special-cases?