官术网_书友最值得收藏!

Considering SSI transactions

On top of read committed and repeatable read, PostgreSQL offers Serializable Snapshot Isolation (SSI) transactions. So, in all, PostgreSQL supports three isolation levels. Note that read uncommitted (which still happens to be the default in some commercial databases) is not supported: if you try to start a read uncommitted transaction, PostgreSQL will silently map to read committed. Let us get back to the serializable isolation level.

The idea behind serializable is simple; if a transaction is known to work correctly when there is only a single user, it will also work in the case of concurrency when this isolation level is chosen. However, users have to be prepared; transactions may fail (by design) and error-out. In addition to this, a performance penalty has to be paid.

If you want to know more about this isolation level, consider checking out https://wiki.postgresql.org/wiki/Serializable.

Consider using serializable only when you have a decent understanding of what is going on inside the database engine.
主站蜘蛛池模板: 大宁县| 怀来县| 恭城| 普陀区| 新邵县| 淮阳县| 汉沽区| 平乐县| 赤峰市| 东兰县| 阿巴嘎旗| 福泉市| 嵊州市| 珠海市| 巨鹿县| 新化县| 景东| 慈利县| 于田县| 五大连池市| 哈密市| 崇文区| 九江市| 东源县| 从化市| 无为县| 榆社县| 顺平县| 镇安县| 康马县| 班玛县| 六盘水市| 大方县| 乌拉特后旗| 弥渡县| 昭觉县| 丁青县| 蕉岭县| 嘉兴市| 高平市| 瑞丽市|