twitter-archive/CocoaSPDY

Consider breaking up large data sends to prevent priority inversion

kgoodier opened this issue · 0 comments

In SPDYSession, in _sendData, the entire input stream is sent in a tight loop, assuming:

  1. The send window never closes
  2. The input stream supplies data

It's possible that a large upload on a slow network will block higher-priority requests that come in after the data upload has started. By breaking up large uploads into multiple data frames and processing any higher-priority operations in between, this priority inversion may be avoided.