I agree with @cata here.
You also introduce a forced 200ms of latency with batch sending.
I also would propose a proper protocol like RTP for network transport, which helps with handling problems during transport.
To support fully streaming operation in the browser, I think we would need to switch to using web sockets. Doable, but complicated and may not be worth it?
200ms of latency isn’t ideal, but also isn’t that bad. The design does not require minimizing latency, just keeping it reasonably small.
You can do that, but then you need the server to retain per-client state. Everything stays much simpler if we don’t!
I agree with @cata here. You also introduce a forced 200ms of latency with batch sending. I also would propose a proper protocol like RTP for network transport, which helps with handling problems during transport.
To support fully streaming operation in the browser, I think we would need to switch to using web sockets. Doable, but complicated and may not be worth it?
200ms of latency isn’t ideal, but also isn’t that bad. The design does not require minimizing latency, just keeping it reasonably small.