This has the potential of saving a lot of CPU time and network bandwidth.
Logged requests show a variety of values:
name='HTTP_IF_MODIFIED_SINCE' type=9
value=''
name='HTTP_IF_MODIFIED_SINCE' type=9
value='Tue, 20 Oct 2015 21:24:49 GMT'
name='HTTP_IF_MODIFIED_SINCE' type=9
value='Mon, 07 Sep 2015 07:31:05 UTC'
See https://developer.mozilla.org/en-US/docs/Web/HTTP/Conditional_requests for details. In short, there are several headers (not just If-Modified-Since) that might be worth implementing.
It might be worth it to implement this in a few iterations. For example:
- static files - it should be trivial to do for static files since we can use etags (hash of the content, or something else)
- post urls - weak validation (see above mozilla link) of just the post data
- index/feed urls - weak validation of all the posts' data