On Sun, 27 May 2012 18:53:31 +0700
Henrik Sarvell <hsarv...@gmail.com> wrote:

> Google couldn't show me any prior discussions of websockets and
> picolisp.
> 
> Is it too early to start thinking about this maybe, seems like the
> spec/ref is still changing a little bit too fast/much atm?
> 
> http://en.wikipedia.org/wiki/WebSocket
> 
> http://tools.ietf.org/html/rfc6455
> 
> C lib: http://git.warmcat.com/cgi-bin/cgit/libwebsockets/
> 
> It came up today when I started to think about how crude file uploads
> via http is with no way of knowing the progress, but they can be used
> for much much more than fancy uploading interfaces of course.
> 
> Having looked a bit at the ref ( http://tools.ietf.org/html/rfc6455 )
> it seems to me that it looks quite straight forward.
> 
> The question is, what is easier/more efficient, implementing this from
> scratch or with the help of the C lib and native? That is the question
> that maybe someone more experienced in C/in general than me can
> answer?

I guess i should have posted this here before:
https://bitbucket.org/cyborgar/web.l/src/249fe9f5c7d8/web/sockets.l

That implements the RFC almost completely (there's no much
implementation of the error code thingamajig because actually browsers
don't even implement ping/pong correctly yet!). The implementation is
in pure lisp, but it could be accelerated with a C library (actually
the only thing to accelerate is the xor descrambling, could be done in
an 'in-like environment). The webtest.l in the root of the repo provides
a (ugly) chat server example using my web.l framework. Sorry if the code
is not very elegant but I didn't devote that much time to that example.

Here's the documentation of that module:
https://bitbucket.org/cyborgar/web.l/wiki/Sockets

Also, the spec is pretty much set in stone, at least as far as the IETF
is concerned, RFC 6455 is a standards track document.

Cheers,
José
--
UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe

Reply via email to