Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
HTTP2
Search
Marcus Barcelos
May 11, 2016
Technology
110
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
HTTP2
Marcus Barcelos
May 11, 2016
More Decks by Marcus Barcelos
See All by Marcus Barcelos
TDC - Integração continua
mvlbarcelos
1
630
Arquitetando e evoluindo um ERP para a Nuvem
mvlbarcelos
1
310
Other Decks in Technology
See All in Technology
形式手法を使って仕様をコーディングしよう
mikanichinose
0
180
ビジネスを止めない技術的負債の返済のための戦略とその手法 - 技術的負債と向き合う / Complexity and Simplicity
soudai
PRO
3
640
Deep Data Security 機能解説
oracle4engineer
PRO
2
710
AI時代に必要な脅威モデリング― 変化の速度に負けない理解とリスク判断
masakane55
4
1.1k
AI駆動開発の時代になったのでトヨタ生産方式から見直す
terurou
0
170
AI時代だからこそ推したい!Gitコマンド再入門
munakata
0
150
Claude起点の仕様駆動開発
tanakaseiya
0
390
Datadog の学び方 - あるいは、オブザーバビリティを学ぶとは何か
mananyuki
1
490
AI時代のAPI開発を加速する品質ガードレール / API Quality Guardrails in the AI Era
yokawasa
0
150
インバスケット試験対策アプリを 作って見えたAIエージェント構築 ナレッジ2選
shichijoyuhi
1
130
freeeらしさをAIとともに作る / Creating the freee Experience with AI
ymrl
0
210
[AWS 秋のクラウドオペレーション祭り 2026]AWS DevOps Agentで変わるリリースと運用対応 ~リリース管理機能と Directed actions のご紹介~
furuton
3
990
Featured
See All Featured
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
How to Build an AI Search Optimization Roadmap - Criteria and Steps to Take #SEOIRL
aleyda
1
2.2k
The Cult of Friendly URLs
andyhume
79
7k
Organizational Design Perspectives: An Ontology of Organizational Design Elements
kimpetersen
PRO
1
840
Utilizing Notion as your number one productivity tool
mfonobong
4
610
[RailsConf 2023] Rails as a piece of cake
palkan
59
7.1k
We Have a Design System, Now What?
morganepeng
55
8.4k
Java REST API Framework Comparison - PWX 2021
mraible
34
9.7k
AI Search: Implications for SEO and How to Move Forward - #ShenzhenSEOConference
aleyda
1
1.4k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.3k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
203
76k
Transcript
pen4education Vamos falar sobre o futuro da Web: HTTP/2 Gabriell
Nascimento Marcus Barcelos Trilha Web @gabriellhrn @mvlbarcelos
pen4education Sysadmin DevOps Bluesoft Quem somos Gabriell
pen4education Arquiteto de soluções DevOps Bluesoft Quem somos Marcus Barcelos
pen4education Bluesoft
pen4education Bluesoft Labs
pen4education HTTP/0.9 1991 HTTP
pen4education Transferência de texto pela Internet (ASCII) HTTP/0.9 Funcionalidades
pen4education ➔ GET HTTP/0.9 Métodos
pen4education web em 1991 http://www.wired.co.uk/news/archive/2013-04/30/first-web-page http://arstechnica.com/information-technology/2013/04/first-website-ever-goes-back-online-on-the-open-webs-20th-birthday/
pen4education HTTP/0.9 1991 HTTP/1.0 1996 HTTP
pen4education ➔ Transferência de MIME ➔ Cabeçalhos ➔ Status codes
HTTP/1.0 Funcionalidades++
pen4education ➔ GET ➔ HEAD ➔ POST HTTP/1.0 Métodos
pen4education HTTP/0.9 1991 HTTP/1.0 HTTP/1.1 1996 1999 HTTP
pen4education ➔ Conexão persistente (keep alive) ➔ HTTP pipelining HTTP/1.1
Funcionalidades++
pen4education ➔ GET ➔ HEAD ➔ POST ➔ PUT ➔
DELETE HTTP/1.1 Métodos ➔ TRACE ➔ OPTIONS ➔ CONNECT ➔ PATCH
pen4education HTTP/0.9 1991 HTTP/1.0 HTTP/1.1 1996 1999 2009 SPDY SPDY
pen4education ➔ Carregamento 50% menor ➔ Compatibilidade com HTTP SPDY
Principais objetivos
pen4education HTTP/0.9 1991 HTTP/1.0 HTTP/1.1 1996 1999 2015 HTTP/2 HTTP
2009 SPDY
pen4education HTTP/2 (RFC 7540) + HPACK (RFC 7541)
pen4education ➔ Troca de mensagens binária ➔ Multiplexação HTTP/2 Funcionalidades++
pen4education ➔ Priorização de requisições ➔ Server push ➔ Compressão
de cabeçalho HTTP/2 Funcionalidades++
pen4education E por que um HTTP/2?
pen4education E por que um HTTP/2? HTTP/1.x não atende mais
pen4education ➔ Sites complexos ➔ Muitas requisições ➔ Mobile A
web atual
pen4education A web atual https://mobiforge.com/research-analysis/the-web-is-doom
pen4education HTTP/1.1 Boas práticas
pen4education ✓ Concatenação ✓ Sprites ✓ Domain sharding ✓ Cabeçalhos/Cookies
HTTP/1.1 Boas práticas ✓ CSS no topo ✓ JS no final ✓ Minificação ✓ Compressão (gzip)
pen4education HTTP/1.1 Diminuir requisições
pen4education ➔ Concatenar (CSS/JS) ➔ Sprites ➔ Domain sharding ◆
cdn1.bluesoft.com.br ◆ cdn2.bluesoft.com.br HTTP/1.1 Diminuir requisições
pen4education HTTP/1.1 Paralelismo: múltiplas conexões TCP Hi there! I’m HTTP/1.1
only :) https://h1.example.com Cliente Servidor
pen4education HTTP/1.1 Head of line blocking Hi there! I’m HTTP/1.1
only :) https://h1.example.com Cliente Servidor
pen4education HTTP/2 Multiplexação de mensagens
pen4education HTTP/2 Multiplexação de mensagens Hi there! I’m HTTP/2 :D
https://h2.example.com Cliente stream 7 DATA … stream 3 DATA stream 5 HEADERS stream 5 DATA stream 3 DATA Conexão HTTP/2 Servidor
$ nghttp -nv https://h2.example.com ... [ 0.009] recv HEADERS frame
<length=30, flags=0x04, stream_id=39> ; END_HEADERS (padlen=0) ; First response header [ 0.009] recv (stream_id=41) :status: 200 [ 0.009] recv (stream_id=41) content-length: 4864 [ 0.009] recv (stream_id=41) content-type: image/png [ 0.009] recv HEADERS frame <length=30, flags=0x04, stream_id=41> ; END_HEADERS (padlen=0) ; First response header [ 0.010] recv DATA frame <length=7456, flags=0x01, stream_id=39> ; END_STREAM [ 0.010] recv DATA frame <length=4864, flags=0x01, stream_id=41> ; END_STREAM [ 0.010] recv DATA frame <length=16384, flags=0x00, stream_id=43> [ 0.010] recv DATA frame <length=4883, flags=0x00, stream_id=45> ...
pen4education Multiplexação why it matters
pen4education Multiplexação why it matters
pen4education HTTP/1.1 Conexões HTTP 6.23s
pen4education HTTP/1.1 Conexões HTTP: domain sharding 2.17s
pen4education HTTP/2 Conexão com multiplexação 0.99s
pen4education HTTP/1.1 Priorização de requisições
pen4education ➔ CSS no topo ➔ JS no final HTTP/1.1
Priorização de requisições
pen4education HTTP/2 Priorização de requisições
pen4education Árvore de pesos e dependências HTTP/2 Priorização de requisições
pen4education HTTP/2 Priorização de requisições * A 1 B 8
C 8 D 12 E 4 A - main.css B - script.js C - style.css D - substyle.css E - favicon.ico
pen4education HTTP/1.1 Tamanho das requisições
pen4education ➔ Cabeçalhos e cookies HTTP/1.1 Tamanho das requisições
pen4education HTTP/2 Compressão de cabeçalho (HPACK)
pen4education HTTP/2 Compressão de cabeçalho Hi there! I’m HTTP/2 :D
https://h2.example.com Cliente Servidor stream 3 HEADERS 1 :method: GET 2 :path: /login 3 :scheme: https 1 :method: GET 2 :path: /home 3 :scheme: https
pen4education HTTP/2 Server push
pen4education HTTP/2 Server push Hi there! I’m HTTP/2 :D https://h2.example.com
Cliente Servidor
pen4education HTTP/2 Server push HTTP/2 https://blog.cloudflare.com/announcing-support-for-http-2-server-push-2/
pen4education HTTP/2 Server push HTTP/2 HTTP/2 + Server Push https://blog.cloudflare.com/announcing-support-for-http-2-server-push-2/
pen4education HTTP/2 Upgrade
pen4education TCP (HTTP) e TLS (HTTPS) HTTP/2 Mecanismo de upgrade
pen4education Na prática: HTTP/2 é com HTTPS
pen4education Resumindo...
pen4education ✓ Concatenação ✓ Sprites ✓ Domain sharding ✓ Cabeçalhos/Cookies
HTTP/1.1 Boas práticas ✓ CSS no topo ✓ JS no final ✓ Minificação ✓ Compressão (gzip)
pen4education ✗ Concatenação ✗ Sprites ✗ Domain sharding ✗ Cabeçalhos/Cookies
HTTP/2 Boas práticas ✗ CSS no topo ✗ JS no final ✓ Minificação ✓ Compressão (gzip)
pen4education HTTP/2 Suporte
pen4education ✓ Google Chrome ✓ Internet Explorer ✓ Microsoft Edge
✓ Mozilla Firefox ✓ Safari HTTP/2 Navegadores https://github.com/http2/http2-spec/wiki/Implementations https://en.wikipedia.org/wiki/Comparison_of_web_browsers#Protocol_support * Versões mais recentes
pen4education ✓ Apache HTTP Server 2.4.17+ ✓ Apache Tomcat 8.5+
✓ Microsoft IIS WinServer 2016 ✓ Nginx 1.9.5+ HTTP/2 Servidores web https://github.com/http2/http2-spec/wiki/Implementations https://en.wikipedia.org/wiki/HTTP/2#Software_and_services_supporting_HTTP.2F2
pen4education ✓ Akamai ✓ CloudFlare HTTP/2 CDNs https://en.wikipedia.org/wiki/HTTP/2#Software_and_services_supporting_HTTP.2F2
pen4education HTTP/2 To use or not to use?
pen4education Nginx http://labs.bluesoft.com.br/habilite-o-http2-no-seu- site-hoje/ Apache http://labs.bluesoft.com.br/habilite-o-http2-no-seu- site-agora-com-apache/ HTTP/2 Artigos
pen4education $ docker pull bluesoftbr/nginx-h2 $ docker pull bluesoftbr/httpd-h2 https://github.com/bluesoft/dockerfiles
HTTP/2 Imagens Docker
pen4education Obrigado! @gabriellhrn @mvlbarcelos bluesoft bluesoftbr http://labs.bluesoft.com.br