[whatwg] WebSocket bufferedAmount includes overhead or not

Anne van Kesteren annevk at opera.com
Thu Mar 25 08:55:32 PDT 2010

On Thu, 25 Mar 2010 16:35:19 +0100, Olli Pettay <Olli.Pettay at helsinki.fi>  
> On 3/25/10 4:25 PM, Niklas Beischer wrote:
>> Easy. The bufferedAmount is: "The amount of bytes waiting to be
>> transferred, including protocol overhead".
> That doesn't define exactly what the bufferedAmount means and what
> kinds of values are expected.
> What I'd expect the API to tell me is, for example, that if I call
> ws.send(foo), and nothing is yet sent over the network, what is the
> exact value of bufferedAmount.
> Again, I'd really wish to keep the API to work reasonable similar
> way as XHR+progress events where protocol overhead isn't reported.

Why? Progress events are completely different from this. This is about not  
saturating the network with too much data; it makes sense if the actual  
amount of data that is going to hit the network is known. (Yes, I changed  
my mind.)

Anne van Kesteren

More information about the whatwg mailing list