Hello,
I have started to implement websockets in a branch by reading the
internet-draft at:
http://tools.ietf.org/html/draft-hixie-thewebsocketprotocol-54
I have only done java based clients for now.
Currently UTF8 is the only frame format for jscript clients.
A later version of the protocol will allow for binary jscript data frames,
when the underlying client side API has been upgraded to handle it.
The general design is to not enforce overheads or constraints on the user
layer.
Not using workerthreads for fast event responses or choosing to not verify
that bytes are UTF8 on all text messages are examples of this.
Can verify that a message is UTF8 once at a point in time you choose or not
at all and then send the still existing bytes directly to others.
This is not fully implemented yet.
Major things thats missing:
SSL .
proxy client.
part of handshake. 25% or so.
things i forgot.
Not part of spec, but still missing:
Connect timeout config and event.
Idle timeout config and event.
Better WebSocketListener.onMessage() parameter datastructure, allowing for
direct access to the ByteBuffer in its frame format while also convenient
methods to get UTF8 Strings or just a faster UTF8 verify on the bytes.
Good designed public api and jdoc.
Extras to make serverside service implementers life easier.
Testing against jscript client.
Testing against third party client and server implementations.
Extensive unit tests, ensuring all corner cases work.
Pluggable load balancing algorithm for selector threads.
Implement a more optimal buffer strategy.
Http request parser that don't hang the thread, will have to write it from
scratch,
to be used standalone or at dedicated port using an accept selector.
Minor things that is missing or needs to be evaluated, is in the code as
//TODO:s
Please give constructive feedback and ideas in general,
Help with QA in all aspects is in great need. I give free cold beers !
--
regards
gustav trede