Re: New parameter RollbackError to control rollback behavior on error

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: New parameter RollbackError to control rollback behavior on error
Дата
Msg-id CAB7nPqQoJbeW=ausdoyQVv2VXQn0Qi8-bazOxhi-cfPGfEjZ=w@mail.gmail.com
обсуждение исходный текст
Ответ на Re: New parameter RollbackError to control rollback behavior on error  (Heikki Linnakangas <hlinnakangas@vmware.com>)
Ответы Re: New parameter RollbackError to control rollback behavior on error  (Michael Paquier <michael.paquier@gmail.com>)
Список pgsql-hackers
On Wed, Mar 26, 2014 at 5:53 PM, Heikki Linnakangas
<hlinnakangas@vmware.com> wrote:
> * I'm not too fond of the RollbackError name. It sounds like "an error while
> rolling back". I googled around and found out that DataDirect's proprietary
> driver has the same option, and they call it TransactionErrorBehavior. See
> http://blogs.datadirect.com/2013/07/solution-unexpected-postgres-current-transaction-aborted-error.html.
>
> * Instead of using 0-2 as the values, let's give them descriptive names.
> Something like "none", "RollbackTransaction", "RollbackStatement".
> (actually, we'll probably want to also allow the integers, to keep the
> connection string short, as there is a size limit on that)
OK, I have been working more on that, giving the attached patch. The
parameter name is changed to TransactionErrorBehavior, able to use the
values "Statement", "Nop", "Transaction" and "Default". "Default"
corresponds to the default behavior, that is used to set the rollback
behavior depending on the Postgres version driver is connected with.
As of now, TransactionErrorBehavior does not accept integer values as
it makes the patch a bit more simple, this could be added with some
atoi calls in dlg_specific.c.

I have updated dlg_wingui.c as well. Patch has always its set of docs
and regression tests.

Regards,
--
Michael

Вложения

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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: MultiXactId error after upgrade to 9.3.4
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: New parameter RollbackError to control rollback behavior on error