specification icon indicating copy to clipboard operation
specification copied to clipboard

Add support for Last-Modified header

Open dmitrizagidulin opened this issue 10 years ago • 5 comments

If a resource is readable, the Last-Modified header should be returned.

(Originally opened by @csarven) (Moved from https://github.com/linkeddata/gold/issues/64)

From RFC 7232:

An origin server SHOULD send Last-Modified for any selected representation for which a last modification date can be reasonably and consistently determined, since its use in conditional requests and evaluating cache freshness ([RFC7234]) results in a substantial reduction of HTTP traffic on the Internet and can be a significant factor in improving service scalability and reliability. https://tools.ietf.org/html/rfc7232#section-2.2.1

dmitrizagidulin avatar Jan 13 '16 00:01 dmitrizagidulin

@csarven - do you still consider this an important feature request; should we move this issue to /specification ?

dmitrizagidulin avatar Sep 24 '19 17:09 dmitrizagidulin

I think it is important for an implementation but the Solid spec most likely won't change anything from RFC 7232 - currently isn't. If there is any interest in it being something other than a SHOULD for Solid, then sure we can have an issue and explore.

csarven avatar Sep 24 '19 21:09 csarven

Yeah, anything that can enable caching is important for Solid, IMHO, so yeah, important, but also possibly a SHOULD with us doing it in our server code to set an example. :-) I believe it is more important to think about it in the server architecture than in the spec.

kjetilk avatar Sep 24 '19 22:09 kjetilk

The current spec sets MUST for 7232 (and actually SHOULD for Last-Modified in there) for servers, and MAY for clients.

For 7234, server SHOULD, client MAY.

As it stands, there is no particular functionality that needs Last-Modified as MUST for server. It can however come from elsewhere and that would be orthogonal.

The Best Practices and Guidelines document can make suggestions.

csarven avatar Oct 18 '20 11:10 csarven

Given the changes in the Solid Protocol involving the Last-Modified header field ( https://solidproject.org/ED/protocol , https://solidproject.org/TR/2024/protocol-20240512 ), this issue can be revisited to make the requirement explicit. A PR to resolve this issue is available at: https://github.com/solid/specification/pull/678.

csarven avatar Aug 24 '24 12:08 csarven