Implement a binary protocol instead of sending JSON over WebSockets #103
Labels
No labels
bug
c:haku
c:rkgk backend
c:rkgk frontend
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: liquidex/rkgk#103
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
With how frequently rkgk sends out events, using JSON is extremely inefficient. It would be healthier to implement a binary protocol that doesn't repeat names as often.
I say "implement" and not "use" because I'd like a lightweight, holistic solution that works well for our use case. For instance we don't need version compatibility, as the app refreshes for everyone once we upgrade the server, and then clients download the updated version.
On the Rust side, we'll probably implement a custom serializer/deserializer, and we'll also generate code to handle the binary magic on the JavaScript side.