PyDocs

Nav

Networking and Interprocess Communication

WriteTransport.set_write_buffer_limits

asyncio

method of WriteTransport (source) not WASI
  • WriteTransport.set_write_buffer_limits(high=None, low=None)
Set the high- and low-water limits for write flow control.

These two values control when to call the protocol's
pause_writing() and resume_writing() methods.  If specified,
the low-water limit must be less than or equal to the
high-water limit.  Neither value can be negative.

The defaults are implementation-specific.  If only the
high-water limit is given, the low-water limit defaults to an
implementation-specific value less than or equal to the
high-water limit.  Setting high to zero forces low to zero as
well, and causes pause_writing() to be called whenever the
buffer becomes non-empty.  Setting low to zero causes
resume_writing() to be called only once the buffer is empty.
Use of zero for either limit is generally sub-optimal as it
reduces opportunities for doing I/O and computation
concurrently.
0 Examples
No examples for asyncio/WriteTransport.set_write_buffer_limits.
See Also
No see-alsos for asyncio/WriteTransport.set_write_buffer_limits
0 Notes
No notes for WriteTransport.set_write_buffer_limits