Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
HTTP/1.1 vs HTTP/2
Ragnar Lönn, Load Impact
ragnar@loadimpact.com
@ragnarlonn
a performance analysis
@loadimpact
Load. . .Impact?
● LOAD TESTING SAAS
● LAUNCHED 2009
● 150,000+ ACCOUNTS
● 1.5M+ LOAD TESTS
● APPLICATION-POSITIVE
Part 1: The protocol
What is the problem?
Source: Mike Belshe, Google
Load time and delay
Source: Mike Belshe, Google
Some history
1996
● Web pages were tiny
● Internet bandwidth was tinier
● HTTP/1.0 spec released (RFC1945)
● Work started ...
Page load circa 1996
Page composition
Page load today
Some more history
1997
● HTTP/1.1 spec released (RFC2068)
● A lot of stuff already implemented…
● Some performance improve...
Connection re-use
Moar connections!
Pipelining - if it worked
Performance optimizations
a.k.a. “ugly hacks”
● Spriting
● Inlining
● Concatenating
● Sharding
Spriting
Performance optimizations
a.k.a. “ugly hacks”
● Spriting
● Inlining
● Concatenating
● Sharding Sharding
GET host1.domain.c...
Ugh.
Yes. So what if there was a protocol that:
● ...was less sensitive to network delay
● ...fixed pipelining and the hea...
HTTP/2 multiplexing
Multiplexing
Multiplexing
HTTP/2 at a glance
● HTTP/2 is binary and (mostly) encrypted
● “Upgrade:” header or TLS ALPN negotiation
● Multiplexing is...
HTTP/2 penetration
● >70% of installed browsers support HTTP/2
HTTP/2 server side
HTTP/2 penetration
● 24% of Firefox traffic is HTTP/2
● 18% of Alexa top 500 support HTTP/2
Objective:
Try to get a sense of real-world
performance impact of going from
HTTP/1.1 to HTTP/2
Part 2: The experiment
● Choose a well-known site
● Download all resources used by main page
● Host everything locally, in controlled
environment...
● ~230-240 resources to get to onload()
● ...but “only” ~10 javascript files
● ~10 unique source hosts
● ~7 Mbyte data
Sit...
MacOS X 10.10.3 (4 CPU cores, 16G RAM)
VMware Fusion
Linux 3.19.0-25 (Ubuntu)
2 CPU cores, 2G RAM
● Nginx 1.9.5/http2
● Sh...
Test results
50-70% reduced load time
-66%
Test results
● HTTP/2 implementations still in their infancy
● Sites are optimized for HTTP/1.1
● Our lab setup is not 100% realistic
S...
http2.loadimpact.com
Code @ https://github.com/loadimpact
Coming soon
@loadimpact
Upcoming SlideShare
Loading in …5
×

O'Reilly Fluent Conference: HTTP/1.1 vs. HTTP/2

995 views

Published on

Load Impact founder Ragnar Lönn presented the results from his study on HTTP/2 at the O'Reilly Fluent Conference 2016 in San Francisco. If you'd like to chat with us about HTTP/2, reach out on Twitter: @LoadImpact.

Published in: Technology
  • DOWNLOAD FULL. BOOKS INTO AVAILABLE FORMAT ......................................................................................................................... ......................................................................................................................... 1.DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... 1.DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... 1.DOWNLOAD FULL. PDF EBOOK here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... 1.DOWNLOAD FULL. EPUB Ebook here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... 1.DOWNLOAD FULL. doc Ebook here { https://tinyurl.com/y8nn3gmc } ......................................................................................................................... ......................................................................................................................... ......................................................................................................................... .............. Browse by Genre Available eBooks ......................................................................................................................... Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult,
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here

O'Reilly Fluent Conference: HTTP/1.1 vs. HTTP/2

  1. 1. HTTP/1.1 vs HTTP/2 Ragnar Lönn, Load Impact ragnar@loadimpact.com @ragnarlonn a performance analysis @loadimpact
  2. 2. Load. . .Impact? ● LOAD TESTING SAAS ● LAUNCHED 2009 ● 150,000+ ACCOUNTS ● 1.5M+ LOAD TESTS ● APPLICATION-POSITIVE
  3. 3. Part 1: The protocol
  4. 4. What is the problem? Source: Mike Belshe, Google
  5. 5. Load time and delay Source: Mike Belshe, Google
  6. 6. Some history 1996 ● Web pages were tiny ● Internet bandwidth was tinier ● HTTP/1.0 spec released (RFC1945) ● Work started on HTTP/1.1
  7. 7. Page load circa 1996
  8. 8. Page composition
  9. 9. Page load today
  10. 10. Some more history 1997 ● HTTP/1.1 spec released (RFC2068) ● A lot of stuff already implemented… ● Some performance improvements Pipelining Connection re-use Improved caching Range requests
  11. 11. Connection re-use
  12. 12. Moar connections!
  13. 13. Pipelining - if it worked
  14. 14. Performance optimizations a.k.a. “ugly hacks” ● Spriting ● Inlining ● Concatenating ● Sharding Spriting
  15. 15. Performance optimizations a.k.a. “ugly hacks” ● Spriting ● Inlining ● Concatenating ● Sharding Sharding GET host1.domain.com/resourceA GET host2.domain.com/resourceB GET host3.domain.com/resourceC ...
  16. 16. Ugh. Yes. So what if there was a protocol that: ● ...was less sensitive to network delay ● ...fixed pipelining and the head of line blocking ● ...performed well regardless of the number of TCP connections used ● ...used the same addressing/URL schemes etc for compatibility with HTTP 1.1
  17. 17. HTTP/2 multiplexing
  18. 18. Multiplexing
  19. 19. Multiplexing
  20. 20. HTTP/2 at a glance ● HTTP/2 is binary and (mostly) encrypted ● “Upgrade:” header or TLS ALPN negotiation ● Multiplexing is done with “streams” ○ Streams can be prioritized, re-prioritized and cancelled at any time ○ Streams can have dependencies ○ Streams have individual flow control ● Headers are compressed ● Servers can push content to clients
  21. 21. HTTP/2 penetration ● >70% of installed browsers support HTTP/2
  22. 22. HTTP/2 server side
  23. 23. HTTP/2 penetration ● 24% of Firefox traffic is HTTP/2 ● 18% of Alexa top 500 support HTTP/2
  24. 24. Objective: Try to get a sense of real-world performance impact of going from HTTP/1.1 to HTTP/2 Part 2: The experiment
  25. 25. ● Choose a well-known site ● Download all resources used by main page ● Host everything locally, in controlled environment ● Measure load times while simulating different network characteristics Approach
  26. 26. ● ~230-240 resources to get to onload() ● ...but “only” ~10 javascript files ● ~10 unique source hosts ● ~7 Mbyte data Site: www.amazon.com
  27. 27. MacOS X 10.10.3 (4 CPU cores, 16G RAM) VMware Fusion Linux 3.19.0-25 (Ubuntu) 2 CPU cores, 2G RAM ● Nginx 1.9.5/http2 ● Shimmer Cat 0.1 ● Linux Netem eth0:1 … … ... eth0:n Chrome The setup
  28. 28. Test results
  29. 29. 50-70% reduced load time -66% Test results
  30. 30. ● HTTP/2 implementations still in their infancy ● Sites are optimized for HTTP/1.1 ● Our lab setup is not 100% realistic So who knows… But still, hey - 60%! But remember:
  31. 31. http2.loadimpact.com Code @ https://github.com/loadimpact Coming soon @loadimpact

×