You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently desiredSize on ReadableStreamDefaultController and WritableStreamDefaultWriter always reflects the amount of queue space available. This is connected to how much buffering we use. However, a sink may have 324KB of space available in some internal buffer, invisible to the streams API and consumers of the streams API. It would be nice if writers to the stream could know that they should aim to write a 324KB chunk. Increasing the highWaterMark of the WritableStream doesn't do anything useful in this situation.
In another case, you might have an API where is optimal to write in 64KB chunks, but the value of desiredSize would go down when the queue is full, leading to writing sub-optimal small chunks.
One solution would be to provide a way that underlying sinks could override the value of desiredSize. An alternative would be to provide a differently-named attribute that hinted the optimal chunk size to use right now.
The text was updated successfully, but these errors were encountered:
Currently
desiredSize
on ReadableStreamDefaultController and WritableStreamDefaultWriter always reflects the amount of queue space available. This is connected to how much buffering we use. However, a sink may have 324KB of space available in some internal buffer, invisible to the streams API and consumers of the streams API. It would be nice if writers to the stream could know that they should aim to write a 324KB chunk. Increasing the highWaterMark of the WritableStream doesn't do anything useful in this situation.In another case, you might have an API where is optimal to write in 64KB chunks, but the value of desiredSize would go down when the queue is full, leading to writing sub-optimal small chunks.
One solution would be to provide a way that underlying sinks could override the value of
desiredSize
. An alternative would be to provide a differently-named attribute that hinted the optimal chunk size to use right now.The text was updated successfully, but these errors were encountered: