PostgreSQL 复制工具
在 postgreSQL 的 wiki 上的“复制、集群和连接池”页面 ( http:// /wiki.postgresql.org/wiki/Replication,_Clustering,_and_Connection_Pooling),它显示了以下有关复制要求的示例:
“您的用户当他们离开办公室时,在笔记本电脑上保存数据库的本地副本,在他们离开时进行更改,并且需要在他们返回时将这些副本与主数据库合并。在这里,您需要一种异步、惰性复制方法,并且将被迫考虑如何处理在主服务器和本地副本上都修改了相同记录的情况下的冲突”
这几乎就是我的情况。但是,不幸的是,在同一页上,它说:“(...)此背景的一个重要来源是 Postgres-R 数据库复制的术语和定义。它没有提到的主要理论主题是如何解决在笔记本电脑等惰性复制情况下解决冲突,涉及投票和类似的方案。”
我想知道的是,在哪里可以找到有关如何解决这种情况的材料,这将是在 PostgreSQL 上执行此操作的最佳方法。
On the postgreSQL's wiki, on the "Replication, Clustering, and Connection Pooling" page ( http://wiki.postgresql.org/wiki/Replication,_Clustering,_and_Connection_Pooling) , it shows the following example on replication's requirements:
"Your users take a local copy of the database with them on laptops when they leave the office, make changes while they are away, and need to merge those with the main database when they return. Here you'd want an asynchronous, lazy replication approach, and will be forced to consider how to handle conflicts in cases where the same record has been modified both on the master server and on a local copy"
And that's pretty much my case. But, unfortunatelly, on the same page, it says: "(...) A great source for this background is in the Postgres-R Terms and Definitions for Database Replication. The main theoretical topic it doesn't mention is how to resolve conflict resolution in lazy replication cases like the laptop situation, which involves voting and similar schemes."
What I want to know, is where can I find material on how to resolve this kind of situation, and wich would be the best way to do this on PostgreSQL.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我将不得不检查 RubyRep,但似乎 Bucardo 可能是一个更广泛支持的选项。
Gabriel Weinberg 在他的网站上有一个关于如何使用 Bucardo 的优秀教程。这家伙运行自己的搜索引擎,名为 DuckDuckGo,并且有很多针对他的用例进行优化的提示和技巧。
http://www.gabrielweinberg.com/blog/2011 /05/replicating-postgresql-with-bucardo.html
I will have to check into RubyRep but it seems like Bucardo might be a more widely supported option.
Gabriel Weinberg has an EXCELLENT tutorial on his site for how he uses Bucardo. The guy runs his own search engine called DuckDuckGo and there are quite a few tips and tricks that are optimized for his use cases.
http://www.gabrielweinberg.com/blog/2011/05/replicating-postgresql-with-bucardo.html
只是回答我自己的问题,如果有人找到它:我正在使用 Rubyrep http://www.rubyrep.org/< /a> 并且它正在工作。
Just answering my own question, if anyone ever finds it: I'm using Rubyrep http://www.rubyrep.org/ and it's working.