MySQL (and other Relational Databases) are known to be ACID compliant with respect to transactions. However, when databases are sharded, does the ACID property of transactions break since now transactions cannot be handle by the db, since the shards are now completely different db instances. Does this mean, the transactions should be handled at the application level including implementation of rollback and other features? So, how does sharding effects ACID property and how to overcome if there any disadvantages of the same?

PS: MongoDB from version 4.2 supports transactions across sharded clusters? Does this give MongoDB a considerable edge over MySQL (and RDMs)?


If, by "sharding", you mean having some data on one server; some on other servers. And you need to touch different servers in the same "transaction". Then you need "XA" in order to achieve ACID. It is complex and slow.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.