mod_h[ttp]2

HTTP/2 for Apache httpd

HTTP/2 will be nu, nu, nu, nu, nineteen!

Copyright (C) 2016 greenbytes GmbH

While you read this, the beautiful people from Apache httpd dev team are busy putting together the next 2.4 realease which - knock on wood - will be 19! While chilling from the last several-day race condition hunt, I thought I'd give you a short overview what will come.

Stability

Since 2.4.18 there have been very important stability improvements done to the module. Many, many thanks to the people who helped out analyzing this, among them Frank Stolle, Mark Nottingham and Bernard Spil. Thank them, buy them beer!

The fixes in no particular order and without guarantuee of completeness:

Almost all of this has been released here in github in the meantime and was tested by several nice people out there, partially on production systems. Very nice.

Push Additions

Server pushes now correctly forward the Content-Encoding header from a client, so that compression is available on pushed resources.

Each connection has not a diary where pushes are recorded, so that the same resource is not PUSHed twice on the same connection. This diary can be preset by a client using a Cache-Digest header. This follows a proposal from Kazuho Oku and is, so far, highly experimental. The spec will probably change quite a bit and browser implementers will have a word or two on this as well, but it's very interesting.

There is also discussion on Link headers and if using preload for HTTP/2 PUSHes is a good idea or not. Following a proposal from Ilya Grigorik, mod_http2 now respects the nopush parameter on preload links. Guess what it does?

Status Handling

The module now gives some information in the Apache scoreboard, also known as server-status. You will see the protocol chosen for each connection and, for HTTP/2 connection, you can see how many streams have been processed, are open, etc.

Additionally, you can configure a http2-status page that shows more details on the current connection. You configure this as

    <Location "/http2-status">
        SetHandler http2-status
    </Location>
If you have a connection open and request that resource, you get statistics about frames, bytes, resets, pushes, push diary, etc.

Also, the environment variables HTTP2 and H2PUSH have been added. The first is set to on for a HTTP/2 connection. The latter is on when pushing resources is supported on the connection.

mod_proxy_http2

And, last but not least, I have been working on a mod_proxy_http2 that will bring HTTP/2 goodies to backend connections. It is not clear if it will make it into the next 2.4 release, as it is very young. But so once was mod_http2...

We'll see.

Münster, 09.03.2016,

Stefan Eissing, greenbytes GmbH

Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved. This file is offered as-is, without warranty of any kind. See LICENSE for details.