valyala / httpteleport

Transfer 10Gbps http traffic over 1Gbps networks :)
MIT License
458 stars 38 forks source link

From my understanding of httptp, will we run out of memory if using indelay? #8

Open unisqu opened 6 years ago

unisqu commented 6 years ago
  1. If the data sent is a lot, will it run out of memory if using indelay with a large value? e.g. 5 seconds

  2. are the data sent in sequence or randomly batched?

valyala commented 6 years ago
  1. No. There is a fixed-size buffer per each connection, which prevents from memory overflow. The buffer is flushed before the delay timeout if it becomes full.
  2. Requests are sent in sequence. teleport protocol allows receiving responses in arbitrary order. http protocol receives responses in requests' order.