Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Pretty typical of any multi-master asynchronous replication: you must make damn sure your application isn't going to generate conflict. If conflict does happen, you have to apply some external logic to resolve that issue. Some things like GoldenGate (oracles purchase of binlog snarfing multi-master replication) provide you some tools for that. Basically dumping conflicted records into a table for manual or automated clean up later.

At the end of the day, it's always going to require well thought out schemas and data layout if you want to take writes for both masters.

Multi-master is less difficult if you only write to a single node at a time (hot-standby style).



Having a single master is sometimes not viable in some situations. But yes, eventual consistency can be both a blessing and a curse.

But if you can design your system to take this into account, it's pretty easy to scale out and everything Just Works(tm).


I don't know much about replication, but I'd like to learn. Can you recommend any books/courses/tutorials that address the sorts of design decisions you're talking about?


The two must have books for MySQL admin and discuss MySQL's built in replication, what problems you'll encounter, how to tune etc.

  - High Performance MySQL (Schwartz et al)
  - MySQL High Availability (Bell et al)
I think using MySQL::Replication can be applied on top of what's in these books, but not using their particular setups.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: