Current time: 12-07-2019, 09:49 PM Hello There, Guest! (LoginRegister)

Post Reply 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
TLS/HTTP/2 slower than TCP/HTTP/1.1
03-09-2016, 09:16 AM
Post: #1
TLS/HTTP/2 slower than TCP/HTTP/1.1
Hi folks,

Have to say I'm a bit surprised to see when you have a site with a lot of requests HTTP/1.1 is still faster than HTTP/2 (obviously with HTTPS):

HTTP:
http://www.webpagetest.org/result/160308...1/details/

HTTP/2 (HTTPS/TLS):
http://www.webpagetest.org/result/160308...1/details/

For example take the same request for an image:
- request 25 on the first page (HTTP)
- request 19 on the second page (HTTP/2).

Almost seems like it's the overhead of encrypting the files ?

Because it's the same H2O webserver talking to Varnish with all files cached.

Is this normal / to be expected ?

I would love to get the opinion of someone else on this.

Have a good day.
Visit this user's website Find all posts by this user
Quote this message in a reply
03-10-2016, 02:52 AM
Post: #2
RE: TLS/HTTP/2 slower than TCP/HTTP/1.1
Try running ~9 tests and preferably from the "Dulles Thinkpad" test location. It's really hard to say with one sample and the Amsterdam server looks like it is seriously CPU constrained loading the page.

There's a good chunk of time when loading the page where the network is idle and it looks like it's entirely JS-bound. Looking at the bandwidth charts, the H2 one looks like it more cleanly and consistently fills the connection so I'd be more inclined to think that it might be from something else.
Visit this user's website Find all posts by this user
Quote this message in a reply
03-10-2016, 03:27 AM
Post: #3
RE: TLS/HTTP/2 slower than TCP/HTTP/1.1
(03-10-2016 02:52 AM)pmeenan Wrote:  Try running ~9 tests and preferably from the "Dulles Thinkpad" test location. It's really hard to say with one sample and the Amsterdam server looks like it is seriously CPU constrained loading the page.

There's a good chunk of time when loading the page where the network is idle and it looks like it's entirely JS-bound. Looking at the bandwidth charts, the H2 one looks like it more cleanly and consistently fills the connection so I'd be more inclined to think that it might be from something else.

Thank you very much, will do that.

I've also been looking into it and fix some minor things.

These ones already look a lot more like what you'd expect:

TCP/HTTP/1.1:
http://www.webpagetest.org/result/160309...1/details/
http://www.webpagetest.org/result/160309...1/details/

TLS/HTTP/2
http://www.webpagetest.org/result/160309...1/details/
http://www.webpagetest.org/result/160309...1/details/
Visit this user's website Find all posts by this user
Quote this message in a reply
03-10-2016, 11:40 AM
Post: #4
RE: TLS/HTTP/2 slower than TCP/HTTP/1.1
Lennie, a few of my colleagues where talking about this topic today. A possible reason of why h2 is slower than h1 could be a small initial TCP congestion window.

I am not sure how the WPT servers have the TCP parameters configured in the kernel, but a small congestion window will favor h1 which opens 6-8 TCP connections vs h2 which opens only 1.
Find all posts by this user
Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)