Diese Präsentation wurde erfolgreich gemeldet.
Die SlideShare-Präsentation wird heruntergeladen. ×
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Anzeige
Nächste SlideShare
AMC Minor Technical Issues
AMC Minor Technical Issues
Wird geladen in …3
×

Hier ansehen

1 von 11 Anzeige

Weitere Verwandte Inhalte

Diashows für Sie (18)

Ähnlich wie HTTP/2 Server Push (20)

Anzeige

Aktuellste (20)

HTTP/2 Server Push

  1. 1. Apache Traffic Server HTTP/2 Server Push Masakazu Kitajo maskit@apache.org
  2. 2. What is Server Push? • One of the features of HTTP/2 • Allows sending resources to a client before the client requests them • Avoids additional round trips • May reduce time to first paint • if we could use it wisely
  3. 3. How does it work? Server Push GET /index.html GET /index.html Client Intermediate Origin server index.html index.html
  4. 4. How can we use it on TS? • TSHttpTxnServerPush • Introduced since 7.0 • Experimental • An example plugin is available #include <ts/experimental.h> void TSHttpTxnServerPush(TSHttpTxn txnp, const char *url, int url_len)
  5. 5. What will happen inside? Client Http2Stream PluginHttpSM TSHttpTxnServerPush() hook->invoke() Http2ClientSession send_push_promise_frame() PUSH_PROMISE HEADERS send_request() handleEvent() send_request() handleEvent() new_transaction() new_transaction() hook->invoke()
  6. 6. What will be a problem? Server Push GET /index.html GET /index.html ? We don’t know which resources we should push. The client may already have the resource. The push may delay the response from an origin.
  7. 7. What can we do? • Use Manifest files • Use Link header • Use Link element in a HTML document • Use Cache Digests (a.k.a CASPER) • Also needs client side implementation • Use AI (machine learning) Simple Complex
  8. 8. Future plan • Add experimental plugins • Add Server Push metrics (maybe 7.1.0) • Brush up the API • Show some results in the next summit
  9. 9. Summary • Server Push MAY increase performance • Server Push CAN decrease performance • Server Push API is available since TS 7.0 • Server Push may be too complicated for human beings WE NEED YOUR FEEDBACK!
  10. 10. Thank you
  11. 11. References • HTTP/2 Server Push • https://tools.ietf.org/html/rfc7540#section-8.2 • Link header & Link element • https://www.w3.org/TR/preload/ • Cache Digests • https://tools.ietf.org/html/draft-ietf-httpbis-cache-digest-00 • Akamai - Are you ready for HTTP/2 Server Push?! • https://blogs.akamai.com/2016/04/are-you-ready-for-http2-server-push.html • Cloudflare - Announcing Support for HTTP/2 Server Push • https://blog.cloudflare.com/announcing-support-for-http-2-server-push-2/ • Fastly • https://www.fastly.com/blog/announcing-limited-availability-http2

×