-
Adrien Nader authored
Until now, communication between clients and server relied on eliom, which in turn relies on HTTP requests. However, there is no ordering between requests and eliom might do several of them in parallel. This broke an assumption in prose (namely that client messages server arrive in order to the server) and garbled content (typically cursor jumps and character permutations). There is no way to avoid that with HTTP without doing all requests in parallel and inducing massive latency (possibly also with a throughput that is moreover too small). Switching to websockets makes solving this a breeze however : there is a single bi-directional communication channel which preservers ordering and also has lower latency and bandwidth usage. It just works. The main downside is that we're not using automagic eliom stuff for communication and we have to do a bit of serialisation ourselves but it is still simple and the messages can be handled nice...
ade82037