Web Streams at the Edge
deno.com
deno.com
I’m not sure what to expect from the websocket example, but I just see “request isn't trying to upgrade to websocket.”
As for the WS example: it is a WebSocket endpoint, so you must connect to it using `new WebSocket` :-)
- Stream-process JSONL.
- Replace strings for translations while streaming.
- Stream Video.
I guess you don't mean WebSockets, since that has a myriad of use-cases, everything from chats, games, charts, feeds etc.
1. An enemy is hiding behind a corner. The player takes a step and sees the enemy.
If the client knew the enemy was there, the player could cheat. If the client didn't know, the player would see the enemy with a delay. The proxy can share the hidden state at exactly the right moment.
2. When the player thinks that their shot hit the target, but the central server disagrees.
If the client is trusted to determine the answer, the player could cheat again. If the client isn't trusted, the player would sometimes see a hit that didn't harm the target. The proxy can make the decision and provide accurate feedback immediately.