rethinkdb / docs

RethinkDB documentation
http://rethinkdb.com/docs
Apache License 2.0
117 stars 167 forks source link

Simulating two-phase commits #598

Open thelinuxlich opened 9 years ago

thelinuxlich commented 9 years ago

It would be nice to have something like this on the Cookbook section

danielmewes commented 9 years ago

Nice idea @thelinuxlich .

See https://github.com/rethinkdb/rethinkdb/issues/1863#issue-25564559 . It's a relatively complicated thing and would need some work to really explain what it does and how to use it.

I think there are some lower-hanging fruits in terms of expanding our documentation at the moment, but we should keep it in mind.

thelinuxlich commented 9 years ago

There is a MongoDB article which you can reuse in RethinkDB:

http://docs.mongodb.org/manual/tutorial/perform-two-phase-commits/

danielmewes commented 9 years ago

Unfortunately the Mongo docs are under a variant of the CC license that does not allow commercial use http://creativecommons.org/licenses/by-nc-sa/3.0/ , so we cannot use it.

thelinuxlich commented 9 years ago

:(

Timer commented 9 years ago

@thelinuxlich I've been working on something like this recently, feel free to audit it for issues -- https://gist.github.com/Timer/51e5b8883ff13eaaa3ca

thelinuxlich commented 9 years ago

@Timer very nice, looking at your code, you could do almost everything with ReQL server-side in one step instead of using async.waterfall

Timer commented 9 years ago

Thanks for the tip @thelinuxlich, I'll look into it.

jaladankisuresh commented 7 years ago

We had a requirement to implement transactional support in ReThinkDb, and had come-up with this solution thinktrans.

I tried to document our approach of Implementing transactions in No SQL Databases

Disclaimer: I am author of this library