I'm one the three CS grad students working on WebSocket (along with Petr Praus).
Just wanted to give an update on our progress, to let you know what we're working on: Adding support for fragmented payloads: Right now, after receiving a frame, StreamInbound unmasks the payload in a WsInputStream and passes it up to the servlet via onBinaryData()/onTextData(). To support fragmented frames, we add an intermediate step: after unmasking the payload, write it to a PipedOutputStream connected to a PipedInputStream that we pass upward via onBinaryData()/onTextData(). When the next fragment arrives, keep streaming data through the pipe. This has the advantage of also allowing us to stream huge payloads (RFC 6455 allows for a 64-bit extended length field---way too much data to buffer in memory all at once). It has the minor disadvantage of breaking the ByteBuffer wrappers from MessageInbound (we can still use them for small payloads if we buffer fragments in memory) I'm working on a patch that implements this...maybe a day or two. I'd appreciate any early criticism you may have---otherwise I mainly just want to prevent duplicate work by explaining what we're up to. Cheers, Jonathan Drake