tatsuhiro-t / spdylay

The experimental SPDY protocol version 2, 3 and 3.1 implementation in C
http://tatsuhiro-t.github.io/spdylay/
MIT License
603 stars 102 forks source link

Proxy slow when download file #69

Closed nutinshell closed 11 years ago

nutinshell commented 11 years ago

By using Chrome with SPDY proxy, when downloading big file at high speed, browsing web pages become very slow, is this the unknown bug? Seems like issue: https://github.com/indutny/node-spdy/commit/be33b5a49addd993d8e2197d7ae0c245cc1f41b3 but I'm not sure.

tatsuhiro-t commented 11 years ago

I don't know what the node-spdy commit does either, but this issue is inherent problem of simple SPDY priority mechanism and if the priority is equal, they are raced and not interleaved nicely. Here is the patch to make DATA frames interleave more frequently: https://gist.github.com/tatsuhiro-t/5643313

Could you try this patch and give us your feedback?

nutinshell commented 11 years ago

Thanks. The node-spdy commit fixed a very same issue like this, so I wonder it may happen on shrpx. I tried the patch, seems much better, but Chrome still has great web pages latency when downloading file.

tatsuhiro-t commented 11 years ago

Updated the patch to give lower priority streams more chance to output https://gist.github.com/tatsuhiro-t/5643313

nutinshell commented 11 years ago

Hi, it gets better, but still very different with TLS proxy, downloading file has no impact to web pages browsing. Maybe it's part of Chrome's issue.

tatsuhiro-t commented 11 years ago

Do you mean stud by TLS proxy? Then yes, it is different because TLS proxy uses multiple connections: one for downloading large file and others for web contents. On the other hand, chrome normally uses just 1 connection to SPDY proxy and all traffic goes through it. If the patch goes well, I'll push the changes to the repo.

nutinshell commented 11 years ago

Yes, it's stud TLS. The patch makes better, thanks.

tatsuhiro-t commented 11 years ago

The change was committed. Let's close the issue.