[openstreetmap/openstreetmap-website] Idempotency for API 0.6 (#2201)

mmd notifications at github.com
Sun Apr 7 15:42:06 UTC 2019

> Just as a matter of principle I don't think we should accept anything that attempts to make an operation which is defined to be non-idempotent behave idempotently.

If we were to redesign the interface from ground up, I would fully agree with you. Most likely we would first request some URL to store a later osmChange message, and use PUT instead of POST. Still parts of what I have outlined earlier on would to some extent still be valid, e.g. on top of what we have today, we need to persist the diffResult somehow.

It's an interesting coincidence that the folks who came up with this approach also initially forgot to make their API fault-tolerant (see https://stripe.com/en-US/blog/idempotency). In the context of financial transactions, it's obviously a big no go to charge your customers twice, and they had to come up with some schema to fix this. 

You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20190407/f83993eb/attachment.html>

More information about the rails-dev mailing list