A funny addendum from Sam on the topic of concurrent updates with REST;

Obviously, Clemens hasn’t heard about the expires header. All you have to do is predict with 100% accuracy when the next POST or DELETE request is going to come in, and all caches will remain perfectly in synch.

It is just a SMOP.

Heh, exactly. Some might call this a bug, I call it a feature. There is no requirement in REST that all layers have a consistent view of the state of a resource, as to do so would be to reduce scalability. It’s basically just recognizing that perfect data consistency in the face of latency and trust boundaries, is impossible. The best one can do (addendum; well close to it) is to make explicit, at the time the representation is transferred, the expectations about the durability of the data. As I mentioned previously, architectural styles that transfer serialized objects (the whole object, not just the state) can address the issue of latency, by moving the encapsulating code along with the data. But this is done at the cost of visibility, which means that it likely won’t cross trust boundaries.

Trackback

no comment until now

Add your comment now