Re: why postgresql over other RDBMS
От
Alexander Staubo
Тема
Re: why postgresql over other RDBMS
Дата
Msg-id
88daf38c0705241416n35b92f48xf01d08abe364ab49@mail.gmail.com
Ответ на
Список
Дерево обсуждения
Re: why postgresql over other RDBMS Wiebe Cazemier <halfgaar@gmx.net>
Re: why postgresql over other RDBMS "A.M." <agentm@themactionfaction.com>
Re: why postgresql over other RDBMS Alvaro Herrera <alvherre@commandprompt.com>
Re: why postgresql over other RDBMS Naz Gassiep <naz@mira.net>
Re: why postgresql over other RDBMS "A.M." <agentm@themactionfaction.com>
Re: why postgresql over other RDBMS "Alexander Staubo" <alex@purefiction.net>
Re: why postgresql over other RDBMS PFC <lists@peufeu.com>
Re: why postgresql over other RDBMS "A.M." <agentm@themactionfaction.com>
Re: why postgresql over other RDBMS Andrew Sullivan <ajs@crankycanuck.ca>
Re: why postgresql over other RDBMS "A.M." <agentm@themactionfaction.com>
We're derailing the thread, but... On 5/24/07, A.M. wrote: > 2PC requires that the modifications already be in concrete. What I > suggest is a method for a new connection to insert itself into an > existing (sub-)transaction SQL stream, make changes, and commit to > the root or parent transaction. The problem with long-running transactions is that they need to avoid locking the resources they touch. Short-running transactions are bad enough as they stand -- until fairly recently (8.1? 8.2?), merely inserting or updating a row that had a foreign-key reference to another table row would lock the referenced row until the end of the transaction, by issuing an implicit "select ... for update". Although a mechanism whereby multiple connections can share a single session/transaction is probably easy to implement, using long-running transactions to isolate DDL changes is not feasible at the moment because PostgreSQL currently acquires an AccessExclusiveLock on the modified table until the transaction ends, which means that concurrent transactions would be blocked from even querying the table. I don't know PostgreSQL's internals, so I can only postulate that this locking occurs because PostgreSQL holds a single copy of the schema and related bookeeping structures in memory. Alexander.
В списке pgsql-general по дате отправления