RFC: race condition in resource updates

Giulio Fidente gfidente at fedoraproject.org
Fri Nov 30 12:39:16 UTC 2012


On 11/30/2012 01:29 PM, Martyn Taylor wrote:
>> Use the ETag header, containing a MD5 hash, to indicate the state of
>> the resource. As far as I can tell we have this header already,
>> perhaps it is auto generated.
>
> Looking at the HTTP Spec this does seem to be the way to go.  But I
> am unsure on how this is implemented.  For example, we do not want
> the MD5 Checksum to be done after the resource has been represented
> in a particular format, since the client is stuck using that format
> or it has to refresh its entire view (Since the checksum will change
> from XML to JSON).

I like better the idea of using etags too, mostly because:

- etag is quite common nowdays for caching management too
- let the server decide if the client is allowed to change the resource
or not
- in the UI, given that a race isn't so common, one could just handle
the 412 into some properly described failure notice

-- 
Giulio Fidente



More information about the aeolus-devel mailing list