Hacker News new | ask | show | jobs
by koolba 3426 days ago
> I will never rely on my database, regardless of which one I am using for complete data consistency.

I can't imagine developing any software that involves relationships between entities that does not have data consistency. Check constraints, foreign keys, and data type validation all provide a minimum sanity level of the underlying data that allows your mind to focus on more important things. Otherwise you're entire application is going to be littered with those same sanity checks.

I'm not saying that all apps need that type of data store or that there isn't room in this world for NoSQL stores, I mean specifically that complicated interdependencies and validation checks lend themselves well to the relational model.

1 comments

I think maybe the doubt is based on case like https://aphyr.com/posts/282-jepsen-postgres which all systems are subject to.
That's not a case of inconsistency. There are just three outcomes for a transaction: Committed, Aborted and Unknown.

The client will never experience Committed unless it really is committed, and thus never report that it was successful to the user.

Uh, no. That article is a bit of a long winded way to say that 2PC with timeouts is 2PC with timeouts.
It might be better to think of it as a limitation of two-generals, rather than 2PC in particular.