On Wed, Aug 1, 2012 at 6:51 PM, Glenn Adams <glenn@skynav.com> wrote:
> I'm questioning defining a "LazyBlob" that is solely usable with XHR. It
> would be better to have a more generic version IMO.
>
Websockets have no content semantics, therefore any lazy content
negotiating reader cannot deal with websockets unless an additional
application layer protocol and implementation on the server side is
introduced, something that does not exist for websockets otherwise. You
could for instance implement HTTP over websockets to get the content
semantics, and if your server gets a websocket request, it could be proxied
to a domain socket which happend to have a webserver listening which would
understand the HTTP request and deliver the resource/range.
Now instead of implementing HTTP over websockets over HTTP over sockets,
you could just use XHRs which implement HTTP over sockets. Which is why
generalising lazy readers to websockets does not make sense.