Open coolreader18 opened 2 months ago
Outstanding TODOs:
Identity
has been changed to use the actual spacetimedb_lib::Identity
type.(Plus make the tests and lints pass, obviously.)
Additional question: how do we negotiate protocol version now? I believe protobuf transparently supports changing schemas for the most part by making everything optional, but I don't think bsatn has anything like that. We should at minimum send a version number I think, either once per session or once per message...
I think we should use the WebSocket protocol for this. In the past we've been quite lax about updating the WebSocket protocol name, continuing to use v1.bin.spacetimedb
even after breaking changes, but once this merges and we start providing real stability guarantees, we'll need to update the version prefix whenever we change the schema.
mm, that's a good point Phoebe - I was planning on putting a enum { V1(MessageV1) }
around the message but that's a better idea.
Should we update the WebSocket text/JSON protocol to use the new schema, or maintain the existing JSON schema? I would prefer the former, but that raises the barrier to merging this PR - we'll have to make more changes in the SDKs, and also update the website.
Update: I now lean towards not migrating JSON to use the new schema, at least in the short term.
Description of Changes
Replace protobuf with bsatn.
API and ABI breaking changes
API breaking for binary clients.
Expected complexity level and risk
3 (lotsa churn)
Testing
This is dependent on the C# sdk getting updated. I feel confident that CI + a botstest with the updated sdk would get everything.