RE: HTTP If-* headers, etags

This is a really good point:

> However, the other side of the coin is that it makes sense
> for editable
> content (say a PDF document) to keep their ETag between PUTs. Clients
> can then use the ETag (and are indeed encouraged to do this) to check
> for unexpected changes to the document they are about to replace.

At risk of belaboring the obvious, I'd like to add that clients SHOULD check
the ETag when doing a PUT request (it's just one extra header).  This should
be done even if the client things they've locked the file because locks can
go away or (although wrongly) be used by another process owned by the same
user.

Thus, if clients SHOULD check the ETag before putting the file, it makes it
even more important for servers not to change the ETag unless the contents
have actually changed.  Changing the ETag when the body is unchanged could
result in a poor user experience, if their application has to pop up a
dialog or return an error saying "The file you are trying to save MAY have
been changed.  Do you want to save your changes anyway?"

lisa

Received on Tuesday, 30 April 2002 13:43:22 UTC