1

Possible Duplicate:
Transaction in REST WCF service

http://rest.blueoxen.net/cgi-bin/wiki.pl?TwoPhaseCommit proposed implementing two-phase commits using a custom header value to identify the transaction associated with a request. Wouldn't this approach break caching proxies? For example, a proxy sees HTTP DELETE /foo against Transaction 123 but it's not smart enough to realize this transaction is subsequently rolled-back. The proxy then proceeds to cache the fact that /foo has been deleted.

Am I wrong? What do you recommend for implementing RESTful two-phase commits?

Community
  • 1
  • 1
Gili
  • 86,244
  • 97
  • 390
  • 689
  • See my answer to [this](http://stackoverflow.com/questions/1389881/transaction-in-rest-wcf-service) question – Darrel Miller Oct 08 '10 at 11:23
  • Why does Fielding assume that two-phased commits can only be implemented with the client coordinating server resources? I see nothing wrong with two-phased commits (or transactions in general) from a RESTful point of view. Please clarify what he means. – Gili Oct 09 '10 at 06:12
  • Note to self, interesting post: http://www.infoq.com/news/2009/06/rest-ts – Gili Oct 09 '10 at 06:27
  • Damn. I wrote you a big comment and power outage trashed it. Here's the condensed version. Seems I read Roy's quote wrong. I don't think he is saying you can't do dist-transactions, he is just saying that the client does not need to be aware of any dist-trans protocol. The client simply follows the links it has been given. If behind the scenes some kind of 2-phase commit is going on, maybe that is ok. Need to do some more thinking. – Darrel Miller Oct 09 '10 at 18:25
  • interesting! Let me know if you find any more documentation on this. – Gili Oct 11 '10 at 16:37

0 Answers0