4 ms·
Postgres doesn't do distributed consensus though does it.
by alexjarvis 10y ago
Postgres doesn't do distributed consensus though does it.
- TheDong 10y agoYes it does, via configuring multiple postgres servers with synchrnous and streaming replication options. https://www.postgresql.org/docs/9.2/static/warm-standby.html#SYNCHRONOUS-REPLICATION https://www.postgresql.org/docs/9.2/static/warm-standby.html... https://github.com/sorintlab/stolon https://github.com/sorintlab/stolon
- trcollinson 10y agoI'll assume this isn't a joke and that you just aren't well versed in computer science nor in database theory. While Postgres doesn't use distributed consensus it does use distributed transactions to maintain consistency (a major tenet of ACID compliance). In a distributed consensus environment a substantial number of proofs of work (in Bitcoins case a hash) must be performed to gradually ensure that a block in the chain is consistent and thus come to a consensus that it is in fact valid. In Postgres a transaction can be verified and guaranteed to be consistent among nodes using a two phase commit protocol. Essentially a transaction is attempted, verified, and then committed by the nodes of the network in a guaranteed, and very secure, manner. The upside to the Postgres method is you do not need a substantial number of individual processors to perform proof of work to securely verify consistency.
- alexjarvis 10y agoSorry, I wasn't clear, I meant trust-less consensus (proof of work). Distributed transactions in an RDBMS requires trusting all the hosts it runs on.