raku-community-modules / HTTP-Server-Async

Raku HTTP::Server::Async
Artistic License 2.0
18 stars 15 forks source link

Websockets #1

Closed tony-o closed 7 years ago

tony-o commented 10 years ago

Support them.

via TimoTimo

timo commented 10 years ago

Right now I'm toying with implementing websockets by giving a handler a way to "take over" the socket and shut down the "async read loop" thingie we have in the server.

I'd probably implement websockets in a whole separate module, as it pulls in at least Digest and MIME::Base64 for the handshake ...

timo commented 10 years ago

actually, could you stop by on irc some time soon so that we can discuss how to do the hand-over of the socket properly? i can't seem to find a good way to properly do it by re-tapping, and jnthn advised against that anyway ...

tony-o commented 10 years ago

@timo checkout /examples/connection_hijack.pl6 for an example of how to hijack the connection (includes previously gathered data)