Re: Autonomous Transaction (WIP)

Поиск
Список
Период
Сортировка
От Craig Ringer
Тема Re: Autonomous Transaction (WIP)
Дата
Msg-id 53424AB5.6010506@2ndquadrant.com
обсуждение исходный текст
Ответ на Autonomous Transaction (WIP)  (Rajeev rastogi <rajeev.rastogi@huawei.com>)
Ответы Re: Autonomous Transaction (WIP)  (Ian Barwick <ian@2ndquadrant.com>)
Re: Autonomous Transaction (WIP)  (Rajeev rastogi <rajeev.rastogi@huawei.com>)
Список pgsql-hackers
On 04/07/2014 12:06 PM, Rajeev rastogi wrote:


> Syntax to create autonomous transaction can be as:
> 
>                         */PRAGMA AUTONOMOUS TRANSACTION;/*

Wouldn't you want to use SET TRANSACTION for this?

Or a suffix on BEGIN, like BEGIN AUTONOMOUS TRANSACTION ?

What's the logic behind introducing "PRAGMA" ?


If you wanted to use that syntax for Oracle compatibility you'd need to use:
   PRAGMA AUTONOMOUS_TRANSACTION;

(note underscore). But really, this would no be a pragma at all,
PostgreSQL doesn't really have the concept. Calling it that would just
be misleading.




> *_Starting of Autonomous  Transaction:_*
> 
> Starting of autonomous transaction will be exactly same as starting
> sub-transaction.

If you don't want it to dirty read data from the parent tx, or inherit
parent locks, then it cannot be the same at all.

> 2.      Freeing of all resource and popping of previous transaction
> happens in the same way as sub-transaction.

I'm not sure what you mean here.


Overall, this looks like a HUGE job to make work well. I know some
others have been doing work along the same lines, so hopefully you'll be
able to collaborate and share ideas.

-- Craig Ringer                   http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training & Services



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Pavel Stehule
Дата:
Сообщение: Re: Autonomous Transaction (WIP)
Следующее
От: Craig Ringer
Дата:
Сообщение: Re: Pending 9.4 patches