News for hackers. Stuff that matters.
Re:HTTP Immutable Responses by edmorley on Friday September 15, 2017 @07:49PM (#15261800)
For more on the rationale behind this feature, see:

https://www.ietf.org/mail-archive/web/httpbisa/current/msg25...

https://bitsup.blogspot.co.uk/2016/05/cache-control-immutabl...

Rough summary:

> At Facebook, ... we've noticed that despite our nearly infinite expiration dates we see 10-20% of requests (depending on browser) for static resource being conditional revalidation. We believe this happens because UAs perform revalidation of requests if a user refreshes the page.

> A user who refreshes their Facebook page isn't looking for new versions of our _javascript_. Really they want updated content from our site. However UAs refresh all subresoruces of a page when the user refreshes a web page. This is designed to serve cases such as a weather site that says <img src="" ...

> Without an additional header, web sites are unable to control UA's behavior when the user uses the refresh button. UA's are rightfully hesitant in any solution that alters the long standing semantics of the refresh button (for example, not refreshing subresources).

Re:HTTP Immutable Responses by fulafel on Saturday September 16, 2017 @05:09AM (#15263726)
What's the hurry to optimize away the revalidation requests when the user clicks reload? Is it just beancounter mindset about saving a few "304 Not modified" responses? In that case they shouldn't count the percentage of requests, but percentage of bandwidth or CPU seconds. Tiny responses are much cheaper with HTTP/2, so be sure to benchmark with that.
Re:HTTP Immutable Responses by joosters on Saturday September 16, 2017 @08:21AM (#15264316)
I'd be happier if my browser made fewer requests, however small they may be. Even if they make up a tiny percentage of my internet traffic, it all adds up. Making computers do less unnecessary work is a good thing.
Re:HTTP Immutable Responses by fulafel on Saturday September 16, 2017 @08:37AM (#15264367)
People are notoriously poor at predicting what increases their happiness; see Daniel Gilbert's book[1].

[1] https://en.wikipedia.org/wiki/Stumbling_on_Happiness

Re:HTTP Immutable Responses by Denvercoder9 on Saturday September 16, 2017 @08:22AM (#15264321)
At Facebook scale, the sum of all those "304 Not Modified" responses is probably a significant amount of resources.
Re:HTTP Immutable Responses by fulafel on Saturday September 16, 2017 @08:42AM (#15264391)
I'm not sure it's a good argument to take up the biggest companies and then tally up effects of a micro improvement. You could argue for all kinds of complexity increasing changes resulting in %0.01 efficiency improvements this way.
Re:HTTP Immutable Responses by marcusarmstrong on Saturday September 16, 2017 @10:03AM (#15264685)
At my company, 304s account for 3% of our CDN requests.
Re:HTTP Immutable Responses by fulafel on Saturday September 16, 2017 @10:56AM (#15264890)
304 requests are so tiny that you probably end up in the order of 0.01%.
Re:HTTP Immutable Responses by justinjlynn on Saturday September 16, 2017 @08:23AM (#15264327)
Very few entities operate at "facebook scale".
Re:HTTP Immutable Responses by icebraining on Saturday September 16, 2017 @10:33AM (#15264795)
But they still account for a lot of the Web traffic.
Re:HTTP Immutable Responses by 3pt14159 on Saturday September 16, 2017 @01:47PM (#15265670)
Think dropped requests. If you're operating with 99% packet loss like many people around the world minimizing the absolute number of requests can have dramatic impact on load times.
Re:HTTP Immutable Responses by fulafel on Saturday September 16, 2017 @03:13PM (#15266162)
You can't do anything with TCP or the web in a situation like that.
Re:HTTP Immutable Responses by 3pt14159 on Sunday September 17, 2017 @06:38PM (#15272087)
What do you mean? I've operated at 99% packet loss plenty of times in the rural parts of Vietnam. The key is you can't use any of the websites or apps that are popular in North America / Europe.
Re:HTTP Immutable Responses by fulafel on Tuesday September 19, 2017 @01:06AM (#15281939)
The likelihood of even opening a TCP connection is going to be very low. For phase 1, stacks typically send 5 SYNs before giving up. So 95% of your TCP connection estabilishments will slowly fail due to timeout before you even get to phase 1 of the 3-stage connection estabilishment. To say nothing of actually transmitting or receiving any payload data successfully. Which you would have to many times to open a web page.
Re:HTTP Immutable Responses by simcop2387 on Saturday September 16, 2017 @05:02AM (#15263706)
I understand their rationale for it, but I don't think it should be implemented. Having something immutable like this allows it to end up being used for tracking purposes. Just add a <script src="trackingcookie.js" /> that calls a function with the cookie and all the sudden there's yet another place to covertly store an ID for tracking a user.
Re:HTTP Immutable Responses by joosters on Saturday September 16, 2017 @08:24AM (#15264328)
But you're removing HTTP requests, so how can it make tracking easier? Any ID that a company puts in their immutable content can also be put in their normal content. The change doesn't make tracking any easier than it already is.
Re:HTTP Immutable Responses by simcop2387 on Saturday September 16, 2017 @12:50PM (#15265424)
It makes it another place that they can store the tracking cookie and have your browser give it back out to them. Deleting the cookies or other such things wouldn't remove the tracking ID as long as the browser continues to use the cached immutable resource. Similar to how this[1] works by using multiple storage methods.

https://github.com/samyk/evercookie