News for hackers. Stuff that matters.
Re:Apache 2.4.17 with HTTP/2 support by Tepix on Friday October 16, 2015 @08:05AM (#10398720)
That's great news! I look forward to test this. I saw that the Ubuntu apache ppa at https://launchpad.net/~ondrej/+archive/ubuntu/apache2 already has packages for this version (not tested by me).

What's sad is that this is yet another github page with #777 colored text on white background. The resulting contrast is too low to read comfortably!

Re:Apache 2.4.17 with HTTP/2 support by skrause on Friday October 16, 2015 @07:25AM (#10398607)
No mention of server push, so I assume it's not supported?
Re:Apache 2.4.17 with HTTP/2 support by mholt on Friday October 16, 2015 @12:40PM (#10400472)
Here's a blog post I wrote about why this probably isn't implemented in most servers yet: https://caddyserver.com/blog/implementing-http2-isnt-trivial
Re:Apache 2.4.17 with HTTP/2 support by spankalee on Friday October 16, 2015 @03:42PM (#10401573)
There a few claims you have that I think are slightly off.

First, push is very different than inlining, because individual resources are cacheable by the client, and inlined resources are not. There's a little handshake at the start of a push and if the client has (or doesn't otherwise want) the resource, it can cancel the push.

In my team's experiments with using push for HTML Imports, push ends up being better than inlining (using Polymer's vulcanize tool), even with a cold cache.

Also, push is relatively easy to implement if you use the response header approach, and was availably early on in mod_spdy.

Re:Apache 2.4.17 with HTTP/2 support by dtech on Friday October 16, 2015 @08:05AM (#10398721)
Reading the page it seems like it is still in quite an early state, I expect they have higher priorities.
Re:Apache 2.4.17 with HTTP/2 support by tootie on Friday October 16, 2015 @11:09AM (#10399804)
How would server push from a web server work?
Re:Apache 2.4.17 with HTTP/2 support by pquerna on Friday October 16, 2015 @12:04PM (#10400202)
Other comments are are good starts.

Another method would be to add a headers to the response:

    Server-Push: /relative/url
Then have an output filter pull them out and push them -- but AFAIK the APIs to do that don't yet exist in mod_h2 to push like that. Adding headers in the response is nice because it works with any 'backend', and the web server doesn't have to parse the HTML/css/etc going the through it.
Re:Apache 2.4.17 with HTTP/2 support by spankalee on Friday October 16, 2015 @03:27PM (#10401491)
This how it's done in mod_spdy[1] and App Engine[2], with the X-Associated-Content header.

[1]: https://code.google.com/p/mod-spdy/wiki/OptimizingForSpdy#Us... [2]: https://github.com/GoogleChrome/http2push-gae

Re:Apache 2.4.17 with HTTP/2 support by acdha on Friday October 16, 2015 @11:49AM (#10400081)
The simplest way would seem to be a directive to push static resources:

    <Location />
        ServerPush /static/css/main.css
        ServerPush /static/js/main.js
    </Location>

    <LocationMatch "^/$">
        ServerPush /static/img/gigantic-homepage-image.jpg
    </LocationMatch>

    <Location /maps/>
        ServerPush /static/js/leaflet.js
    </Location>
I believe this could even avoid the need to include cache-busters in the URL since you could push with an ETag and the client can terminate if it already has the appropriate bytes without the incredible performance hit of using ETags with HTTP 1.
Re:Apache 2.4.17 with HTTP/2 support by thethimble on Friday October 16, 2015 @02:48PM (#10401312)
I think this is unsustainable (any non-trivial change to your html resources would require updating and restarting httpd). This is not DRY.

Jetty's approach to this problem is really interesting. Using HTTP referrer headers, it builds up a tree of resources that are often fetched together. Then, it optimistically pushes companion resources down. https://github.com/eclipse/jetty.project/blob/master/jetty-s...

Re:Apache 2.4.17 with HTTP/2 support by acdha on Friday October 16, 2015 @03:07PM (#10401409)
You'll note that I said “simplest” – this could work on a $2/month shared hosting plan (not sure where you got the “updating and restarting httpd” bit from with a couple decades of prior art showing otherwise).

The Jetty approach is clever, too, as would be things like scanning rel=prefetch links but simple declarative approaches have their moments, too. One thing the Jetty approach doesn't appear to offer is the ability to manage resources if not all resources are appropriate for every client so it would appear to do things like ship every size of a responsive image to every client.

Re:Apache 2.4.17 with HTTP/2 support by Tobani on Friday October 16, 2015 @11:45AM (#10400052)
If the server can parse served html, it could preemptively also send along other required assets (css, images, etc) before the client has time to parse and request them. This would help remove necessity for optimizations like image bundling.
Re:Apache 2.4.17 with HTTP/2 support by vpkaihla on Friday October 16, 2015 @07:41AM (#10398647)
They added a significant new protocol in a minor upgrade. Is that right?
Re:Apache 2.4.17 with HTTP/2 support by dtech on Friday October 16, 2015 @08:00AM (#10398698)
Apache version numbering is similar to what the linux kernel used before 2.6.

In a.b.c, odd b indicates the unstable or experimental branch, and even b's are used for major and backwards-compatibility breaking changes. Backwards-compatibility preserving changed can be introduced in c.

So 2.2 and 2.4 are pretty different versions, while 2.3 and 2.4 are closer except 2.3 is unstable. 2.4.0 is theoretically compatible with 2.4.17, except the latter has a lot more functionality and features.

Re:Apache 2.4.17 with HTTP/2 support by chrisseaton on Friday October 16, 2015 @07:45AM (#10398657)
If all it does is add new functionality, and doesn't modify or break any existing functionality, then that seems to be good software engineering to do in a minor upgrade doesn't it?
Re:Apache 2.4.17 with HTTP/2 support by dtech on Friday October 16, 2015 @07:56AM (#10398681)
If you follow semantic versioning, the third number should only be used for bugfixes. They don't.
Re:Apache 2.4.17 with HTTP/2 support by dspillett on Friday October 16, 2015 @08:02AM (#10398709)
Seems valid: MAJOR.MINOR.PATCH, with the minimum changes being increment "patch" for backwards compatible bug fixes, "minor" for new/improved functionality that does not break backwards compatibility, and "major" for any API/feature change that is not backwards compatible. They could of course chosen to increment MAJOR instead, but they don't have to in this case.

(I'm assuming they are following "standard" semver rules here)

Re:Apache 2.4.17 with HTTP/2 support by dtech on Friday October 16, 2015 @08:07AM (#10398727)
They don't use semver, and their versioning scheme precedes semver.
Re:Apache 2.4.17 with HTTP/2 support by skrause on Friday October 16, 2015 @08:10AM (#10398739)
In your example MAJOR.MINOR.PATCH they actually only increased PATCH, Apache 2.4.0 was released in early 2012.
Re:Apache 2.4.17 with HTTP/2 support by dspillett on Friday October 16, 2015 @09:13AM (#10398996)
Ah, I was assuming the mention of "minor" in the post I replied to was referring to minor in the semver sense, without actually checking. My bad.
Re:Apache 2.4.17 with HTTP/2 support by ta0967 on Friday October 16, 2015 @11:12AM (#10399826)
"backwards compatible bug fixes" don't exist: fixing a bug changes the program's behavior.
Re:Apache 2.4.17 with HTTP/2 support by dspillett on Friday October 16, 2015 @11:21AM (#10399898)
Compatibility in this case is referring to published APIs and not changing documented behaviour. There are a large family of changes that are bug fixes that don't change correct use of an API - many security fixes for example.
Re:Apache 2.4.17 with HTTP/2 support by barkingcat on Friday October 16, 2015 @10:10AM (#10399369)
why wouldn't it be right? Not everyone uses semver, and apache project version #'s precedes semver by a long while.
Re:Apache 2.4.17 with HTTP/2 support by laumars on Friday October 16, 2015 @09:43AM (#10399164)
It's an optional module rather than changing the core logic (as 2.2->2.4 did), so in that regard it makes sense to only up the minor version number.
Re:Apache 2.4.17 with HTTP/2 support by marktangotango on Friday October 16, 2015 @08:18AM (#10398769)
A better title would probably be: with OPTIONAL http2 support.
Re:Apache 2.4.17 with HTTP/2 support by itsbits on Friday October 16, 2015 @07:44AM (#10398654)
not defaulted as http2 though.