Enable HTTP/2 Support in AWS ELB
This thread was started more than a year ago, asking for when Amazon Web Services will add support for HTTP/2 into their ELB. In addition to that, people are also asking, how to configure ELB to support multiple SSL certificates.
AWS support team has been reluctant on giving out any specific details on when both of these features will be available, citing:
Naturally, you need to have HTTP2 enabled in your web server level. Latest specification also requires that you have SSL enabled. Assuming you are using nginx 1.9.5 or later (I was using nginx 1.10 on Ubuntu 16.4) both are trivial tasks.
AWS support team has been reluctant on giving out any specific details on when both of these features will be available, citing:
I've verified that the ELB team is aware of the interest in ELB supporting HTTP/2. Please keep an eye on What's New from Amazon Web Services: http://aws.amazon.com/new/ for any updates.
What is HTTP/2?
HTTP/2 is a replacement for how HTTP is expressed “on the wire.” It is not a ground-up rewrite of the protocol; HTTP methods, status codes and semantics are the same, and it should be possible to use the same APIs as HTTP/1.x (possibly with some small additions) to represent the protocol.
HTTP/2 protocol is supported by major modern browsers including IE11, Edge 13, Firefox 47, Chrome 52, Safari 9.1, Opera 38, iOS Safari 9.3, Android 5.1.
What are the differences with HTTP/1.x?
The major differences are following:
- binary protocol
- is fully multiplexed, instead of ordered and blocking
- uses only one connection for parallelism
- uses header compression to reduce overhead
- allows servers to “push” responses proactively into client caches
- not supported in current nginx version though
How to enable HTTP/2 Support in ELB
There is a way to enable the support for HTTP2 in ELB. Or to put it mildly, instruct ELB to act as a dummy round-robin TCP-IP pass-through device.Naturally, you need to have HTTP2 enabled in your web server level. Latest specification also requires that you have SSL enabled. Assuming you are using nginx 1.9.5 or later (I was using nginx 1.10 on Ubuntu 16.4) both are trivial tasks.
- Go to EC2, Load Balancing, Load Balancers.
- Click on existing load balancer, or add new one
- Click on Listeners tab, and hit Edit
Now, edit your listeners so for HTTP traffic the load balancer port is TCP 80, and instance protocol is HTTP port 80. For SSL, set the load balancer TCP port 443, and instance protocol HTTPS (Secure HTTP) port 443. It is very important to ensure that incoming protocols are TCP - this allows seamless pass-through and essentially the SSL termination will happen at the node level.
ELB configuration to support HTTP/2 |
Comments
Post a Comment